[mythtv-users] Confused about MBE/SBE boxes and myth.find_orphans.pl

stuart stuart at xnet.com
Thu May 28 13:54:02 UTC 2009



Ronald Frazier wrote:
>> So why does a run of myth.find_orphans.pl on the SBE box identify this
>> recording as one that should be purged? :
>>
>>> myth.find_orphans.pl --host=mbe_box --dbhost=mbe_box
>> ...
>>> unknown file [6.1GB]: /space/recordings/1201_20090509050000.mpg
> 
> 
> Have you looked to see what the path stored in the database is? I'm
> wondering if you've somehow got it setup so that this file is
> accessible via multiple paths through different storage groups. Maybe
> it's finding the file twice, and one of the times the path in the DB
> isn't matching what it's looking at.

How do you go about finding the path?  I looked at the data base dump 
and do not see any path information around the "1201_20090509050000.mpg" 
pattern.

Some background - if that would help:

=== The following was done on the assumption that the current mythtv 
applications would handle moving recordings between MBE and SBE as well 
as between different directories on those machines all of which are 
actively being used by mythtv ===

1) On the SBE there are 2 partitions containing recordings.
2) One of these partitions was also / ("root") - yes, I know, a bad thing.
3) So, I moved all the recordings out of the / ("root") partition and 
into the other partition on the SBE and on the MBE machines.
4) That done, I shrank the / ("root") partition and created a new 
partition just for recordings.

6) Just to add a bit more confusion - I should add that, somewhere 
during the past several weeks, I must have run the myth-rename utility 
accidentally.  That is, I managed to give many myth recordings in the 
recording directories on both the MBE and SBE real names.  I don't think 
that effected the myth-frontends.  That is, I was still able to play 
back these recordings.  However, I do not know how this effected 
myth.find_orphan.  I suspect the myth.find_orphan utility works fine 
with the actual recordings - but falls apart on the many png files.  I 
witnessed many many png files being deleted on my MBE (not all of them, 
but more then the one associated with the "marked for deletion" mpg files).
---------

Now, running myth.find_orphans_dir on the MBE produced reasonable 
results.  It didn't find any data base problems and only found about 
half a dozen recording it wanted to delete because of no data base 
entry.  So I went ahead and ran it for real deleting about half a dozen 
recordings.  But, as mentioned above, it did delete a disturbing number 
of png files.

On the the SBE box.  The is where it all falls apart.  I tried doing a 
dry run:

myth.find_orphans.pl --host=MBE --dbhost=MBE
...and got this:
   Host: MBE, Directories: /space/recordings
   0 valid recordings, 145 missing recordings not fixed, check above is 
valid and use --dodbdelete to fix
   0 known media files using 0B
   46 orphaned thumbnails with no corresponding recording
   46 unknown files using 175.5GB not fixed, check above and use 
--dodelete to clean up if the above output is accurate

...No valid recordings???  Ok, this must be pilot error, so I did this:
myth.find_orphans.pl --host=SBE --dbhost=MBE
...and got this:
   Host: SBE, Directories: /space/recordings /more_space/recordings
   101 valid recordings, 13 missing recordings not fixed, check above is 
valid and use --dodbdelete to fix
   202 known media files using 457.9GB
   176 orphaned thumbnails with no corresponding recording
   97 unknown files using 182.4GB not fixed, check above and use 
--dodelete to clean up if the above output is accurate

...Well, now I have 101 valid recordings.  But I 97 unknown files!!!!  I 
am sure I don't have that many files lying around which can not be 
played!!!  If I ran myth.find_orphans on this machine for real I would 
be deleting about a third of my mythtv recordings (half of what I have 
on this machine)!!!

The OP w/the question about the "1201_20090509050000.mpg" file is in 
fact one of these "orphaned" files.  It's a file I can play back through 
a mythfrontend fine.  And if I rename it, that instance of mythfrontend 
will not be able to find it.  So, yes, this is the file that is known to 
myth.  However, it still shows up when I run myhth.find_orphans.

Any help will be appreciated & thanks for ploughing through this 
posting.  I know it was long, but I thought I had left way too much out 
of the PO for anyone to help me out.

-thanks




More information about the mythtv-users mailing list