[mythtv-users] Notification of conflicts

Michael T. Dean mtdean at thirdcontact.com
Sat Sep 19 13:16:40 UTC 2009


On 09/14/2009 08:26 PM, f-myth-users wrote:
> From: Jim Stichnoth 
>
>     > If you still have problems finding the perl script or getting it to
>     > run, you could always try "mythbackend --printsched".  Conflicts will
>     > be indicated by a "C" character in the column labeled "N".  Unless the
>     > formatting of --printsched has changed, this command should work:
>
>     >   mythbackend --printsched | awk '/^Title - Subtitle/||substr($0,70,1)=="C"{print}'
>
> I do something similar---since I log fairly verbosely from my backend,
> I have several different greps all glued to its output with tee, each
> of which feeds into various notifiers if they trigger on something.
>
> In other words, I have something like this:
>
>   mythbackend [options] | tee >(scanner1) >(scanner2) ... | split [options] logfile
>
> where, for conflicts, one of the scannerN entries is
>
>   >(grep --line-buffered -E 'C   [0-9]+$' | notice-schedule-conflicts)
>
> and notice-schedule-conflicts is a simple bash script that stores each
> hit in a file;

http://swatch.sourceforge.net/
http://sourceforge.net/projects/swatch/

http://kodu.neti.ee/~risto/sec/

>  if it's already in the file, I've already been notified.
> The file gets cleared before mfdb runs.  Thus, I only get notified
> about any given conflict once a day, instead of every time the
> scheduler runs---but since it's monitoring the backend log rather
> than doing an explicit printsched every so often, I get notified the
> instant the scheduler first creates the conflict. so I find out if it
> magically -creates- a conflict right in the middle of primetime when
> nothing's been edited and mfdb hasn't run [which it did once]

There's absolutely no magic in Myth's scheduler and the scheduler does 
not create conflicts--people do.  Assuming you have no conflicts one 
minute, the only way that a conflict could ever be created is if a) your 
recording rules change (includes extending an ongoing recording or 
saying not to record a show when you're in LiveTV and it asks for the 
tuner), b) your listings change, c) some capture cards (i.e. in a remote 
backend) drop offline.

Mike


More information about the mythtv-users mailing list