[mythtv-users] Can I restart the Backend from the Frontend? [SOLVED]

Andrew Lyon andrew.lyon at gmail.com
Sat Sep 30 19:54:20 UTC 2006


> Kevin Kuphal wrote:
> > Search the archives for the EXEC menu command.  It will launch any
> > external script.
> Thanks Kevin.
>
> For the benefit of the archives, here's how I did this:-
>
> 1) I added a menu item called "Restart Backend" according to this:
> http://www.myhdbox.com/mythtips/2006/04/tip-2-how-to-customize-mythtvs-menus.php.
> I added it to the Utilities menu.
>
>    <button>
>    <type>SHUTDOWN</type>
>    <text>Restart Backend</text>
>    <action>EXEC ssh -l mythtv server.home "sudo
> ./restart_backend.sh"</action>
>    </button>
>
> 2) I set up RSA keys for the mythtv user, so that it can ssh into the
> backend without having to enter a password. On Gentoo, this is made
> easier with ssh-installkeys, discussed here:
> http://gentoo-wiki.com/SECURITY_SSH_without_a_password.
>
> 3) I created the "restart_backend.sh" script to restart the backend, and
> added the mythtv user to the sudoers file, allowing it to run that
> script without a password:
>
>    mythtv ALL = NOPASSWD: /home/mythtv/restart_backend.sh
>
> and that's about it.
>
> Cheers,
>
> Jon
>
>

Brilliant!, I added a second option that also rmmod's and modprobes
the drivers as well, somtimes things go completely screwy when im
using a cam. and it only takes a second too run :)

Andy


More information about the mythtv-users mailing list