View unanswered posts    View active topics

All times are UTC - 6 hours





Post new topic Reply to topic  [ 3 posts ] 
Print view Previous topic   Next topic  
Author Message
Search for:
 Post subject: Files not deleted
PostPosted: Thu Jun 10, 2010 3:38 am 
Offline
Joined: Sat Mar 18, 2006 6:23 am
Posts: 70
R5.5
I have programs that are showing up in the System Status/AutoExpire List as deleted. They are months old. I used to have programs set not to delete immediately, but after 3 days. I turned the feature back to 0 days (delete immediately) and the programs are still there. The data files for the programs themselves are not there. The programs cannot be deleted, but KM thinks they are still there taking space. Inspection of the mythbackend.log shows

Code:
2010-06-10 05:15:26.692 Expiring 3146 MBytes for 1006 @ Mon Mar 29 20:00:00 2010 => Chuck "Chuck Versus the American Hero"
2010-06-10 05:15:26.700 mythbackend: Delete Recording: File /GetPlaybackURL/UNABLE/TO/FIND/LOCAL/FILE/ON/mythtv/1006_20100326020400.mpg does not exist for chanid 1006 at Fri Mar 26 02:04:00 2010 when trying to delete recording.
2010-06-10 05:15:26.707 autoexpire: Expiring Program: Expiring 3146 MBytes for 1006 @ Mon Mar 29 20:00:00 2010 => Chuck "Chuck Versus the American Hero"


that KM is trying to delete them, but is having a problem. I did the steps under RepairingMythConvergDB in the KM wiki and there were no errors.

How do I get rid the database of these pesky ghosts?


Top
 Profile  
 
 Post subject: Re: Files not deleted
PostPosted: Thu Jun 10, 2010 4:48 pm 
Offline
Joined: Sun Aug 28, 2005 7:07 pm
Posts: 821
Location: Melbourne, Australia
mkaz wrote:
How do I get rid the database of these pesky ghosts?


Hope I haven't misunderstood your problem. I'm assuming that your backend is trying to delete files that it's expecting to find in /myth/tv and it can't as they're already long gone. My solution would involve simply getting a list of the files and creating empty files with the same names that your backend can successfully remove.

If that's a reasonably accurate summary, here's how I'd do it:

Grep the log file for an appropriate string to retrieve the names of all the files and get them into a list.
E.g.
grep FIND /var/log/mythtv/mythbackend |grep LOCAL |awk -F/ '{print $10}'|awk '{print $1}' |sort|uniq > /root/orphans.txt

Check that this actually works (I just made it up). You can do this by removing everything after the last uniq. If you end up with a list of files in /root/orphans.txt that end in .mpg, you can then do this:

for i in /root/orphans.txt;do touch /myth/tv/$i;done

This will create empty files in /myth/tv that you can then delete.

If you didn't get the file names, chances are that my one minute one-liner is faulty. If you can't adjust this, I can do it for you.

Mike

_________________
*********************
LinHES 7.4
Australian Dragon
*********************


Top
 Profile  
 
 Post subject:
PostPosted: Thu Jun 10, 2010 6:38 pm 
Offline
Joined: Sat Mar 18, 2006 6:23 am
Posts: 70
That worked! Thanks a lot.


Top
 Profile  
 

Display posts from previous:  Sort by  
Post new topic Reply to topic  [ 3 posts ] 


All times are UTC - 6 hours




Who is online

Users browsing this forum: No registered users and 23 guests


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot post attachments in this forum

Jump to:  
cron
Powered by phpBB® Forum Software © phpBB Group

Theme Created By ceyhansuyu