LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - Server (https://www.linuxquestions.org/questions/linux-server-73/)
-   -   Help with cpuspeed (https://www.linuxquestions.org/questions/linux-server-73/help-with-cpuspeed-629050/)

bt227 03-18-2008 06:18 PM

Help with cpuspeed
 
I was trying to monitor my server's CPU load and was playing around with cpuspeed, I ran it a bunch of times and it didn't seem to be doing anything. But when I check the list of running processes, I see there are 40+ instances of it running! The server load average has gone from below 1 to over 40, this probably has something to do with the freq scaling cpuspeed is doing. I tried to kill the process using kill but to no avail.

I am new to linux, any help you guys can offer would be much appreciated. I just want to get rid of these running instances and restore my server to the original state. Thanks for your help!

Bruce Hill 03-19-2008 01:38 AM

Welcome to LQ!

Read "man kill" -- every Linux command should have a manual page.

In a terminal issue "ps aux" to see the running processes. If you
can't kill it as user with "kill <pid>" then su - to root and issue
"kill -9 <pid>" where <pid> is the process ID.

TITiAN 03-19-2008 09:12 AM

You can also issue "killall <process name>" or "killall -sKILL <process name>" if you want to kill every single process with the name <process name>. The argument "-sKILL" should only be used when it doesn't work without, though, as it interrupts the ending procedure in a program.

bt227 03-19-2008 03:14 PM

Thanks for your tips. I am logged in as root. I tried "kill -9 <pid>" as well as "killall cpuspeed", but I still see them running when I use "ps -Al" I also see these cpuspeed processes when I use "ps aux" and it says they have been running since yesterday.

Any other suggestions would be appreciated!

syg00 03-19-2008 04:22 PM

Why do I have visions of the Mickey Mouse in Fantasia before my eyes ... ???.

If you are merely worried about the high load count, don't be - have a look at "top", and see if all those cpuspeed instances have a status of "D".
If so, that's what's contributing to the count. If you can't kill them, recycle the server at some time.

And be a little more circumspect in future.

TITiAN 03-20-2008 09:16 AM

Quote:

Originally Posted by TITiAN (Post 3093818)
You can also issue [...] "killall -sKILL <process name>" [...]. The argument "-sKILL" should only be used when it doesn't work without[...].

Quote:

Originally Posted by bt227 (Post 3094196)
Thanks for your tips. I am logged in as root. I tried "kill -9 <pid>" as well as "killall cpuspeed", but I still see them running when I use "ps -Al" I also see these cpuspeed processes when I use "ps aux" and it says they have been running since yesterday.

Any other suggestions would be appreciated!

How about that argument?
( edit: ) Maybe SIGTERM (default signal) isn't enough, so you need SIGKILL which you envoke by the argument ...

archtoad6 05-01-2008 09:57 AM

Did you fix the problem?
If so, how?

Funny, no one mentioned:
Code:

killall -9 cpuspeed
as a possible solution. Did you by any chance find & use it?

Also, htop (when run as root) allows to to interactively kill processes 1-at-a-time or in groups, & you can select the signal to send. I find it so useful, I usually have an X terminal (Konsole) running:
Quote:

nice -n-13 htop
at all times.


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