[mythtv-users] Monit for monetring mythbackend

Richard Freeman r-mythtv at thefreemanclan.net
Fri Nov 16 11:25:55 UTC 2007

John wrote:
> I just have one question. How do you start it
> automatically on boot and how do you pause the start
> on boot. I use to use a crontab but it would start the
> mythbackend before everything loaded thus I'd get
> either device busy or the device wouldn't work
> properly. The wiki says to do it with a monit_delay
> script but this gave me synatx errors. How does
> everyone else start monit?

Typically this is done via an init.d script.  If you installed monit
using your distribution's package manager it should have provided one
(if your distribution requires you to manually create this stuff for
every other package you install I'd consider another one).  Most init.d
implementations provide a way to indicate dependencies among daemons -
in my case I modified my init.d script to include "need mythbackend
mysql apache2 sshd" so that it loads in order (I monitor all of these
apps).  This syntax is likely gentoo-specific so it might not be of much
help to you.

In terms of how you get the init.d script to run at startup, typically
this is done by associating it with a runlevel.  Again, this varies
considerably by distribution - many provide a script that will handle
this for you (such as Gentoo's rc-update script), and if not usually it
is done by adding a symlink to the script in a runlevel directory (look
for an /etc/rc.5 directory or something along those lines).

I'm not sure what distro you're running, but chances are the folks who
maintain it also have some good documentation on how all this stuff is
supposed to work.  It does vary a little by distro but whatever you
learn will stand you in good stead elsewhere.  Don't worry - we all
start out as learners...

More information about the mythtv-users mailing list