LinHES Forums http://forum.linhes.org/ |
|
how can I move recordings from myth A to myth B? http://forum.linhes.org/viewtopic.php?f=17&t=16390 |
Page 1 of 1 |
Author: | sonicshrub [ Sun Sep 09, 2007 10:56 pm ] |
Post subject: | how can I move recordings from myth A to myth B? |
Long story short, I would like to move recordings from one myth installation to another and need some help. I have R5a26(myth A) on a drive that I would like wipe and integrate into my r5c7(myth B)install. However there are a number of recordings that I would like to selectively move over to the r5c7 install before I wipe the drive. After reading the following forum posts: http://mysettopbox.tv/phpBB2/viewtopic.php?t=13329&highlight=merge+databases http://www.mysettopbox.tv/phpBB2/viewtopic.php?t=10195&highlight=merge+database I have a better idea of what needs to be done however I am still unclear on many steps. Since I am not going to be doing a new install do I just need to move the nuv files and sym links over while preserving ownership and permissions? Also I am not sure I follow the SQL myphpadmin part. I thought I had better ask for some help after reading the warning: Quote: IF YOU ARE NOT SURE HOW TO USE PHPMYADMIN OR MYSQL DON'T DO THIS !!!
Thanks |
Author: | cecil [ Sun Sep 09, 2007 11:41 pm ] |
Post subject: | |
Read the MythTV docs.... This is covered. |
Author: | Girkers [ Mon Sep 10, 2007 6:15 pm ] |
Post subject: | |
The other option would be to copy the files out of the Pretty directory and then put them into the Video directory of your other box. |
Author: | sonicshrub [ Tue Sep 11, 2007 4:46 pm ] |
Post subject: | |
Thank you both for your contributions and taking time to reply. Yesterday I may have done this completely wrong, so don't do this unless it has been blessed by someone who knows more about this than me, but so far it looks like things worked. Backed up both old and new databases with mythbackup I moved the contents of the pretty and tv folders: Code: cp -a /mnt/old/pretty/* /myth/pretty Code: cp -a /mnt/old/tv/* /myth/tv Then, I followed the instructions from the mythtv docs under section 23.7 http://www.mythtv.org/docs/mythtv-HOWTO-23.html#ss23.7 While it looked like all the old recording info made it, there were no previews for the old recordings nor could I watch them. Did a google and noticed something about blank basenames. Sure enough the old recordings had blank values in the recorded table's basename column. I don't know if I missed something or if this was just a result of moving nuv files in the format of chanid_startime_endtime.nuv ie 1046_20060123113000_20060123120000.nuv to my current version which uses chanid_startime.mpg I ran the following update: Code: UPDATE recorded SET basename = CONCAT(chanid, '_', DATE_FORMAT(starttime,'%Y%m%d%H%i00'),'.mpg') where basename = '';
Then truncated the filenames and changed .nuv to .mpg in /myth/tv folder. ie 1046_20060123113000.mpg. There is probably a real slick way to rename these in one line with regex but I did them by hand. I still have the old myth install intact and I have backups of the databases in case I really fubared this. |
Author: | Girkers [ Tue Sep 11, 2007 8:07 pm ] |
Post subject: | |
For reference the Pretty folder is simply symlinks to the TV folder with easy to read names. |
Author: | neutron68 [ Tue Sep 11, 2007 8:34 pm ] |
Post subject: | what is the trick? |
Girkers wrote: The other option would be to copy the files out of the Pretty directory and then put them into the Video directory of your other box.
Girkers, What is the trick to copying the symlinks in the PRETTY folder and getting the actual files they point at to come along during the copy process? You see, I've tried to copy items from the PRETTY folder from both a Knoppmyth command line and using the Linux xfe graphic file browser loaded on the Knoppmyth machine and all I ended up copying were the simlinks - no video files. Eric |
Author: | manicmike [ Tue Sep 11, 2007 11:06 pm ] |
Post subject: | Re: what is the trick? |
neutron68 wrote: Girkers, What is the trick to copying the symlinks in the PRETTY folder and getting the actual files they point at to come along during the copy process?
Hi Eric, The /myth/pretty symlinks are generated every 15 minutes (I think) as a cron job by matching up the file names with the real names in the database. They are regenerated regardless of whether they already exist. Mike |
Author: | neutron68 [ Wed Sep 12, 2007 9:03 am ] |
Post subject: | Re: what is the trick? |
manicmike wrote: Hi Eric,
The /myth/pretty symlinks are generated every 15 minutes (I think) as a cron job by matching up the file names with the real names in the database. They are regenerated regardless of whether they already exist. Mike Yep. I am familiar with how the symlinks get in the PRETTY folder, but that wasn't my question. Eric |
Author: | nharris [ Wed Sep 12, 2007 9:23 am ] |
Post subject: | |
These links may be of interest: http://www.mythtv.org/wiki/index.php/Up ... e_internet http://www.mythtv.org/wiki/index.php/Nuvexport |
Author: | tjc [ Wed Sep 12, 2007 6:21 pm ] |
Post subject: | |
The nuvexport utility has a mode specifically for this which dumps the SQL needed to import the file into another system. http://www.mythtv.org/wiki/index.php/Nuvexport#Export_to_.nuv_and_.sql |
Author: | Girkers [ Wed Sep 12, 2007 10:32 pm ] |
Post subject: | |
Let me preface this by saying there are many ways of doing what you want to achieve. My suggestion is simply that, my suggestion. Any way the reason your cp command didn't follow the symlinks is you specified the -a command. The cp man page states this: Quote: -a, --archive
Preserve as much as possible of the structure and attributes of the original files in the copy. Equivalent to --physical --preserve --recursive. -p, --preserve Preserve file owner, group, permissions and timestamps. -P|d, --physical|nodereference Don't follow symbolic links; copy symbolic rather than the files they point to. -r|R, --recursive Operate on the contents of directories recursively. So when you specify -a one of the options you are specifying is -P which tells it not to follow symlinks. To copy the file a symlink refers simply use the cp command and no options and you will be right to go. |
Author: | neutron68 [ Thu Sep 13, 2007 11:49 am ] |
Post subject: | thanks Girkers |
Girkers wrote: To copy the file a symlink refers simply use the cp command and no options and you will be right to go.
Thanks Girkers, that is exactly what I wanted to know. ![]() Eric |
Author: | sonicshrub [ Thu Sep 13, 2007 9:24 pm ] |
Post subject: | |
Thanks everyone. ![]() |
Page 1 of 1 | All times are UTC - 6 hours |
Powered by phpBB® Forum Software © phpBB Group http://www.phpbb.com/ |