Opened 10 years ago

Closed 10 years ago

#7692 closed defect (fixed)

Autoexpire no longer gracefully deals with missing recordings

Reported by: Marc Randolph <mrand@…> Owned by: Isaac Richards
Priority: minor Milestone: 0.23
Component: MythTV - General Version: 0.22-fixes
Severity: medium Keywords:
Cc: Ticket locked: no

Description

Forwarding from downstream:

Summary is that the AutoExpire? in 0.21 checked that each expire succeeds and if it doesn't tries another file. That appears to be broken in 0.22.

First here's a log from 0.21 where autoexpire ran during a recording (extra required set to 1gb):

2009-09-18 03:36:28.229 AutoExpire?: CalcParams?(): Max required Free Space: 2.0 GB w/freq: 15 min 2009-09-18 03:36:28.324 ProgramInfo?, Error: GetPlaybackURL: '1061_20090903220000.mpg' should be local, but it can not be found. 2009-09-18 03:36:28.327 Expiring 4452 MBytes for 1038 @ Sun Sep 6 00:00:00 2009 => Babe

notice how it failed to delete the first file, but got a round this by deleting a second.

Now here's a similar log from 0.22 (extra required set to 5gb):

2009-11-27 14:59:13.207 AutoExpire?: CalcParams?(): Max required Free Space: 6.0 GB w/freq: 15 min 2009-11-27 14:59:13.307 ProgramInfo?, Error: GetPlaybackURL: '1061_20090903220000.mpg' should be local, but it can not be found.

This time notice how it only attempted to delete a single file (and this failed); subsequent logs show it making further attempts to delete that same file. Eventually either the disk fills (what I was seeing), or auto-expire detects that to free up the required space it should delete multiple files.

Most obvious cause of this would be a program or system crash, or the file somehow being accidentally deleted. Regardless, filling up the hard drive is a pretty harsh punishment for someone not manually catching this - especially if they weren't aware that the crash happened to begin with (if mythbackend is auto-restarted, for example).

Change History (3)

comment:1 Changed 10 years ago by sphery

Milestone: unknown0.23
Status: newinfoneeded_new
Version: unknown0.22-fixes

Does this still happen in trunk with r23054 or higher?

comment:2 Changed 10 years ago by Paul Kendall <paul@…>

This does not seem to be a problem any more. I have a full recording disk which I renamed some of my early recordings and setup a whole swag of new recordings. When AutoExpire? ran, it said in the log...

2010-02-01 10:14:32.630 AutoExpire: CalcParams(): Max required Free Space: 1.0 GB w/freq: 8 min
2010-02-01 10:14:32.638 ProgramInfo, Error: GetPlaybackURL: '1001_20100131213000.mpg' should be local, but it can not be found.
2010-02-01 10:14:32.652 ProgramInfo, Error: GetPlaybackURL: '1001_20100131234500.mpg' should be local, but it can not be found.
2010-02-01 10:14:32.654 ProgramInfo, Error: GetPlaybackURL: '1002_20100201081500.mpg' should be local, but it can not be found.
2010-02-01 10:14:32.655 ProgramInfo, Error: GetPlaybackURL: '1002_20100201084000.mpg' should be local, but it can not be found.
2010-02-01 10:14:32.657 ProgramInfo, Error: GetPlaybackURL: '1001_20100201090000.mpg' should be local, but it can not be found.
2010-02-01 10:14:32.657 Expiring 1332 MBytes for 1002 @ Mon Feb 1 09:00:00 2010 => Korero Mai - Speak To Me

So, it has tried multiple files until it finds one it can delete.

comment:3 Changed 10 years ago by danielk

Resolution: fixed
Status: infoneeded_newclosed

Paul, thanks for testing this.

Note: See TracTickets for help on using tickets.