[mythtv-users] hard disk died ... how to delete all recordings from the db? (which mysql tables to trunctate)

Michael T. Dean mtdean at thirdcontact.com
Mon Mar 10 15:48:44 UTC 2008


On 03/10/2008 10:58 AM, David George wrote:
> On 03/10/2008 09:42 AM, Ma Begaj wrote:
>   
>> my hard disk died yesterday while watching "two and a half men" :). I
>> just heard a few "click" sounds from the hdd in the mythbox and
>> mythfrontend stopped responding a few seconds later. instead of trying
>> to save data with "dd" or something else over ssh, I rebooted ...
>> xfs_repair cannot do anything (cannot find superblock, and it quits
>> with some "fatal error") .. If you have some kind of advice for me ...
>> I accept everything :)
>>
>> it was Samsung 500GB, 4-5 months old ... so be careful when you get
>> your new hdd :)
>>
>> I am getting a new hdd today/tommorow and I would like to delete all
>> recordings from the database which was on another hdd. And I don't
>> want to delete them with my remote or from mythweb because there a
>> 200-300 hundred recordings in the database.
>>
>> which mysql do I have to truncate to delete all recordings? I do NOT
>> want to delete my recording rules.
> You may be interested in this message which is similar to what you are 
> asking:
> http://www.gossamer-threads.com/lists/mythtv/users/316769#316769
>
> I had the same thing happen here and used myth.find_orphans.pl in the 
> contrib directory.  However it didn't allow me to set the programs to 
> re-record in case they come on again so I added a rerecord option to 
> it.  Here is a link to the patch:
>
> http://svn.mythtv.org/trac/ticket/4677
>
> This has actually been added to the latest trunk (after the .21 release 
> so it is not in .21).

Please, no.***  If using 0.21, you should go into mythfrontend's 
Watch/Delete Recordings screen.  Then, go to the "All Programs" category 
name (left column), and use Menu to "Add this Group to Playlist."  Then, 
use Menu to select "Playlist Options", then select "Delete" or "Delete, 
and allow re-record."

Note that you can do the same thing for 0.20; however, you won't be 
given the "Delete, and allow re-record" option.

Mike


*** Though myth.find_orphans.pl is not direct /manual/ editing of the 
database, it's an old script that, er, directly edits the database.  
There is a replacement script in the works (ticket #4599) that uses the 
MythTV Perl bindings, and that has (will have) MythTV do as much work as 
possible without direct editing of the DB.  However, in this 
circumstance--when mythfrontend has all the capability of doing what you 
want with just a few button presses--using mythfrontend (which is known 
to do things right) is preferred over using some contrib script (which 
may not have received as much loving as it should have while MythTV was 
changing around it).


More information about the mythtv-users mailing list