[mythtv] Systemd expertise needed: systemctl fails to start mythbackend

Gavin Hurlbut gjhurlbu at gmail.com
Thu Jul 5 17:22:29 UTC 2012


On Thu, Jul 5, 2012 at 9:25 AM, R. G. Newbury <newbury at mandamus.org> wrote:
> Using --syslog local7 (and why *that* name: it's used in the example
> somewhere but without explanation), I get only the following in
> /var/log/messages:

You need to use one of the syslog facilities to use syslog.  LOCAL7 is
the default one I chose for mythtv as it is almost always available
for use.  There are a limited number of available facilities.

> Jul  5 12:19:34 tor6 mythlogserver: mythlogserver[2125]: C thread_unknown
> mythcommandlineparser.cpp:2545 (ConfigureLogging) mythlogserver version:
> master [v0.26-pre-742-gb6d65fc-dirty] www.mythtv.org
> Jul  5 12:19:34 tor6 mythlogserver: mythlogserver[2125]: C thread_unknown
> mythcommandlineparser.cpp:2547 (ConfigureLogging) Qt version: compile:
> 4.8.2, runtime: 4.8.2
> Jul  5 12:19:34 tor6 mythlogserver: mythlogserver[2125]: N thread_unknown
> mythcommandlineparser.cpp:2549 (ConfigureLogging) Enabled verbose msgs:
>  general
> Jul  5 12:19:34 tor6 mythlogserver: mythbackend[2087]: C thread_unknown
> mythcommandlineparser.cpp:2545 (ConfigureLogging) mythbackend version:
> master [v0.26-pre-742-gb6d65fc-dirty] www.mythtv.org
> Jul  5 12:19:34 tor6 mythlogserver: mythbackend[2087]: C thread_unknown
> mythcommandlineparser.cpp:2547 (ConfigureLogging) Qt version: compile:
> 4.8.2, runtime: 4.8.2
> Jul  5 12:19:34 tor6 mythlogserver: mythbackend[2087]: N thread_unknown
> mythcommandlineparser.cpp:2549 (ConfigureLogging) Enabled verbose msgs:
>  general
> [root at tor6 log]#
>
>
> Which is all about the mythlogserver.....

No, it is not.

Read the lines more carefully.  The first logserver in the line means
that's the process actually doing the logging.  Syslog doesn't
effectively let me shut that off.  Immediately after, it shows the
actual program the log message came from, and its pid.

Now, really, for debugging, you should not rely on the use of syslog.
If given a logpath, MythTV applications will generate a logfile for
every run of the application that contains ONLY logs for that run.
These are more useful than the syslog option as you don't need to
filter them, and because the timing will be accurate.  The timestamp
on syslog messages is when syslogd received the message (nothing we
can do about that) and only has second resolution.  The debug log
files have microsecond resolution, and the timestamps are when the log
message was created.

> Want to take 'obscure systemd problems' for $400??

I don't do init scripts for mythtv :)  I stop/start/rebuild/mess with
my machines so much, it would be an utter waste of time for me to use
a system-level script.  I run my own start script (which is on github
in my mythtvmeta repo) to wrap the calls to setup path, etc as I also
don't install into /usr or /usr/local, but rather into
/opt/mythtv/${BRANCHNAME} as I often have several branches installed
at once.  My logs go to /opt/mythtv/logs/${BRANCHNAME} and are managed
by logrotate (archived weekly, deleted after 3 months, IIRC).


More information about the mythtv-dev mailing list