LinHES Forums
http://forum.linhes.org/

imdb info + poster images getting wiped out
http://forum.linhes.org/viewtopic.php?f=6&t=3345
Page 1 of 1

Author:  Russ [ Wed Jan 26, 2005 11:40 am ]
Post subject:  imdb info + poster images getting wiped out

I'm running a KnoppMyth r4v5 front+backend box and one XBox frontend-only box. I rip DVDs on the XBox frontend because my backend has no DVD drive yet, and watch them on both machines. So far so good, until I rename the video files and pretty them up with imdb metadata and poster pics.

Here's what's happening: on the KnoppMyth box I can rename the video and successfully grab the imdb info and poster image. It looks great and as long as I watch videos on the KnoppMyth box everything is fine. But, if I then try to watch videos on the frontend XBox, every video's metadata gets wiped out (reverts to the default names, no imdb number, no notes, no poster file). If I do the opposite, i.e. grab the imdb data on the Xbox, just the opposite happens, i.e. looks ok on the Xbox until viewing on the KnoppMyth box wipes out the metadata. In either case, the metadata is clobbered on both machines - not just the one which first triggers the erasure.

Thinking that the error was caused by poster files grabbed on one machine not being available to the other, I tried sharing the poster directory by moving it to a new dir /myth/posters (which is exported through NFS to the XBox along with the rest of the /myth tree), and setting both machines to use this as the poster file location. This didn't help (although I now only have/need a single copy of the poster image file, which is not a bad thing I suppose).

Any tips on where to look or how to fix this would be appreciated.

-Russ

Author:  cesman [ Wed Jan 26, 2005 1:15 pm ]
Post subject: 

Take a gander at LinHES.

Author:  Russ [ Wed Jan 26, 2005 2:15 pm ]
Post subject: 

Thanks - I see how you apportioned hard drive space between the two systems and mapping the image_cache/MythVideo dir so both machines see the same image files but I didn't do a very good job highlighting my problem. I'm trying to figure out why bringing up the video menu on one machine clobbers all imdb metadata entered at the other machine. AKAIK there is only one table with imdb info, in the backend server's MySQL database. Then again, I could be totally clueless about what in LinHES config deals with all this :D

Author:  Russ [ Wed Jan 26, 2005 11:20 pm ]
Post subject: 

Further to my last post, it now appears that the video metadata gets deleted when entering the video manager in the other machine. After perusing /var/log/mysql.log I think I know what's happening and Cecil's answer is making a lot more sense to me now. :wink:

Author:  cecil [ Thu Jan 27, 2005 12:10 am ]
Post subject: 

There is a method to my madness.

Author:  Greg Frost [ Thu Jan 27, 2005 4:56 am ]
Post subject: 

Russ wrote:
After perusing /var/log/mysql.log I think I know what's happening and Cecil's answer is making a lot more sense to me now. :wink:

Well then it behooves you to spell it out a bit so that others that find your post searching for a similar solution can benefit from your insightful interpretation of cecil's understandably brief but cryptic response.

Author:  Russ [ Thu Jan 27, 2005 5:49 am ]
Post subject: 

It was late and I still have a few things to do. Once it's working 100% a full writeup will be posted.

Author:  Russ [ Fri Jan 28, 2005 9:53 am ]
Post subject: 

Here's the scoop: This problem arose because the video manager stores the full path name of the video and poster files in the database. In my case, the KnoppMyth backend had this set to /myth/video and the front end XBox had it set to /mnt/store/video. /myth/video is exported via NFS to /mnt/store/video so both boxes are looking at the same directory - they're just known by different names. Same with the poster directory /myth/poster and /mnt/store/poster. This was the root of the problem.

Ripping a DVD on the Xbox causes two main things to happen: a video file is created in /mnt/store/video, and a default entry in the video manager table (don't have the table name handy sorry) is created which contains the full path to the file name, i.e. /mnt/store/video/videofilename. Now, if you then populate the imdb info using the video manager, all the information is related to the file /mnt/store/video/videofilename. The poster file is saved in /mnt/store/poster/posterfilename.

Moving over to the backend machine, we can play video fine because the /myth tree is exported to the /mnt/store tree on the backend. But the backend is looking for the poster file in /mnt/store/poster, which it cannot find because that path does not exist on that machine!

Moreover, if you then go into the video manager, it looks for files in /mnt/store/video since that's what's been stored in the database. Not finding them, it apparently assumes they were deleted, and deletes those records. Then it scans for new video files and finds what it thinks are "new" files (actually the same files) in /myth/video, and adds them to the database with default values. Blammo, your imdb info is now wiped out.

The solution is blissfully simple:

1) On each machine in your Myth environment set the videos settings default path names to the same thing. I chose the real path on the backend:

Code:
in utilities/setup>setup>media settings>videos settings>general settings

"directory that holds videos" = /myth/video
"directory that holds movie posters" = /myth/poster

2) create a symlink on the front end to point /myth to /mnt/store:

Code:
$ ln -s /mnt/store /myth


That's it.

Page 1 of 1 All times are UTC - 6 hours
Powered by phpBB® Forum Software © phpBB Group
http://www.phpbb.com/