1833080 Members
2794 Online
110050 Solutions
New Discussion

Very long login by ssh

 
Xou
Advisor

Re: Very long login by ssh

Delay was before any messages from server.

Trouble only in sshd from HP:
===
OpenSSH_5.2p1+sftpfilecontrol-v1.3, OpenSSL 0.9.8g 19 Oct 2007
HP-UX Secure Shell-A.05.20.006, HP-UX Secure Shell version
===

Now I use openssh 5.2p1(http://hpux.connect.org.uk/hppd/hpux/Networking/Admin/openssh-5.2p1/). It work good. Thanks to all.
Xou
Advisor

Re: Very long login by ssh

Hi ALL again! :)
I have a new trouble.

When count of ssh users more then 500 many cmnds crashed with "mmap error", for example:
===============================
#glance
/usr/lib/hpux32/dld.so: Cannot map text for library: mmap(0x0, 0x362be0, 0x5, 0x41, 3, 0x0) returns Not enough space.
#xglance
/usr/lib/hpux32/dld.so: Cannot map text for library: mmap(0x0, 0x362be0, 0x5, 0x41, 3, 0x0) returns Not enough space.

#mcedit ~/cmd.log
/usr/lib/hpux32/dld.so: Cannot map text for library: mmap(0x0, 0x2345d0, 0x5, 0x41, 3, 0x0) returns Not enough space.

#/home/user1/somescript.pl
/usr/lib/hpux32/dld.so: Cannot map text for library: mmap(0x0, 0x2f6660, 0x5, 0x41, 3, 0x0) returns Not enough space.
===============================

Kernel limits are not reached:
===============================
# kcusage
Tunable Usage / Setting

filecache_max 3015495680 / 4480000000
maxdsiz 18677760 / 4294963200
maxdsiz_64bit 227475456 / 4294967296
maxfiles_lim 404 / 20480
maxssiz 172032 / 268435456
maxssiz_64bit 1179648 / 1073741824
maxtsiz 35868672 / 134217728
maxtsiz_64bit 28205056 / 34359738368
maxuprc 1005 / 64474
max_thread_proc 128 / 4096
msgmni 2 / 71638
msgtql 0 / 32767
nflocks 20 / 4096
ninode 12300 / 37052
nkthread 27914 / 125382
nproc 6868 / 71638
npty 0 / 4096
nstrpty 815 / 4096
nstrtel 0 / 4096
nswapdev 4 / 32
nswapfs 0 / 32
semmni 154 / 16384
semmns 10697 / 71630
shmmax 19180371968 / 51200000000
shmmni 36 / 9216
shmseg 3 / 8
===============================

And memory usage normal:
===============================
# swapinfo -tam
Mb Mb Mb PCT START/ Mb
TYPE AVAIL USED FREE USED LIMIT RESERVE PRI NAME
dev 16384 0 16384 0% 0 - 1 /dev/vg00/lvol2
dev 131072 19116 111956 15% 0 - 0 /dev/dsk/c9t4d4
dev 131072 19112 111960 15% 0 - 0 /dev/dsk/c9t4d3
dev 208896 0 208896 0% 0 - 1 /dev/vg_local_swap/lv_local_swap0
reserve - 92694 -92694
memory 62209 17613 44596 28%
total 549633 148535 401098 27% - 0 -
===============================

perl in openssh(http://hpux.connect.org.uk/hppd/hpux/Networking/Admin/openssh-5.2p1/) run-time dependencies list is default hpux 11.31 bundle, but may problem be in it???
===============================
swlist |grep -i perl
perl D.5.8.8.F Perl Programming Language
===============================

Dennis Handly
Acclaimed Contributor

Re: Very long login by ssh

>When count of ssh users more then 500 many cmnds crashed with "mmap error",
>dld.so: Cannot map text for library : mmap(0x0, 0x362be0, 0x5, 0x41, 3, 0x0) returns Not enough space.

You are out of shared memory space or it is too fragmented.
What does "ipcs -ma" show?

You may need a newer linker/dld patch?

If this doesn't solve it, you'll have to contact the Response Center to get a tool that can print details on your shared memory allocations.

Or port your ssh to 64 bit.
Dennis Handly
Acclaimed Contributor

Re: Very long login by ssh

>ME: You are out of shared memory space or it is too fragmented.

Here is a thread where they are talking about shared memory space for mmap and the shminfo tool:
http://forums.itrc.hp.com/service/forums/questionanswer.do?threadId=1364505
Wiktor Cieślak
New Member

Re: Very long login by ssh

Hi Xou,
What Steve Post said may be right but according to /var/adm/wtmps file. Check

ll /var/adm/wtmps

I had same problem on some servers, on one of them 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