Quote:
Originally Posted by leosgb
I am not sure of what you are trying to do. I can do ls /proc/<pid>/:
ls /proc/1/
auxv cwd exe loginuid mem oom_adj root smaps statm task
cmdline environ fd maps mounts oom_score seccomp stat status wchan
If you have hanged processes you can always kill them:
ps aux (it iwll display the current processes)
After you find the pid for the process you want to kill you just:
kill -9 pid
Does this help you?
|
see, what you are saying is right but kill -9 sends the terminate signal to a process. a hanged process will however receive the signal but a process exits only if it closes all the file descriptors, releasing memory maps etc.
if there is a hunged process (eg. a process trying to access the nfs mount on a server while the remote server is down) will not terminate via kill -9 command. also ps command will only work if the processes in /proc directory allows the stat file to be accesses. A hunged process does not allow the ps command to seek the stat info. thts why ps, top, w command wont work.
Thep problem what I am facing is similar to "http://www.ussg.iu.edu/hypermail/linux/kernel/0207.1/0683.html".
there is one way to get rid of this is to reboot the machine, but production systems shud not be rebooted very often. what I am looking for is anything which allows us to free the "hunged process's" memory file descriptor so that the process makes an exit.