LinuxQuestions.org
Welcome to the most active Linux Forum on the web.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Software
User Name
Password
Linux - Software This forum is for Software issues.
Having a problem installing a new program? Want to know which application is best for the job? Post your question in this forum.

Notices


Reply
  Search this Thread
Old 12-16-2005, 04:01 AM   #1
Jeozp
Member
 
Registered: Dec 2004
Distribution: Debian
Posts: 40

Rep: Reputation: 15
Can't kill a few proceses!


I can't seem to be able to kill a du and cp proces...

I am using ssh (putty 0.54) to accsess th server. And when Ii tried to see the size of all of my users malbox the "du -sh /var/virtual/*mydomain.com > tmp.txt" it just craped out I had to open another putty window to try to kill it, no luck. I then closed the whole thing down (hence all the "?" under the tty.

I can see them with ps (and their pid's) but when I try to "kill <pid>" or "kill -1 <pid>" or even "kill -9 <pid>" no killing happens, althou the kill itself dosent repport an error

After trying a couple more times (hence all those du's runin heh) I discovered it always gets stuck on the same users malobox. And that I can run "du -sh" on his mailobox without the problem (also on the onebelow him..), but when I tried to copy it to another location the "cp -p" did the same thing...

This is all on a mail server I would rather not have to reboot.

here is waht I see in "ps -e |grep du" and "ps -e |grep cp"

PID TTY TIME CMD
30631 ? 00:00:00 du
30962 ? 00:00:00 du
31515 ? 00:00:00 du
32313 ? 00:00:00 du
32459 ? 00:00:01 du
16852 ? 00:00:00 du
1642 ? 00:00:00 du
1919 ? 00:00:00 du
2213 ? 00:00:00 du
2934 ? 00:00:00 du
--------------------------------------
3092 ? 00:00:00 cp

and this is "top -p <pid>"

PID USER PRI NI SIZE RSS SHARE STAT %CPU %MEM TIME COMMAND
30631 root 9 0 544 544 376 D 0.0 0.1 0:00 du
30962 root 9 0 544 544 376 D 0.0 0.1 0:00 du
.
.
.
3092 root 9 0 592 592 504 D 0.0 0.1 0:00 cp

Is this something I should be woried about? Is ther some way to kill those proceses? What did I do wrong? And please dont tell me 42

Any help or yels of RTFM are apricieted, if you could just point me in the right direction..
 
Old 12-16-2005, 05:27 AM   #2
arckane
Member
 
Registered: Sep 2005
Location: UK
Distribution: Gentoo/Debian/Ubuntu
Posts: 308

Rep: Reputation: 39
Usually, if kill -9 <pid> doesn't work then the process will zombie and just hang there. I take it you are running the kill as Root? If not, kill as Root first, if they are still there you'd better schedule a reboot.
 
Old 12-16-2005, 05:55 AM   #3
Jeozp
Member
 
Registered: Dec 2004
Distribution: Debian
Posts: 40

Original Poster
Rep: Reputation: 15
ok reboot scheduled

now in the mean time could someone explain to me why this happend?

right now I have to check every mailbox, there are close to 400 of them, manauly before copying it to the new server. Some of them are up to 800mb and the only link is a mesly 2mb wifi, don't ask , so I can't do the migration during buisnes hours...

Now sice du hangs every time i run it on all the folders, does anyone have any sugestions?
again thx in advance for any help
 
Old 12-16-2005, 06:14 AM   #4
arckane
Member
 
Registered: Sep 2005
Location: UK
Distribution: Gentoo/Debian/Ubuntu
Posts: 308

Rep: Reputation: 39
Could it be a permissions error on a directory which causes du to hang? You said it only happens on some directories, or is it just when ran from top level?

If it's just from top level then you could try some shell scripting and loop through each second level dir and du from there?
 
Old 12-16-2005, 06:57 AM   #5
Jeozp
Member
 
Registered: Dec 2004
Distribution: Debian
Posts: 40

Original Poster
Rep: Reputation: 15
no reason for it to be a premisons thing. I am working as root and all the direstories in /var/virtual are "postfix postfix" defiened.

Though could it be that du hanged on that first pass becouse someone was using (postfix or some other part of the mail system)the direstori, after that the first instnce of du haden't released that directori and is cousing averything wlse to hang?
This is just a therori ofcourse....
 
Old 12-16-2005, 07:04 AM   #6
arckane
Member
 
Registered: Sep 2005
Location: UK
Distribution: Gentoo/Debian/Ubuntu
Posts: 308

Rep: Reputation: 39
You'll find out right after the reboot I'd imagine
 
Old 12-16-2005, 07:30 AM   #7
Jeozp
Member
 
Registered: Dec 2004
Distribution: Debian
Posts: 40

Original Poster
Rep: Reputation: 15
ok c ya after 17:00 then <keeps fingers crosed that the damn thing boots back up>
 
  


Reply



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
What if 'kill -9' fails to kill a task? chii-chan Linux - Newbie 15 03-27-2013 03:47 PM
how to use kill to kill a batch of processes with same name? dr_zayus69 Linux - Software 2 09-03-2005 06:35 PM
cannot kill process (kill -9 does not work) mazer13a Linux - General 1 05-27-2005 02:32 PM
start proceses spank Linux - Newbie 2 08-31-2003 07:59 PM
defunct proceses? JustinHoMi Linux - General 2 10-01-2001 02:01 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - Software

All times are GMT -5. The time now is 07:59 PM.

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
Open Source Consulting | Domain Registration