1833776 Members
1976 Online
110063 Solutions
New Discussion

ls -al / hang

 
SOLVED
Go to solution
yulianto piyut
Valued Contributor

ls -al / hang

somebody now why ls -al / (root) hang ? in another direcory like /var, i can do ls -al.
10 REPLIES 10
Steven E. Protter
Exalted Contributor

Re: ls -al / hang

Shalom,

Probably ls -al / is listing a stale nfs mount.

Check your nfs mounts and possibly stop/start the services or automounter and the problem should go away. There may of course be a problem on the actual NFS server.

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
yulianto piyut
Valued Contributor

Re: ls -al / hang

steven,

i have already stop & start the nfs daemon
/sbin/init.d/nfs.core stop
/sbin/init.d/nfs.client stop
/sbin/init.d/nfs.server stop

then with some command, i start the nfs, but still hang. something that make me confuse is in /etc/mnntab file, there is a mounting /net:
pjkpdb1:(pid777) /net ignore defaults 0 0 1185044493
the real hostname is oasddb1.

# more /etc/mnttab
/dev/vg00/lvol3 / vxfs log 0 1 1185044449
/dev/vg00/lvol1 /stand hfs defaults 0 0 1185044450
/dev/vg00/lvol8 /var vxfs delaylog,nodatainlog 0 0 1185044463
/dev/vg00/lvol7 /usr vxfs delaylog,nodatainlog 0 0 1185044463
/dev/vg00/lvol6 /tmp vxfs delaylog,nodatainlog 0 0 1185044464
/dev/vg00/lvol5 /opt vxfs delaylog,nodatainlog 0 0 1185044464
/dev/vg00/lvol4 /home vxfs delaylog,nodatainlog 0 0 1185044464
pjkpdb1:(pid777) /net ignore defaults 0 0 1185044493
/dev/vg02/lvol1 /db11i vxfs log,nodatainlog 0 0 1191241319
/dev/vg03/lvol1 /appstest vxfs log,nodatainlog 0 0 1191241334
/dev/vg01/lvol1 /appsproddb vxfs delaylog,nodatainlog,largefiles 0 0 1191314463
# uname -a
HP-UX oasddb1 B.11.11 U 9000/800 930887987 unlimited-user license

MarkSyder
Honored Contributor

Re: ls -al / hang

What response do you get if you ping pjkpdb1?

Mark Syder (like the drink but spelt different)
The triumph of evil requires only that good men do nothing
Yogeeraj_1
Honored Contributor

Re: ls -al / hang

hi,

this is most probably related to a network connectivity problem to the server pjkpdb1.

what do you see when in your syslog.log or when you run dmesg?

revert
kind regards
yogeeraj
No person was ever honoured for what he received. Honour has been the reward for what he gave (clavin coolidge)
F Verschuren
Esteemed Contributor
Solution

Re: ls -al / hang

ls -1 / |while read line
do
echo $line
ls -al $line
done

this wil give you a clou on what the ls is hanging..
als soon as this hangs you know what the dir is that is causing it, like the ealyer post it is most likely a nfs mount from a server that you can't ping anny more, if that is the cause it is solved when you temp ad the ip to a other server, this normaly wil free the i/o wait....

if it is not a nfs mount please post the lvdisplay -v from mountpoint
yulianto piyut
Valued Contributor

Re: ls -al / hang

thx all,

pjkpdb1 is the old hostname for this server. the new hostname is oasddb1. I have changed the ip and hostname for this server. when i run script gave by Verschuren, output hang at net directory.

nt
total 16
drwxr-x--- 2 root sys 96 Dec 11 2006 .
drwxr-xr-x 25 root root 8192 Dec 6 16:37 ..
net

I think, it's related to /etc/auto_master. hmm..poor me, before i have kill -9 autmount daemon. I try to run automount but can not, it's hang.
# /usr/lib/netsvc/fs/automount/automount -f /etc/auto_master
# ps -ef|grep mount
root 27097 27078 0 18:57:44 pts/24 0:00 grep mount
root 26169 1 0 15:57:54 ? 0:00 /usr/sbin/rpc.mountd

is it need reboot server for solving this issue?

-yut-
Pete Randall
Outstanding Contributor

Re: ls -al / hang

> is it need reboot server for solving this issue?

Yes.

Make sure your host name resolution is correct, then reboot.


Pete

Pete
Yogeeraj_1
Honored Contributor

Re: ls -al / hang

hi,

Yes. Unfortunately you will have to reboot.

Before you reboot, also verify your /etc/fstab for any references to the old name.

good luck!
kind regards
yogeeraj
No person was ever honoured for what he received. Honour has been the reward for what he gave (clavin coolidge)
F Verschuren
Esteemed Contributor

Re: ls -al / hang

the system is waiting on this share, be for you reboot do not forger to remove this share out of the /etc/auto_master, if you do not neet it....
F Verschuren
Esteemed Contributor

Re: ls -al / hang

you can try to temp ad the old ip adress (if it is not reused jet) you have a change this frees your hanging auto mount if not a reboot is needed to fix this.