Download your favorite Linux distribution at LQ ISO.
Go Back > Forums > Linux Forums > Linux - Newbie
User Name
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!


  Search this Thread
Old 05-05-2010, 06:02 AM   #1
LQ Newbie
Registered: Apr 2010
Posts: 3

Rep: Reputation: 0
PKILL process

Hey guys,
I am trying to kill a process.
I am using a Python handler and having a problem killing both the parent and all the child process belonging to it.

here is what i'm trying
pkill -p $pid && (sleep 5; kill -SIGTERM $pid) && (sleep 5; kill -SIGKILL $pid)
kill $pid && (sleep 5; kill -SIGTERM $pid) && (sleep 5; kill -SIGKILL $pid)

#Where $pid is the parent process id.

I'm fairly new to this so an help would be appreciated! Thanks!!
Old 05-05-2010, 07:38 AM   #2
LQ Newbie
Registered: Apr 2010
Posts: 3

Original Poster
Rep: Reputation: 0
just figured it out.
should of used -P and not -p


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
[SOLVED] pkill -KILL -u root ...... is that bad??? KZeeSoft Linux - Server 7 03-13-2010 11:17 AM
can't stop a process using pkill 2007fld Linux - Server 4 09-12-2007 09:13 AM
when a process cann't be terminated through kill/skill/pkill/killall... Osirix Linux - Software 9 07-19-2006 12:16 AM
pkill ssh elohmrow Linux - Security 2 08-25-2005 10:51 AM
pgrep/pkill d3funct Linux - General 0 09-18-2001 03:30 PM > Forums > Linux Forums > Linux - Newbie

All times are GMT -5. The time now is 05:58 AM.

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