LinHES Forums http://forum.linhes.org/ |
|
Moving /myth/tv files, but keep the pretty names? http://forum.linhes.org/viewtopic.php?f=5&t=18132 |
Page 1 of 1 |
Author: | tzoom84 [ Thu Apr 03, 2008 4:24 pm ] |
Post subject: | Moving /myth/tv files, but keep the pretty names? |
I'd like to move some of the /myth/tv recordings to another storage location. However, I'd like to label them properly, as is done in the /myth/pretty directory. Is there any way to move a symbolic link with the file attached? Or merge the link with the file? Something like that, so I can have pretty file names without manually changing the recording names? Thanks ... yet again! |
Author: | Too Many Secrets [ Thu Apr 03, 2008 4:35 pm ] |
Post subject: | |
I just cp the /pretty file and the .mpg follows. cp /myth/pretty/Scrubs-03-03-03.mpg /storage/location/scrubs/ |
Author: | abigailsweetashoney [ Thu Apr 17, 2008 12:49 pm ] |
Post subject: | |
Too Many Secrets >> That really works?? The pretty files are just symlinks so I don't see how it could. I do vaguely recall though that R5F27 lets you put the mpg's in various directories, not just /myth/tv, is this true? Thanks, _abs |
Author: | tzoom84 [ Thu Apr 17, 2008 12:59 pm ] |
Post subject: | |
My issue is I am burning to DVD using k3b. So I can't really use the cp command unless I can 'hot-copy' files over, rather than using a burning client. |
Author: | tjc [ Thu Apr 17, 2008 5:15 pm ] |
Post subject: | |
abigailsweetashoney wrote: Too Many Secrets >> That really works?? The pretty files are just symlinks so I don't see how it could.
Yes, of course it does. It's fundamental to the way that symlinks work. With a 2 minute experiment you prove this to yourself: Code: root@black2:~# echo "I am a file" >real.file
root@black2:~# ln -s real.file fake.file root@black2:~# mkdir destination root@black2:~# cp fake.file destination root@black2:~# ls -al *.file destination lrwxrwxrwx 1 root root 9 Apr 17 19:17 fake.file -> real.file -rw-r--r-- 1 root root 12 Apr 17 19:16 real.file destination: total 12 drwxr-xr-x 2 root root 4096 Apr 17 19:17 . drwxr-xr-x 23 root root 4096 Apr 17 19:17 .. -rw-r--r-- 1 root root 12 Apr 17 19:17 fake.file |
Author: | hari [ Fri Apr 18, 2008 11:25 am ] |
Post subject: | |
I moved files from my /myth/tv directory to another disk to free up space, then created a symlink to the new location from /myth/tv (using the same filename). Since /myth/pretty symlinks to /myth/tv, everything still works; you're just following two symlinks now instead of one. |
Author: | cfoxga [ Fri Apr 18, 2008 1:21 pm ] |
Post subject: | |
tjc, I assume that tzoom84 is looking to have the symlink point to the new location (destination/real.file) instead of the old location(real.file). I'm not sure there is a way to do that easily, unless you like writing shell scripts. When I added a new HD to my system to increase storaged, I copied the /myth/tv files to the new drive, removed the /myth/tv directory, and then mounted the new drive as /myth/tv. Of course I stopped the myth and mysql applications first. Worked like a charm... Chris |
Author: | tjc [ Fri Apr 18, 2008 5:51 pm ] |
Post subject: | |
cfoxga wrote: unless you like writing shell scripts.
Guilty as charged. As a matter of fact memory says I've already written this one and published it somewhere around here. Search for something by me that says something about moving a file and leaving a symlink in it's place. It may include a discussion about enabling the MythTV option to have deletion follow links... I'll look in my bag of scripts to see if I can find the name of it... |
Page 1 of 1 | All times are UTC - 6 hours |
Powered by phpBB® Forum Software © phpBB Group http://www.phpbb.com/ |