[mythtv-users] Previous recordings have disappeared

Stephen Worthington stephen_agent at jsw.gen.nz
Tue Jan 29 14:00:44 UTC 2019


On Mon, 28 Jan 2019 22:00:30 -0700, you wrote:

>> I can remember a bug that could do this to you, but I think it was
>> fixed before 0.27.  And crashed database tables can cause this, but
>> you have already checked for that.  You may have to delve deep and
>> turn on the database logging options to see what queries are being
>> done and then run those queries manually yourself to see what the
>> results are.  You should probably run find_orphans.py and see what
>> problems it can see in the database - but until you know what is going
>> on, I would not recommend letting it do any cleanups.
>
>I'm not great with databases but I can give that I try.  If you have a
>pointer to some more details about database logging, I'd appreciate
>it.  I trying adding "OPTIONS=--enable-dblog" to
>/etc/sysconfig/mythbackend and restarted the backend.  But I'm not
>seeing anything in /var/log/mythtv/ that looks like it has database
>commands.

The mythbackend command line has good help options to tell you what
you need for logging - just run "mythbackend --help" and "mythbackend
-v help". You can run those help commands at any time even if another
copy of mythbackend is running in the background.  I believe you would
need to add "-v database".  Be aware that turning on high impact
logging like full database output can slow things down, so it is best
to only do it when mythbackend is not busy recording.

The easiest way to do this is to run a command like "mythbackend
--setverbose database" which will tell the copy of mythbackend that is
already running to add the "-v database" logging.  You can turn it off
again with "mythbackend --setverbose nodatabase".  You can also change
the logging level using "mythbackend --setloglevel debug" to get more
detailed output.  Be careful when typing "mythbackend" commands - if
you do not have the options spelt correctly, you can wind up with a
second copy of mythbackend running in the background.  If that
happens, you can kill the second copy by doing this:

ps -ef | grep mythbackend

to see the process IDs (PIDs) of all copies of mythbackend and what
options they are running with, which should tell you which one you
need to kill.  Then kill it using:

kill <PID>

using the PID of the new mythbackend instance.


More information about the mythtv-users mailing list