[mythtv-users] recording name does not match database

F P zagor.fp at gmail.com
Thu Jun 17 07:58:30 UTC 2010


> ------------------------------
>
> Message: 14
> Date: Wed, 16 Jun 2010 13:27:26 -0400
> From: "Michael T. Dean" <mtdean at thirdcontact.com>
> Subject: Re: [mythtv-users] recording name does not match database
> To: Discussion about mythtv <mythtv-users at mythtv.org>
> Message-ID: <4C19097E.50001 at thirdcontact.com>
> Content-Type: text/plain; charset=ISO-8859-1; format=flowed
>
> On 06/16/2010 05:03 AM, F P wrote:
> > I have a mythbuntu 9.04 64bit working installation.
> > For several reasons I had to reinstall from scratch, still 9.04 64bit.
> > Before doing that, I did run the backup script mythconverg_backup.pl
> > as suggested here, on the mythbuntu upgrading page.
> > After 9.04 reinstallation, I stopped the backend, drop the database,
> > created a new one and finally restored the database with the twin
> > script mythconverg_restore.pl.
> >
> > All recordings are there, as well as channels ids and so on.
> > But the recordings point to the wrong filenames!
> > It seems somewhere in the process of backup/restore, the database was
> > converted from "numbered filenames" to "pretty filenames".
> > For instance, a "dr house" manual recording previously pointing to
> > "1000_20100613211000.mpg" now points to a file named "dr house (Manual
> > Record) - 2010-06-13, 9-10 PM - Sun Jun 13 21-10-00 2010.mpg".
> >
> > Is there any way I can rebuild the correct links between the database
> > and the real files?
> >
> > I've tried renaming a file to the name the database expects, and it
> > works, but doing that for 100+ recordings drives me crazy!!!
>
> MythTV doesn't do any file renaming (as part of normal usage or
> upgrades/backups/...).  The deprecated mythrename.pl script used to do
> so, but it has been replaced by a new script mythlink.pl, which only
> allows creating pretty, human-readable symlinks to recording files.  We
> explicitly removed the ability to rename files because of the problems
> it causes (with file name length limitations imposed by the file system,
> file system or OS file name reserved character differences, character
> encoding issues, etc.).
>
> Therefore, the only way you could have a backup with file names that do
> not match your recording files (assuming only MythTV-related programs
> ever touched the database) is if someone ran mythrename.pl (the old,
> deprecated script) after the backup was created (and used a really
> messed up format specifier).
>
> I don't see much of any way to fix the issue other than manually
> renaming the files (while it's easy to determine the proper file names,
> determining the current file names and how they relate to recorded
> program entries is much more challenging).  You can use the following
> query to get some information, which you could open in a spreadsheet
> program and use to figure out which file is for which recording.
>
> cat<< "EOF" |  mysql -u mythtv -p mythconverg 2>&1 | tee ~/recordings.txt
> SELECT title, subtitle, chanid, starttime, endtime, basename
>   FROM recorded;
> EOF
>
> Mike
>

Mike, thank you very much for your answer and your query.
I'll test it this evening.
I can assure you that nothing has been run beside the backup script: I am
the only one touching the system and I did all the operations one after the
other, in the same evening...

To summarize the sequence of operations I did:
Mythbuntu 9.04 working (with "numbered" names) --> mythconverg_backup.pl -->
upgrade to Mythbuntu 9.10 (went wrong) --> installation from scratch of
Mythbuntu 9.04 (preserving /home and /var/lib/mythtv) --> dropDB/createDB/
mythconverg_restore.pl --> database is there and populated but the filenames
in the db are long and pretty, while the recordings files themselves are
still with the numbered names.

Any more suggestions?
Francesco
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mythtv.org/pipermail/mythtv-users/attachments/20100617/93b6e81f/attachment.htm>


More information about the mythtv-users mailing list