LinuxQuestions.org
Visit the LQ Articles and Editorials section
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Networking
User Name
Password
Linux - Networking This forum is for any issue related to networks or networking.
Routing, network cards, OSI, etc. Anything is fair game.

Notices

Reply
 
Search this Thread
Old 12-01-2004, 02:58 AM   #1
TiCkO
Member
 
Registered: Oct 2003
Location: Slovenija
Distribution: Slackware 9.1
Posts: 36

Rep: Reputation: 15
sshd doesn`t work


hello!

I have a little problem about sshd, but i can`t set it up. i have used slackwafre linux 10.0. And ssh was working with no problem, but now when i try to connect i have this message:
Code:
ticko@tickobox:~$ ssh ticko.heapsoft.com
ssh: connect to host ticko.heapsoft.com port 22: Connection refused
Now what is wrong? how to delete this sshd and install it again? i can`t find some similiar topic about sshd.
 
Old 12-01-2004, 03:40 AM   #2
|2ainman
Member
 
Registered: Mar 2004
Distribution: Slackware current, DSL 0.9.2
Posts: 133

Rep: Reputation: 15
Are you hosting the server yourself?
Is it behind a firewall?
Can you access any other services on the server?
When you say that ssh was working w/ no problem do you mean that you could ssh into localhost?
Code:
cat /etc/ssh/sshd_config
and post results plz
 
Old 12-02-2004, 10:32 AM   #3
TiCkO
Member
 
Registered: Oct 2003
Location: Slovenija
Distribution: Slackware 9.1
Posts: 36

Original Poster
Rep: Reputation: 15
here is it.

Code:
root@tickobox:/home/ticko# cat /etc/ssh/sshd_config
#       $OpenBSD: sshd_config,v 1.68 2003/12/29 16:39:50 millert Exp $

# This is the sshd server system-wide configuration file.  See
# sshd_config(5) for more information.

# This sshd was compiled with PATH=/usr/local/sbin:/usr/sbin:/sbin:/usr/local/bin:/usr/bin:/bin

# The strategy used for options in the default sshd_config shipped with
# OpenSSH is to specify options with their default value where
# possible, but leave them commented.  Uncommented options change a
# default value.

#Port 22
#Protocol 2,1
#ListenAddress 0.0.0.0
#ListenAddress ::

# HostKey for protocol version 1
#HostKey /etc/ssh/ssh_host_key
# HostKeys for protocol version 2
#HostKey /etc/ssh/ssh_host_rsa_key
#HostKey /etc/ssh/ssh_host_dsa_key

# Lifetime and size of ephemeral version 1 server key
#KeyRegenerationInterval 1h
#ServerKeyBits 768

# Logging
#obsoletes QuietMode and FascistLogging
#SyslogFacility AUTH
#LogLevel INFO

# Authentication:

#LoginGraceTime 2m
#PermitRootLogin yes
#StrictModes yes

#RSAAuthentication yes
#PubkeyAuthentication yes
#AuthorizedKeysFile     .ssh/authorized_keys

# For this to work you will also need host keys in /etc/ssh/ssh_known_hosts
#RhostsRSAAuthentication no
# similar for protocol version 2
#HostbasedAuthentication no
# Change to yes if you don't trust ~/.ssh/known_hosts for
# RhostsRSAAuthentication and HostbasedAuthentication
#IgnoreUserKnownHosts no
# Don't read the user's ~/.rhosts and ~/.shosts files
#IgnoreRhosts yes

# To disable tunneled clear text passwords, change to no here!
#PasswordAuthentication yes
#PermitEmptyPasswords no

# Change to no to disable s/key passwords
#ChallengeResponseAuthentication yes

# Kerberos options
#KerberosAuthentication no
#KerberosOrLocalPasswd yes
#KerberosTicketCleanup yes
#KerberosGetAFSToken no

# GSSAPI options
#GSSAPIAuthentication no
#GSSAPICleanupCredentials yes

# Set this to 'yes' to enable PAM authentication (via challenge-response)
# and session processing. Depending on your PAM configuration, this may
# bypass the setting of 'PasswordAuthentication' and 'PermitEmptyPasswords'
#UsePAM no

#AllowTcpForwarding yes
#GatewayPorts no
#X11Forwarding no
#X11DisplayOffset 10
#X11UseLocalhost yes
#PrintMotd yes
#PrintLastLog yes
#TCPKeepAlive yes
#UseLogin no
#UsePrivilegeSeparation yes
#PermitUserEnvironment no
#Compression yes
#ClientAliveInterval 0
#ClientAliveCountMax 3
#UseDNS yes
#PidFile /var/run/sshd.pid
#MaxStartups 10

# no default banner path
#Banner /some/path

# override default of no subsystems
Subsystem       sftp    /usr/libexec/sftp-server
so can now anybody tell me what is wrong.
 
Old 02-06-2006, 10:43 AM   #4
Svidd
LQ Newbie
 
Registered: Aug 2004
Location: Chicago
Distribution: Slackware 10.2 - current
Posts: 6

Rep: Reputation: 0
I'm having the same problem but I can't even connect on the local machine that sshd is running on.
 
Old 02-06-2006, 12:30 PM   #5
Darin
Senior Member
 
Registered: Jan 2003
Location: Portland, OR USA
Distribution: Slackware, SLAX, Gentoo, RH/Fedora
Posts: 1,024

Rep: Reputation: 45
Quote:
Originally Posted by |2ainman
Are you hosting the server yourself?
Apparently so.
Quote:
Originally Posted by |2ainman
Is it behind a firewall?
Is it? it's possible to set up packet filtering to even block local requests. You mentioned Slackware, did you add in a firewall package or rc.firewall script?
Quote:
Originally Posted by |2ainman
Can you access any other services on the server?
Like ping, http. Does the external name ticko.heapsoft.com resolve to the right machine? does ssh localhost or ssh 127.0.0.1 work?
Quote:
Originally Posted by |2ainman
When you say that ssh was working w/ no problem do you mean that you could ssh into localhost?
see above for localhost and were you getting it to work from offsite to your server via domain name before?
Quote:
Originally Posted by |2ainman
cat /etc/ssh/sshd_config and post results plz
The config file looks like it's just setting most defaults, that's probably not it.

Still some unanswered questions that would help us on the forum figure out what's wrong.
 
Old 02-06-2006, 04:24 PM   #6
satinet
Senior Member
 
Registered: Feb 2004
Location: England
Distribution: Slackware 11, Sabayon 3.1
Posts: 1,464

Rep: Reputation: 46
did you regenerate your keys or something.

and are you passing the passphrare automatically using ssh-agent?

you might want to turn 'PAM' authentication to 'no'.

try that... i would regen your keys at both sides. and blank any know keys and known hosts to get back to a blank sheet....

Last edited by satinet; 02-06-2006 at 04:28 PM.
 
Old 02-06-2006, 06:02 PM   #7
Svidd
LQ Newbie
 
Registered: Aug 2004
Location: Chicago
Distribution: Slackware 10.2 - current
Posts: 6

Rep: Reputation: 0
ok I regenerated the keys all right but it still refused my connection on port 22. To clerify this happens when I try $>ssh localhost so its not due to an external firewall.

and here is something interestinf sshd isint running appenetly... when I try /etc/rc.d/rc.sshd restart I get the message:
sshd: no process killed
and it is not in the process tree when I try ps ax

where are the log files kept because something could be going on I can't see.
 
Old 02-07-2006, 01:42 AM   #8
satinet
Senior Member
 
Registered: Feb 2004
Location: England
Distribution: Slackware 11, Sabayon 3.1
Posts: 1,464

Rep: Reputation: 46
so 'ps -ax|grep -i sshd' produces nothing?

hmm sounds like ssh isn't running. Can you ssh out from this box? bearing in mind that sshd doesnt need to be running to make outward connections....

are you sure this service is set to start when the system reboots? I'm not familiar with openbsd, but in Netbsd, you need to put it in the /etc/rc.conf file. (openbsd was a fork from netbsd,btw).
 
Old 02-07-2006, 11:16 AM   #9
Darin
Senior Member
 
Registered: Jan 2003
Location: Portland, OR USA
Distribution: Slackware, SLAX, Gentoo, RH/Fedora
Posts: 1,024

Rep: Reputation: 45
As root:
Code:
/etc/rc.d/rc.sshd start
tail -40 /var/log/messages | grep sshd
would be a good way to find out if/why it isn't starting.
 
Old 02-11-2006, 02:31 PM   #10
Svidd
LQ Newbie
 
Registered: Aug 2004
Location: Chicago
Distribution: Slackware 10.2 - current
Posts: 6

Rep: Reputation: 0
ps ax |grep -i sshd
produces nothing

I also tried darin's suggestion but either noting prints to the log involving sshd or I'm not doing something right.

I have hit another wall. it just seems that sshd won't run and won't tell me why. Is it possable something got corrupted becuase this happened at the same time the permissions for /dev/null got changed somehow. I don't know what happened there just one day it started complaining about permission problems wih /dev/null. I fixed that (I think/hope) by changing the permissions to world readable/writable.

I don't know how this affects my sshd problem but hopfully there is something I can do to get it working again.
 
Old 02-11-2006, 03:03 PM   #11
satinet
Senior Member
 
Registered: Feb 2004
Location: England
Distribution: Slackware 11, Sabayon 3.1
Posts: 1,464

Rep: Reputation: 46
what is the output when you actually start the service??
 
Old 02-11-2006, 04:50 PM   #12
Svidd
LQ Newbie
 
Registered: Aug 2004
Location: Chicago
Distribution: Slackware 10.2 - current
Posts: 6

Rep: Reputation: 0
no output whatsoever now.
When I wiped the rsa keys and started it it did give me output concerning that. Creating them.
Other then that nothing
 
Old 02-11-2006, 05:00 PM   #13
satinet
Senior Member
 
Registered: Feb 2004
Location: England
Distribution: Slackware 11, Sabayon 3.1
Posts: 1,464

Rep: Reputation: 46
i dont know how darwin works. but in hp-ux you have to go into /etc/rc.config.d/ and edit the ssh file so that it says something like sshd=1. otherwise it doesnt start even if you type /sbin/init.d/secsh start (the hp way of doing it). i wonder if there is a similar thing in darwin?

can you show the init script? dunno if there is an /etc/init.d or equivalent...
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

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
vnc4server doesn`t work! tyranus Debian 4 06-02-2006 06:08 PM
Wi-Fi doesn;t work on Suse 9.3 hackerarchangel Linux - Hardware 2 10-18-2005 12:59 PM
Microphone doesn' work Lars79 Slackware 20 08-30-2005 09:24 AM
PS/2 mouse doesnīt work :( teekaay Slackware 7 01-08-2004 02:22 AM
kopete doesnīt work maZ Linux - Software 1 07-31-2003 03:51 PM


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

Main Menu
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
identi.ca: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration