Operating System - HP-UX
1752795 Members
6380 Online
108789 Solutions
New Discussion юеВ

Re: ssh problem with normal user

 
yangk
Frequent Advisor

ssh problem with normal user

Hi all,

When i use the ssh connect to the localhost with normal user, it will not longin.
the debug message of the ssh client like :


debug1: Next authentication method: password
yangk@localhost's password:
debug3: packet_send2: adding 64 (len 54 padlen 10 extra_pad 64)
debug2: we sent a password packet, wait for reply
debug1: Authentication succeeded (password).
debug3: clear hostkey 0
debug3: clear hostkey 1
debug3: clear hostkey 2
debug1: Final hpn_buffer_size = 131072
debug1: HPN Disabled: 1, HPN Buffer Size: 131072
debug1: channel 0: new [client-session]
debug3: ssh_session2_open: channel_new: 0
debug2: channel 0: send open
debug1: Requesting no-more-sessions@openssh.com
debug1: Entering interactive session.
debug1: channel 0: free: client-session, nchannels 1
debug3: channel 0: status: The following connections are open:
#0 client-session (t3 r-1 i0/0 o0/0 fd 6/7 cfd -1)

debug3: channel 0: close_fds r 6 w 7 e 8 c -1
Connection to localhost closed by remote host.
Connection to localhost closed.
Transferred: sent 2224, received 1960 bytes, in 0.0 seconds
Bytes per second: sent 197529.5, received 174081.7
debug1: Exit status -1

it seems that it can pass the authentication , but it can not longin. So what is the problem?
Could some one give some advise about this?
6 REPLIES 6
Steven Schweda
Honored Contributor

Re: ssh problem with normal user

> Could some one give some advise about this?

You might get more advice if you provided
more information.

What are these systems?

uname -a

Which SSH software?

ssh -V

> the debug message of the ssh client like :
> [...]

A _complete_ transcript, including the actual
command(s) used would be nice, too.

Have you looked in the system log files?
nightwich
Valued Contributor

Re: ssh problem with normal user

Hi yangk


I think the "remote system" can't accept connections true ssh.

Try to see if the daemon of the ssh is running.

ps -ef | grep -i ssh

If not try to start it.


Regards
Steven Schweda
Honored Contributor

Re: ssh problem with normal user

> I think the "remote system" can't accept
> connections true ssh.

So, to whom was the client talking when a
message like this one was emitted?:

debug1: Next authentication method: password

As problem descriptions go, this one was
horrible, but I've never seen an SSH client
say "Connection to XXX closed" unless it had
first opened a connection to XXX. Which is
not easy to do if there's no SSH server
running on XXX.
Steven E. Protter
Exalted Contributor

Re: ssh problem with normal user

Shalom,

On the remote system:

ps -ef | grep sshd

See if the daemon is running.

Try bouncing it:

/sbin/init.d/secsh stop
/sbin/init.d/secsh start

Try checking the log /var/adm/syslog/syslog.log

SEP
Steven E Protter
Owner of ISN Corporation
http://isnamerica.com
http://hpuxconsulting.com
Sponsor: http://hpux.ws
Twitter: http://twitter.com/hpuxlinux
Founder http://newdatacloud.com
Richard Pereira_1
Regular Advisor

Re: ssh problem with normal user

Hi,

Do other users logins work via the same connection method? Is the problem limited to one particular user? If yes, verify the user's entry in /etc/passwd, check for things like a valid shell and valid home directory. / The log var/adm/syslog/syslog.log may also provide some errors for that user login.

If all users fail to login on localhost but work from an external host, check the /opt/ssh/etc/sshd_config file for any ListenAddress arguments. Perhaps your server listens only on specific addresses?

Good luck
yangk
Frequent Advisor

Re: ssh problem with normal user

Here is the message from the syslog.log:
Apr 20 12:15:54 sshpa4 sshd[23684]: SSH: Server;Ltype: Version;Remote: ::1-50502
;Protocol: 2.0;Client: OpenSSH_5.2p1+sftpfilecontrol-v1.3-hpn13v5
Apr 20 12:16:03 sshpa4 sshd[23684]: Accepted keyboard-interactive/pam for yangk2
from ::1 port 50502 ssh2

The other use encounter the same problem, but the root can login, and all the user with the telnet can work fine too.

So it is so strange to me.