create a cron job to kill process if stuck for x number of hours - Linux
$30-250 USD
Closed
Posted over 9 years ago
$30-250 USD
Paid on delivery
Hello,
We have a mplayer process which sometimes hangs for several hours or days until killed. We would like to create a cron job that runs every hour to kill these stucked mplayer process if they have been running for more than X number of hours.
A sample stucked mplayer process is:
root@debian:~# ps -o etime,pid,stime,time,cmd -C mplayer
ELAPSED PID STIME TIME CMD
7-13:38:20 30306 Jul29 7-12:47:28 mplayer /storage/cgi-bin/uploads/00450/nnyb38w2tdqj -identify -frames 0 -quiet -ao null -vo null
This project is to create the script that will be run via cron job. It will check to see if there are any mplayer process stucked for more than X number of hours and kill if so.
Budget is about $40
Thank you.
Hello,
I am an expert level Linux system administrator with more than 12 years of experiences.
I can write a bash script to monitor and kill mplayer processes that run longer than 3 hours and can place it within crontab to run the script.
I can deliver the script within hours with a very professionally coding/commenting.
kindly let me know if you have any additional question & request,
Regards,
Pardus.
Hello,
I am an experienced linux admin working for a well known web hosting company in US. I have done these kind of projects before. This is a simple thing that we do for our clients daily. Please let me know when we can start.
Regards
Rahul
Hi. I worked hosting company 4 years. Have experience in the administration of servers Linux, FreeBSD, Cisco etc. I am create scripts on sh, bash partially on perl. Many times did similar jobs.
Hi,
I can write you a shell script that kills mplayer processes that have exceeded the max runtime. I have lots of experience writing shell scripts and can have this done for you in no time. If you have any questions please let me know.
Thanks,
Derek
Hi there,
I have already written similar kind of script for killing the application if running more than 2 hrs as per my company need.I am pretty confident about this to make your requirment work
Best Regards,
Rohit
Hi,
i would offer you a simple script written in php or perl, where you can handle the number of hours as command line parameter.
I'm looking forward to support your project,
Hawaiibernd.