[mythtv-users] Silencing mythfilldatabase

Dave Sherohman esper at sherohman.org
Sat Sep 24 14:46:28 UTC 2005


What does it take to eliminate all non-error output from mythbackend?

I'm using mythtv 0.18.1, as packaged for Debian at
http://dijkstra.csh.rit.edu/~mdz/debian and mythfilldatabase is being
run by anacron from /etc/cron.daily/mythtv-backend with the following
script:

--- cut here ---
#!/bin/sh

su mythtv -c "mythfilldatabase --quiet" >/dev/null
--- cut here ---

I added the ">/dev/null" myself in an attempt to silence it, but this
had no noticable effect - I still get email from cron every night
with mythfilldatabase's output.  I have also tried moving it inside
the quoted command string and this has no effect.

Changing it to "&>/dev/null" does successfully eliminate all
non-error output from mythfilldatabase, but at the cost of also
eliminating all error output.  Although I am rather annoyed by the
(highly verbose) daily reports of its normal operation, I do still
consider it to be fairly important to receive notice of any problems.

I also saw a mention of on this list of using "-quiet" (only one
dash), but "mythfilldatabase -quiet" gets me the response "illegal
option: '-quiet' (use --help)".  Interestingly enough, although it
doesn't complain about "--quiet", that neither "-quiet" nor "--quiet"
is mentioned in the output of "mythfilldatabase --help".

IMO, this is symptomatic of two distinct bugs:  1) --quiet isn't.
2) mythfilldatabase (or some external program called by it to
retrieve program data) is sending non-error output to stderr.
(Optional bug #3:  The output of "mythfilldatabase --help" does not
document the "--quiet" option.)

Does a patch or workaround currently exist which silences the routine
details without also throwing out notice of any errors which may
occur?  If so, what do I need to do to get that in place?  If not,
how do other people handle this and where should I look in the code
to create such a patch?  A quick look through
mythtv-0.18.1/programs/mythfilldatabase/filldata.cpp shows that it
doesn't send anything to stderr itself other than the "illegal
option: '%s' (use --help)" message and --quiet does suppress a large
amount of output, even though it doesn't appear to catch everything,
so it would seem that this needs to be fixed in a less-obvious place.

Output of this morning's run, as emailed to me, follows.  If you're
not interested in it, then there's nothing more to see here.  Move
along.

--- cut here ---

--06:25:49--  http://datadirect.webservices.zap2it.com/tvlistings/xtvdService
           => `-'
Resolving datadirect.webservices.zap2it.com... 206.18.98.160
Connecting to datadirect.webservices.zap2it.com[206.18.98.160]:80... connected.
HTTP request sent, awaiting response... 401 Unauthorized
Connecting to datadirect.webservices.zap2it.com[206.18.98.160]:80... connected.
HTTP request sent, awaiting response... 200 OK
Length: unspecified [text/xml]

    0K .......... .......... .......... .......... ..........  924.21 B/s
   50K .......... .......... .......... .......... ..........   93.30 KB/s
  100K .......... .......... .....                               3.34 KB/s

06:28:20 (1.98 KB/s) - `-' saved [128914]

--06:28:31--  http://datadirect.webservices.zap2it.com/tvlistings/xtvdService
           => `-'
Resolving datadirect.webservices.zap2it.com... 206.18.98.160
Connecting to datadirect.webservices.zap2it.com[206.18.98.160]:80... connected.
HTTP request sent, awaiting response... 401 Unauthorized
Connecting to datadirect.webservices.zap2it.com[206.18.98.160]:80... connected.
HTTP request sent, awaiting response... 200 OK
Length: unspecified [text/xml]

    0K .......... .......... .......... .......... ..........    1.53 KB/s
   50K .......... .......... .......... .......... ..........   89.79 KB/s
  100K .......... .......... ..........                          3.29 KB/s

06:29:50 (3.07 KB/s) - `-' saved [133493]

--06:29:59--  http://datadirect.webservices.zap2it.com/tvlistings/xtvdService
           => `-'
Resolving datadirect.webservices.zap2it.com... 206.18.98.160
Connecting to datadirect.webservices.zap2it.com[206.18.98.160]:80... connected.
HTTP request sent, awaiting response... 401 Unauthorized
Connecting to datadirect.webservices.zap2it.com[206.18.98.160]:80... connected.
HTTP request sent, awaiting response... 200 OK
Length: unspecified [text/xml]

    0K .......... .......... .......... .......... ..........    2.31 KB/s
   50K .......... .......... .......... .......... ..........  124.03 KB/s
  100K .......... .......... ...                                 4.05 KB/s

06:31:05 (4.44 KB/s) - `-' saved [126031]

--06:31:14--  http://datadirect.webservices.zap2it.com/tvlistings/xtvdService
           => `-'
Resolving datadirect.webservices.zap2it.com... 206.18.98.160
Connecting to datadirect.webservices.zap2it.com[206.18.98.160]:80... connected.
HTTP request sent, awaiting response... 401 Unauthorized
Connecting to datadirect.webservices.zap2it.com[206.18.98.160]:80... connected.
HTTP request sent, awaiting response... 200 OK
Length: unspecified [text/xml]

    0K .......... .......... .......... .......... ..........    7.99 KB/s
   50K .......... .......... .......... .......... ..........   71.32 KB/s
  100K .......... .......... .......... .........              141.59 KB/s

06:31:23 (19.23 KB/s) - `-' saved [142448]



More information about the mythtv-users mailing list