LinuxQuestions.org
Share your knowledge at the LQ Wiki.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie
User Name
Password
Linux - Newbie This Linux forum is for members that are new to Linux.
Just starting out and have a question? If it is not in the man pages or the how-to's this is the place!

Notices


Reply
  Search this Thread
Old 08-18-2008, 01:47 AM   #1
yogesh619
LQ Newbie
 
Registered: Jul 2008
Posts: 15

Rep: Reputation: 0
ssh connection resused


Hi,

I am trying to connect to another m/c in my network with ssh
when i execute the command as
# ssh 10.10.10.69

it gives me following error as
ssh: connect to host 10.10.10.69 port 22: Connection refused

i can't understand why it is happening?
i checkd the following files on 10.10.10.69 it's contents are
vi /etc/sysconfig/system-config-firewall

--enabled
--port=22:tcp

what should i do???
 
Old 08-18-2008, 02:08 AM   #2
jomen
Senior Member
 
Registered: May 2004
Location: Leipzig/Germany
Distribution: Arch
Posts: 1,687

Rep: Reputation: 55
Is the sshd running there (to listen for incoming connections)?
 
Old 08-18-2008, 08:10 AM   #3
farslayer
LQ Guru
 
Registered: Oct 2005
Location: Northeast Ohio
Distribution: linuxdebian
Posts: 7,249
Blog Entries: 5

Rep: Reputation: 191Reputation: 191
You should be able to quickly check using netstat if sshd is running. do this from the box you are trying to connect to..

Code:
it-etch:~# netstat -alnp | grep ::22

tcp6       0      0 :::22                   :::*                    LISTEN      3205/sshd
 
Old 08-18-2008, 08:51 AM   #4
dqiu350508
LQ Newbie
 
Registered: Apr 2008
Posts: 19

Rep: Reputation: 0
Do you try to connect localhost with ssh ?
Quote:
[root@CentOS ssh]# ssh cf.linux@localhost
cf.linux@localhost's password:
Do you check the configuration of ssh in /etc/ssh/sshd_config;
Quote:
Port 22
#Protocol 2,1
Protocol 2
#AddressFamily any
#ListenAddress 0.0.0.0
#ListenAddress ::
…………
There maybe some errors in your firewall settings ,the result can not be accessed.
 
Old 08-18-2008, 10:22 AM   #5
tredegar
LQ 5k Club
 
Registered: May 2003
Location: London, UK
Distribution: Fedora38
Posts: 6,147

Rep: Reputation: 435Reputation: 435Reputation: 435Reputation: 435Reputation: 435
Code:
when i execute the command as
# ssh 10.10.10.69
The root user isn't normally allowed to login with ssh
So ssh to the other computer as yourself, and then become root in the normal manner if you need to:
Code:
user@localhost:~$ ssh 10.10.10.69
user@10.10.10.69:~$ su root
root@10.10.10.69:~#

Last edited by tredegar; 08-18-2008 at 11:26 AM. Reason: Clarity
 
Old 08-19-2008, 02:25 AM   #6
yogesh619
LQ Newbie
 
Registered: Jul 2008
Posts: 15

Original Poster
Rep: Reputation: 0
directory u specified is not present

Quote:
Originally Posted by dqiu350508 View Post
Do you try to connect localhost with ssh ?


Do you check the configuration of ssh in /etc/ssh/sshd_config;


There maybe some errors in your firewall settings ,the result can not be accessed.

hi, thanks
the file and even directory u specified is not present on the system "/etc/ssh"
what to do now???
 
Old 08-19-2008, 02:33 AM   #7
r3sistance
Senior Member
 
Registered: Mar 2004
Location: UK
Distribution: CentOS 6/7
Posts: 1,375

Rep: Reputation: 217Reputation: 217Reputation: 217
Sounds like you don't have SSHD or openssh-server installed correctly, what distro are you using? if your using debian for example, that will likely not come with openssh-server straight after an install and you may need to use apt-get to install it.
 
Old 08-19-2008, 06:12 AM   #8
yogesh619
LQ Newbie
 
Registered: Jul 2008
Posts: 15

Original Poster
Rep: Reputation: 0
yhanks!

Quote:
Originally Posted by r3sistance View Post
Sounds like you don't have SSHD or openssh-server installed correctly, what distro are you using? if your using debian for example, that will likely not come with openssh-server straight after an install and you may need to use apt-get to install it.
thank!

i will try with installing openssh. does it hav any dependancies or simply
rpm -ivh openssh....

will work? I am using fedora 9.
 
Old 08-19-2008, 06:27 AM   #9
billymayday
LQ Guru
 
Registered: Mar 2006
Location: Sydney, Australia
Distribution: Fedora, CentOS, OpenSuse, Slack, Gentoo, Debian, Arch, PCBSD
Posts: 6,678

Rep: Reputation: 122Reputation: 122
Try

yum install openssh-server
 
  


Reply



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
ssh: connection to host port: 22: Connection timed out lost connection cucolin@ Linux - Server 4 11-22-2011 06:15 AM
LXer: ssh-xfer: Quickly grabbing files over an existing SSH connection LXer Syndicated Linux News 0 08-08-2008 03:11 PM
ssh connection refused - trying to set up ssh server at home openSauce Linux - Server 10 10-18-2007 04:38 PM
Connection to ssh... wtfn00b Linux - Newbie 2 02-01-2006 10:09 AM
ssh connection doodah Linux - Networking 2 05-09-2001 07:35 AM

LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie

All times are GMT -5. The time now is 11:28 PM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration