[mythtv-users] Extending mythshutdown to monitor non-myth processes
Paul Harrison
mythtv at dsl.pipex.com
Wed Nov 12 12:06:24 UTC 2008
mythtv at payne.ch wrote:
> I am running Mythdora 5 on a master backend and one frontend. I also
> use Samba to share som filesystems for general use, and I use Mythweb
> from other workstations for most scheduling and control actions.
>
> I've (finally) got WOL & ACPI wakeup working on the BE and I plan to
> send a WOL packet during FE startup to make sure the BE's running.
>
> The mythshutdown function will make sure the BE doesn't shutdown if
> the FE is running or soemthing is scheduled to be recorded, but how
> could I get it to stay on if someone is runnig Mythweb, or if samba
> shares are in use?
>
>
Create a script to do the checks and change the 'Pre Shutdown check
command' setting to call your script. Your script should return 0 if it
is OK to shutdown or 1 if it is not. You probably should add a call to
mythshutdown --check to your script which already checks for things
like mythfilldatabase running, comm flagging, in or about to start a
daily wakeup period etc. I'll leave it as an exercise to work out how
your script should check if MythWeb is active or samba shares are in use :-)
> Also: do I need to run mythwelcome on the BE or can I do everything I
> need on the BE without mythwelcome (eg start at midnight to allow the
> schedule update to run)?
>
>
No you only need MythWelcome on any FE's. You may not need it at all it
depend on how you want things to work. If when you exit the FE you
automatically shut the computer down then you don't need it. If on the
other hand you want the FE to stay up until the BE shuts down then you
need it. The idea is you start the mythfrontend from MythWelcome so
when you're done for the day and you exit mythfrontend, which will
allow the BE to shutdown, you're taken back to MythWelcome which if
you have it setup properly will shutdown the FE when the BE does. If
it's a combined FE/BE then you really always need MythWelcome.
> Any tips are welcome
>
> John
>
>
Paul H.
More information about the mythtv-users
mailing list