New on LowEndTalk? Please Register and read our Community Rules.
All new Registrations are manually reviewed and approved, so a short delay after registration may occur before your account becomes active.
All new Registrations are manually reviewed and approved, so a short delay after registration may occur before your account becomes active.
Kill processes and restart them
This discussion has been closed.
Comments
there was a tread of this kind a few days back
I remember there was that thread, unfortunately, I couldn't find it anymore (could be one of those thread that missing from LET)
@Saiku
yeah that thread was started by me....and now even me can not find it
you want to check simple ram usage or swap usage also...
This will restart httpd process, when cpu spikes. You can customize this with kill all / kill command.
Workarounds are not solutions to problems.
I remember such a shell http://wangyan.org/blog/sys-mon-shell-script.html
But you need to understand some simple Chinese or translated.
If only I could find your post :P (It's probably missing anyway, went through a few pages from your discussion/comments and it's really not there xD
@Saiku
i think you forgot to check my reply...
oops. It's only ram usage. the VPS rarely use swap so I don't really care.
@Saiku
execute this command
free -m | grep "Mem" > /home/ram.txt
and give me that ram.txt file...
@mca295188
Mem: 996 887 109 0 16 209
That is the output from ram.txt
@Saiku
i can not count the place index from this file...i need that txt file as it is...
or tell me you can count the index yourself or not...
For total memory
For memory in use
Never mind for now, I probably won't need it anymore. Thanks for the effort to help me tho!
@Spirit you can close this thread now. Thanks.
Old thread is back: http://lowendtalk.com/discussion/13812/need-script-to-reboot-server-if-memory-usage-go-above-95
Of course.