[mythtv-users] find orphans.py question

Greg greg12866 at nycap.rr.com
Sat Apr 16 00:36:45 UTC 2011

On 04/15/2011 06:49 PM, Raymond Wagner wrote:
> On 4/15/2011 18:15, Greg wrote:
>> On 04/14/2011 03:05 PM, Raymond Wagner wrote:
>>> On 4/14/2011 12:00, richard Woelk wrote:
>>>> On 4/11/2011 9:56 PM, Greg wrote:
>>>>> On 04/11/2011 07:20 PM, Raymond Wagner wrote:
>>>>>> On 4/11/2011 18:41, Greg wrote:
>>>>>>> My question is why it didn't find the png's?
>>>>>> An orphaned snapshot is defined as an image with no matching recording
>>>>>> in the database.  A recording will have a basename like
>>>>>> 2047_20110410200000.mpg, so any file with '2047_20110410200000' in the
>>>>>> name will be presumed to match to that recording and be removed from the
>>>>>> list.
>>>>>>        Yes, I see that,but i was under the assumption,the script would delete all orphans,including the pgn files...My question is does it?
>>>>>>> One other question is why does it target my db_backup's?...I really don't want to delete my backups..
>>>>>> It doesn't target the database backups.  Backups are not listed anywhere
>>>>>> in the database, so it is not possible for them to be 'orphaned'.  The
>>>>>> script is merely listing which ones it has found.  If you look closer,
>>>>>> the script offers no option to delete these files.
>>>>>> _______________________________________________
>>>>>> mythtv-users mailing list
>>>>>> mythtv-users at mythtv.org
>>>>>> http://www.mythtv.org/mailman/listinfo/mythtv-users
>>>>>> Other files
>>>>>>         tvserver: /video3/db_backups/mythconverg-1270-20110401043002.sql.gz                         31.3MB
>>>>>>         tvserver: /video3/db_backups/mythconverg-1270-20110402043002.sql.gz                         30.2MB
>>>>>>         tvserver: /video3/db_backups/mythconverg-1270-20110403043002.sql.gz                         31.2MB
>>>>>>         tvserver: /video3/db_backups/mythconverg-1270-20110404043003.sql.gz                         30.3MB
>>>>>>         tvserver: /video3/db_backups/mythconverg-1270-20110404074419.sql.gz                         31.2MB
>>>>>>         tvserver: /video3/db_backups/mythconverg-1270-20110405043002.sql.gz                         31.4MB
>>>>>>         tvserver: /video3/db_backups/mythconverg-1270-20110406043002.sql.gz                         31.5MB
>>>>>>         tvserver: /video3/db_backups/mythconverg-1270-20110407043002.sql.gz                         31.7MB
>>>>>>         tvserver: /video3/db_backups/mythconverg-1270-20110410043002.sql.gz                         32.0MB
>>>>>>         tvserver: /video3/db_backups/mythconverg-1270-20110411170754.sql.gz                         30.5MB
>>>>>>         tvserver: /video4/recordings/1006_20110210200000_audio.aac                                  34.6MB
>>>>>>                                                                                         Total:     345.8MB
>>>>>> Please select from the following
>>>>>>        1. Delete other files
>>>>>>        2. Refresh list
>>>>> As you can see, it plainly lists my db_backups under other files....You
>>>>> say it don't offer to delete them...Why then does it say under item 1.
>>>>> Delete other files?  Looking at that, one would assume all files under
>>>>> Other Files would be deleted....
>>> The script on the wiki assumes any file with the string 'sql' anywhere
>>> in it will be a database backup file.  If you are running the script on
>>> the wiki, those files should not be showing up in the unfiltered list.
>>>         dbbackup = []
>>>         for f in list(unfiltered):
>>>             if 'sql' not in f:
>>>                 continue
>>>             dbbackup.append(f)
>>>             unfiltered.remove(f)
>>> The 'dbbackup' list they are filtered into are displayed, but not
>>> offered for deletion
>> It's not that I didn't believe you,I wanted to make sure It wasn't going
>> to delete my backups...Thanks for the script and your efforts ....
> What I'm saying is that the script, as it appears on the wiki, is
> supposed to filter any filename with 'sql' in it, and place it in the
> "Database backups" group.  If you are running the script on the wiki,
> and those are falling through to "Other files", then something strange
> is going on and I would look into fixing it.
> _______________________________________________
> mythtv-users mailing list
> mythtv-users at mythtv.org
> http://www.mythtv.org/mailman/listinfo/mythtv-users
I am running the script on the wiki..I ran a test today by coping the 
backups to another drive,then I ran the script.It worked fine and didn't 
delete my files... What I posted above is what shows up when I run the 
Update, I just ran the script again,and now the backups do show in the 
Database backup groups...I didn't do anything any different,so I have no 
idea what the problem could have been...
Thanks again for your time...

More information about the mythtv-users mailing list