LinuxQuestions.org
Welcome to the most active Linux Forum on the web.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie
User Name
Password
Linux - Newbie This Linux forum is for members that are new to Linux.
Just starting out and have a question? If it is not in the man pages or the how-to's this is the place!

Notices


Reply
  Search this Thread
Old 09-27-2009, 07:46 AM   #1
threezerous
Member
 
Registered: Jul 2009
Posts: 91

Rep: Reputation: 15
Question Is it normal to see many threads of df -hP running under ps -ef?


When I tried to run df -k, the command just got hung after displaying the following lines....would not show me the nfs mounts, which I know exist.

Filesystem 1K-blocks Used Available Use% Mounted on
/dev/sda2 59755388 18558848 38161060 33% /
/dev/sda1 101086 13361 82506 14% /boot
none 1933036 0 1933036 0% /dev/shm

To check if the CPU is loaded or if there are any processes loading the server, i ran a ps-ef | grep df and I got a result of the kind below. Is that normal to see so many df -hP processes running? Or should I get rid of them using kill command?

root 4473 4467 0 Sep12 ? 00:00:00 df -hP
dmadmin 4888 26971 0 07:32 pts/3 00:00:00 grep df
root 5091 5088 0 Sep24 ? 00:00:00 df -hP
root 8033 8025 0 Sep19 ? 00:00:00 df -hP
root 8429 8423 0 Sep04 ? 00:00:00 df -hP
root 8562 8555 0 Sep26 ? 00:00:00 df -hP
dmadmin 8764 1 0 07:28 ? 00:00:00 df -k
root 10552 10547 0 Sep15 ? 00:00:00 df -hP
root 11276 11269 0 Sep16 ? 00:00:00 df -hP
root 12439 12432 0 Sep11 ? 00:00:00 df -hP
root 13039 13032 0 Aug28 ? 00:00:00 df -hP
root 13946 13941 0 Sep17 ? 00:00:00 df -hP
dmadmin 14464 1 0 07:32 ? 00:00:00 df -k
root 19988 19983 0 Aug21 ? 00:00:00 df -hP
root 20244 20237 0 Sep25 ? 00:00:00 df -hP
root 20857 20850 0 Sep03 ? 00:00:00 df -hP
root 22043 22040 0 Sep23 ? 00:00:00 df -hP
root 22592 22586 0 Aug20 ? 00:00:00 df -hP
root 22897 22894 0 Sep07 ? 00:00:00 df -hP
root 23315 23309 0 Sep20 ? 00:00:00 df -hP
root 23635 23631 0 Aug27 ? 00:00:00 df -hP
root 23839 23833 0 Sep06 ? 00:00:00 df -hP
root 25401 25393 0 Aug23 ? 00:00:00 df -hP
root 25414 25408 0 Aug22 ? 00:00:00 df -hP
root 28061 28058 0 Sep18 ? 00:00:00 df -hP
root 29841 29837 0 Sep08 ? 00:00:00 df -hP
root 30643 30635 0 04:02 ? 00:00:00 df -hP
root 30850 30847 0 Sep22 ? 00:00:00 df -hP

Thanks to all in advance
 
Old 09-27-2009, 08:15 AM   #2
avalonit
Member
 
Registered: Jun 2008
Posts: 75

Rep: Reputation: 18
Check your NFS mount and umount/mount it.

I think it would be safe to kill the df processes if they don't disappear after the remount.

You can check if your distribution has started the nfs locking service as well "ps -ef |grep lock" you should see something like rpc.lockd or [lockd]
 
Old 09-27-2009, 08:51 PM   #3
threezerous
Member
 
Registered: Jul 2009
Posts: 91

Original Poster
Rep: Reputation: 15
kill -9 does not seem to work for the df -hP or df -k processes

Thank You for your tips and suggestions

I did umount and mounted the NFS...The processes for df -k and df -hP did not go away. Even trying to kill them using kill -9 PID does not seem to get rid of these processes.

Thanks again...
 
Old 09-27-2009, 09:08 PM   #4
chrism01
LQ Guru
 
Registered: Aug 2004
Location: Sydney
Distribution: Centos 6.8, Centos 5.10
Posts: 17,254

Rep: Reputation: 2328Reputation: 2328Reputation: 2328Reputation: 2328Reputation: 2328Reputation: 2328Reputation: 2328Reputation: 2328Reputation: 2328Reputation: 2328Reputation: 2328
The processes are prob trying to read the old non-existent mounts and hung. They are not dynamic (ie they won't stop reading the old mount and read the new ones).
You can try to

kill -9 <pid>

as root, but if that doesn't work, you may have to reboot, or let them die (I think eventually they will, not sure though).
Definitely check that all the expected nfs related processes are running; see section 18.9.1 http://www.linuxtopia.org/online_boo...y-portmap.html
 
Old 09-28-2009, 01:13 AM   #5
avalonit
Member
 
Registered: Jun 2008
Posts: 75

Rep: Reputation: 18
Quote:
Originally Posted by threezerous View Post
Thank You for your tips and suggestions

I did umount and mounted the NFS...The processes for df -k and df -hP did not go away. Even trying to kill them using kill -9 PID does not seem to get rid of these processes.

Thanks again...
I guess after kill -9, they are listed as defunct?

I have only seen this in conjunction with NFS and another application. Then restarting the NFS locking service helped get rid of them. On some systems the lockd is started automatically, on RHEL/CentOS 4 there is a nfslock init.d script. There could be other methods on other systems.
So check NFS locking is working even if lockd is running.
Look for dmesg and messages in the syslog.


At the moment I don't think the df processes are harmful for your server. But keep an eye on this.
 
Old 10-05-2009, 11:05 AM   #6
threezerous
Member
 
Registered: Jul 2009
Posts: 91

Original Poster
Rep: Reputation: 15
Thumbs up

I rebooted the box, so could not confirm if the processes are listed as defunct. I will check the logs as you suggested. Thanks
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
Return code for parallel running threads jitendriya.dash Programming 2 05-13-2009 01:12 AM
Execution threads vs normal threads jonty_11 Linux - General 2 03-26-2008 11:37 AM
How can I retrieve the number of running posix threads? Pandamatak Programming 2 12-24-2005 12:45 PM
how to list all running threads minil Programming 2 12-28-2004 11:25 PM
how to write a program can have 2 threads running at the same time?? man9 Programming 3 10-07-2000 02:43 PM


All times are GMT -5. The time now is 01:13 AM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration