I have a Ubuntu web server for Rails 3.0 application. when I login to my webserver and do
top
I get set of processes with their stats. Out of that nano
process is occupying 100% of the CPU. And that nano process is a root
process. I dont know what is going wrong. Because of this, my apache processes, ruby processes all are getting their chance to answer to answer any web requests.
I am the only one who is logged in via ssh. I have disabled webserver logins via password. Please help.
I've had this happen with other text editting programs if I'm ssh'd into the box and lose connection. When I go back in, the process I was using before disconnect was taking 100% cpu.
I'd kill it.
If you have sudo permissions, you can kill that process. Note you may lose something important that is being edited in nano, so be careful, especially to get the right pid.
First find the pid:
This will list all
nano
processes, something like this:root 1234 0 0 08:13 ? 00:00:01 nano
find the pid in the second column (1234 in the above example). Then you can do:
If that doesn't work:
Replace the
<pid>
with the actual pid.If you don't have sudo permissions, then you can try using
su
and log in as root in a similar way, though in that case you need the root password (sudo asks you for your password, i.e. the password of the currently logged in user). If you don't have any way to log in as root, then you cannot do anything about that process - you need to contact somebody who has such permissions.