Operating System - HP-UX
1748112 Members
3431 Online
108758 Solutions
New Discussion юеВ

Re: ssh upgrade --login prompt takes time

 
SOLVED
Go to solution
Bill Hassell
Honored Contributor

Re: ssh upgrade --login prompt takes time

30 seconds (and multiples 60 and 90) typicallt signal name resolution issues. On your server run nsquery and nslookup for the incoming or local system where ssh is being run:

nsquery hosts local-IP-address
nslookup local-IP-address

If the IP address cannot be resolved (technically, authenticated), you'll see a 30 second delay for each DNS server listed in /etc/resolv.conf. Check /etc/nsswitch.conf for these lines:

hosts: files [NOTFOUND=continue UNAVAIL=continue] dns
ipnodes: files [NOTFOUND=return] dns

If dns is first, try putting files first, then add the IP address (and dummy name) of your local machine to /etc/hosts and try ssh again.


Bill Hassell, sysadmin
Rajendra prasad NVR
Frequent Advisor

Re: ssh upgrade --login prompt takes time

Bill,

I checked all your suggetions but not resolved the problem.

Mel,

Below are lines uncommented in sshd_config file

[server8:/opt/ssh/etc]grep -v '#' sshd_config
Protocol 2
PermitRootLogin no
KerberosAuthentication yes
UsePAM yes
X11Forwarding yes
X11UseLocalhost no
EnforceSecureTTY yes
Subsystem sftp /opt/ssh/libexec/sftp-server


When ssh -vvv is working fine means with no time it is givinig promt. I am using putty 0.60 which was downloaded from
http://www.chiark.greenend.org.uk/~sgtatham/putty/


Rajendra prasad NVR
Frequent Advisor

Re: ssh upgrade --login prompt takes time

ssh -vvv i treid to login from one server to other server it is working fine. but problem when i try to login from my desk top to server directly.

But other 11.23 version unix servers i am able to login with no issue. The problem where i am facing is 11.11 version hpunix servers.
Bill Hassell
Honored Contributor

Re: ssh upgrade --login prompt takes time

> login from my desk top to server directly.

Since server to server is OK, these boxes probably have a validated IP address from your DNS server. Since only your desktop (Linux or a PC?) fails, it is likely that your server does not know your IP address.


Bill Hassell, sysadmin
Rajendra prasad NVR
Frequent Advisor

Re: ssh upgrade --login prompt takes time

Looks like it is not issue with server.
Wiktor Cie┼Ыlak
New Member

Re: ssh upgrade --login prompt takes time

Hi,

I had same problem on some servers, in my case it was related to wtmps file. On one of the servers wtmps file was 1,8GB big and login took over 1 min. After I have zeroing the wtmps file, login takes ~2 sec.
You can use script below to archive and clear wtmps file:

/usr/sbin/acct/fwtmp < /var/adm/wtmps > $SOME_DIR/wtmp_`date +%Y%m%d`.txt

cat /dev/null > /var/adm/wtmps

Pozdrawiam
balaji_vvv
Frequent Advisor

Re: ssh upgrade --login prompt takes time

usr/sbin/acct/fwtmp < /var/adm/wtmps > $SOME_DIR/wtmp_`date +%Y%m%d`.txt

cat /dev/null > /var/adm/wtmps

wtmps? or wtmpx?
balaji_vvv
Frequent Advisor

Re: ssh upgrade --login prompt takes time

usr/sbin/acct/fwtmp < /var/adm/wtmps > $SOME_DIR/wtmp_`date +%Y%m%d`.txt

cat /dev/null > /var/adm/wtmps

wtmps or wtmpx?