[mythtv-users] Database issue? Recordings not showing up in frontend

Michael T. Dean mtdean at thirdcontact.com
Wed Sep 16 11:25:22 UTC 2015


On 09/15/2015 08:36 PM, Mike Holden wrote:
>
> I've seen deletions fail in a similar manner to this when the backend 
> doesn't have permission to delete the file. This was probably a 
> version or 2 of mythtv ago for me, so may not be an observation on 
> current version, but I have had records stuck in this deletepending=1 
> state.

That should not be possible in any version of MythTV.  If you delete 
using mythfrontend (or MythWeb or find_orphans.py or whatever) to tell 
mythbackend to delete a recording and mythbackend does not have 
file-system permissions to do so, mythbackend will see the deletion 
fail, then will log an error message, then will put the recording back 
in the list (all of which may happen some time after the initial delete 
action, depending on your deletion settings and how much else you had 
just deleted).  Believe it or not, we actually have code to handle 
expected failures in MythTV.

Now, it's quite possible that you did this and had recordings "stuck" in 
the Deleted recording group--that's exactly what should happen.  
However, the deletepending flag would not be set (/would be unset as 
soon as the deletion failed).

That said, there is a race condition that can occur when you do not 
enable slow deletes and you do an unclean shutdown of the backend (kill 
-KILL/power interruption/bad crash/...) right after deleting a recording 
that will result in orphaned recordings in the deletepending state.  If 
you had recordings stuck like this, it was due to the race condition 
being triggered.

Mike


More information about the mythtv-users mailing list