HPE GreenLake Administration
- Community Home
- >
- Servers and Operating Systems
- >
- Operating Systems
- >
- Operating System - HP-UX
- >
- Re: killing a process which has Processor utilizat...
Operating System - HP-UX
1833059
Members
2631
Online
110049
Solutions
Forums
Categories
Company
Local Language
back
Forums
Discussions
Forums
- Data Protection and Retention
- Entry Storage Systems
- Legacy
- Midrange and Enterprise Storage
- Storage Networking
- HPE Nimble Storage
Discussions
Forums
Discussions
Discussions
Discussions
Forums
Discussions
back
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
- BladeSystem Infrastructure and Application Solutions
- Appliance Servers
- Alpha Servers
- BackOffice Products
- Internet Products
- HPE 9000 and HPE e3000 Servers
- Networking
- Netservers
- Secure OS Software for Linux
- Server Management (Insight Manager 7)
- Windows Server 2003
- Operating System - Tru64 Unix
- ProLiant Deployment and Provisioning
- Linux-Based Community / Regional
- Microsoft System Center Integration
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Blogs
Information
Community
Resources
Community Language
Language
Forums
Blogs
Topic Options
- Subscribe to RSS Feed
- Mark Topic as New
- Mark Topic as Read
- Float this Topic for Current User
- Bookmark
- Subscribe
- Printer Friendly Page
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
10-10-2008 01:39 AM
10-10-2008 01:39 AM
killing a process which has Processor utilization for scheduling
Hi All,
I am trying to kill a number of processes using kill command.
Below is the ps -eaf of the processes I want to kill.
Here you can see that the second proecess i.e pid = 20410, is the parent for all other processes. And also it has cpu(Processor utilization for scheduling) as 1 ( column 4)
misjit 20424 20410 0 04:31:43
misjit 20410 1 1 04:31:41
misjit 20423 20410 0 04:31:43
misjit 20433 20410 0 04:31:43
misjit 20430 20410 0 04:31:43
misjit 20435 20410 0 04:31:43
misjit 20434 20410 0 04:31:43
misjit 20427 20410 0 04:31:43
misjit 20413 20410 0 04:31:41
misjit 20432 20410 0 04:31:43
So, if I kill parent process, then all chld process should be killed.
When I try the command "kill 20410", The processes are NOT getting killed( The cpu column is changing to 0). But second time I try the same command "kill 20410", all the processes getting killed !.
Can anybody explain me why?..
I am trying to kill a number of processes using kill command.
Below is the ps -eaf of the processes I want to kill.
Here you can see that the second proecess i.e pid = 20410, is the parent for all other processes. And also it has cpu(Processor utilization for scheduling) as 1 ( column 4)
misjit 20424 20410 0 04:31:43
misjit 20410 1 1 04:31:41
misjit 20423 20410 0 04:31:43
misjit 20433 20410 0 04:31:43
misjit 20430 20410 0 04:31:43
misjit 20435 20410 0 04:31:43
misjit 20434 20410 0 04:31:43
misjit 20427 20410 0 04:31:43
misjit 20413 20410 0 04:31:41
misjit 20432 20410 0 04:31:43
So, if I kill parent process, then all chld process should be killed.
When I try the command "kill 20410", The processes are NOT getting killed( The cpu column is changing to 0). But second time I try the same command "kill 20410", all the processes getting killed !.
Can anybody explain me why?..
3 REPLIES 3
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
10-10-2008 01:51 AM
10-10-2008 01:51 AM
Re: killing a process which has Processor utilization for scheduling
I don't know why that behaviour occurs.
But I've always been told to kill the child processes before killing the parent. To avoid Zombies...this sounds like some Halloween them...killing/zombies :)
So I just line all the child processes up beside the kill command
kill 20424 20423 20433 etc.
Then kill the parent
kill 20410
That's always worked for me 99%. But this opens another question along with your original....is the way I mentioned the correct way? Is there a better way?
Cheers
Note: My method above doesn't always work as the parent might spawn new child processes.
In that scenario I just put the process ID of the parent last in the kill command beside the child process ID's (I've always assume it kills the processes in order from left to right...a bad assumption????)
But I've always been told to kill the child processes before killing the parent. To avoid Zombies...this sounds like some Halloween them...killing/zombies :)
So I just line all the child processes up beside the kill command
kill 20424 20423 20433 etc.
Then kill the parent
kill 20410
That's always worked for me 99%. But this opens another question along with your original....is the way I mentioned the correct way? Is there a better way?
Cheers
Note: My method above doesn't always work as the parent might spawn new child processes.
In that scenario I just put the process ID of the parent last in the kill command beside the child process ID's (I've always assume it kills the processes in order from left to right...a bad assumption????)
The Devil is in the detail.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
10-10-2008 10:33 AM
10-10-2008 10:33 AM
Re: killing a process which has Processor utilization for scheduling
Hi Sushant,
Okay answer some of the questions?
1. Are you facing any performance issues on this server?
2. If yes paste the output for TOP,glance , sar,swapinfo -tam?
3. if you have kmeminfo script then please use it and let me know the output?
4. Do you suspect any application issues on this server?
Regards,
Vivek Bhatia
Okay answer some of the questions?
1. Are you facing any performance issues on this server?
2. If yes paste the output for TOP,glance , sar,swapinfo -tam?
3. if you have kmeminfo script then please use it and let me know the output?
4. Do you suspect any application issues on this server?
Regards,
Vivek Bhatia
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
10-10-2008 08:14 PM
10-10-2008 08:14 PM
Re: killing a process which has Processor utilization for scheduling
>Here you can see that the second process i.e pid = 20410
No we can't. :-) That's why you need to use this command to see a hierarchical listing:
UNIX95=EXTENDED_PS ps -Hfu misjit
>if I kill parent process, then all child process should be killed.
No, they usually are adopted by init as orphans.
>Kevin: But I've always been told to kill the child processes before killing the parent.
Yes. Also kill them at the same time so the parent doesn't make more.
>To avoid Zombies...this sounds like some Halloween them...killing/zombies :)
These aren't zombies, these are orphans, parent is init.
But you forgot to mention zombie masters, since you can't kill zombies. :-)
>In that scenario I just put the process ID of the parent last in the kill command ... (I've always assume it kills the processes in order from left to right.)
That's what I do. Copy from bottom up.
No we can't. :-) That's why you need to use this command to see a hierarchical listing:
UNIX95=EXTENDED_PS ps -Hfu misjit
>if I kill parent process, then all child process should be killed.
No, they usually are adopted by init as orphans.
>Kevin: But I've always been told to kill the child processes before killing the parent.
Yes. Also kill them at the same time so the parent doesn't make more.
>To avoid Zombies...this sounds like some Halloween them...killing/zombies :)
These aren't zombies, these are orphans, parent is init.
But you forgot to mention zombie masters, since you can't kill zombies. :-)
>In that scenario I just put the process ID of the parent last in the kill command ... (I've always assume it kills the processes in order from left to right.)
That's what I do. Copy from bottom up.
The opinions expressed above are the personal opinions of the authors, not of Hewlett Packard Enterprise. By using this site, you accept the Terms of Use and Rules of Participation.
Company
Events and news
Customer resources
© Copyright 2025 Hewlett Packard Enterprise Development LP