monit-general
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Automatically renicing a process


From: Martin Pala
Subject: Re: Automatically renicing a process
Date: Thu, 8 Mar 2012 16:21:47 +0100

Hello,

you can modify the start command to renice the process, for example:

  check process myproc with pidfile /var/run/myproc.pid
      start program = "/bin/bash -c '/etc/init.d/myproc start && 
/usr/bin/renice +1 `cat /var/run/myproc.pid`'"


Regards,
Martin


On Mar 7, 2012, at 5:12 PM, SL wrote:

> Hello
> 
> I didn't get any match on monit+renice, neither on the mailing list nor on 
> the web. And yet, I think I have a pretty basic use case, so I might be 
> missing something totally obvious.
> 
> I would like to automatically renice a process after it starts.
> 
> I have a NAS in charge of transcoding a webradio in realtime and streaming it 
> to my LAN. Whenever another CPU-intensive is launched, the streaming starts 
> skipping. Increasing the priority of the transcoding by hand prevents the 
> skipping.
> 
> The transcoding server starts with a /etc/init.d script that uses 
> start-stop-daemon. start-stop-daemon lets you define the nice level, but it 
> would require editing the Debian packaged script, which I would like to avoid.
> 
> How would you do that?
> 
> Thanks
> -- 
> Sylvain
> 
> --
> To unsubscribe:
> https://lists.nongnu.org/mailman/listinfo/monit-general




reply via email to

[Prev in Thread] Current Thread [Next in Thread]