View unanswered posts    View active topics

All times are UTC - 6 hours





Post new topic Reply to topic  [ 12 posts ] 
Print view Previous topic   Next topic  
Author Message
Search for:
PostPosted: Mon May 22, 2006 1:37 pm 
Offline
Joined: Sun Jul 03, 2005 9:50 pm
Posts: 23
I recently upgraded from R4A22 to R5B7. I did this because I got a new hard drive -- I wanted to put my puny 80 gig out to pasture and install a new 250. Unfortunately, my mythbox's MB was too old to break the 137 gig limit, so I had to drop the new drive in my desktop (Windows) computer and share it out. I installed R5B7 anyway, since I had created a few different problems with my old install, and it seems to be back up and running pretty well now. I have the new drive (in a remote box, remember) mounted as /myth/tv, such that most of the filesystem is local, and only recordings get stored on the networked drive. This seems to work pretty well, but I have an issue (small) and a request (large).


Issue: I'm pretty sure that the samba share doesn't mount up when I reboot. In my fstab, I've got:
//box/mythtv /myth/tv smbfs user,dmask=777,fmask=777,rw,guest,lfs 0 0
I just added the "user" since the last reboot, so if that's the fix, uh, forget I asked :oops:. Otherwise, please fire away.


Request: I've got a lot of wiggle room on the local box, with that 80 gig drive. Only 5 gigs go to root, and 512 to swap (settings chosen by auto-install), so the rest is all for /myth, which under the current setup will not be holding much. So, what I'd love to do is, record the shows to the local disk (somehow), then periodically move them off to the networked drive (somehow), while making sure myth can still find them to play them back (again, somehow). Obviously, I can do any one of those steps independently, but all at once is the sticky wicket. I could probably, if forced, come up with a cron job that does the moving; say, clear the local recording directory out every night at 3AM or something. The problem is, I don't know how to tell Myth they've been moved.

Is there any easy solution to this I'm overlooking, or unaware of? Or is this just not going to happen? I can live with my current solution, but I'm not happy about it. I watch recordings almost exclusively from my Xbox, which means that when a show is recording while I'm watching something, my 100 mbit network is really getting hammered. I could upgrade to gigabit, maybe, but I'd be much happier just moving the network loading to a time when I'm sound asleep. If anybody has the mojo for this, I'd be much abliged.


Top
 Profile  
 
 Post subject:
PostPosted: Mon May 22, 2006 7:30 pm 
Offline
Joined: Tue Nov 22, 2005 7:57 pm
Posts: 295
Location: Auckland, New Zealand
Quote:
The problem is, I don't know how to tell Myth they've been moved.

The easy way is to move files then create a symlink to the new location (in the original location). Symlinks take up no space. There is a setting in mythtv to tell it to follow symlinks when deleting files which will keep everything tidy if you delete stuff.

_________________
HP VL400 (PIII 866), Skystar2 2.6D, PVR350, Nvidia FX5200, 384MB, 200GB, KnoppMyth R5.5


Top
 Profile  
 
 Post subject:
PostPosted: Tue May 23, 2006 9:57 am 
Offline
Joined: Sun Jul 03, 2005 9:50 pm
Posts: 23
Now, see, why didn't I think of that? So, if I have a cron job that moves the files in the middle of the night, then symlinks them back to /myth/tv (on the local disk), that would work? Can anybody give me any pointers to a good reference on setting up cron jobs? Or, if anybody already does this, maybe you can tell me how best to go about it?


Top
 Profile  
 
 Post subject:
PostPosted: Tue May 23, 2006 3:34 pm 
Offline
Joined: Sun Jun 12, 2005 2:39 pm
Posts: 464
Location: UK
Making the script is the tough part, cron is easy :) http://en.wikipedia.org/wiki/Crontab

basically at a shell type:

crontab -e

then enter:

0 5 * * * /full/path/to/script >>/var/log/script.log

that will run your script at 5am everyday :)


Top
 Profile  
 
 Post subject:
PostPosted: Wed May 24, 2006 9:03 am 
Offline
Joined: Sun Jul 03, 2005 9:50 pm
Posts: 23
Thanks! It turns out, though, that 70ish gigs of "temp" space (~35 hours) should be enough that I can "run the script" manually most of the time. In effect, all I have to do is move any files that aren't linked, then softlink to them. The only problem I have is how to tell it to only move files that aren't symlinks. If there's a way to do this using the mv command, or maybe by piping the output of ls to mv, I haven't figured it out yet. Is this easier than I'm trying to make it?


Top
 Profile  
 
 Post subject:
PostPosted: Wed May 24, 2006 10:16 am 
Offline
Joined: Sun Jun 12, 2005 2:39 pm
Posts: 464
Location: UK
This command will move all files (not links) in the current directory to the /root/ folder

Code:
find -type f -exec mv {} /root/ \;


hope that helps ;)


Top
 Profile  
 
 Post subject:
PostPosted: Wed May 24, 2006 4:24 pm 
Offline
Joined: Thu Mar 25, 2004 11:00 am
Posts: 9551
Location: Arlington, MA
You probably need to quote the curly brackets too...


Top
 Profile  
 
 Post subject:
PostPosted: Sat May 27, 2006 5:44 am 
Offline
Joined: Sun Jul 03, 2005 9:50 pm
Posts: 23
This is why I never learned shell scripting properly -- you never know when you need to back-tick something, or escape it, or... I'd really like it if I could just pass some argument to ls that only gives me links, then pipe that to the mv command (or similar). As it is, I'll probably just brute-force move everything, and let the existing files fail. Same with the linking, I think. Unless that can get me in trouble?


Top
 Profile  
 
 Post subject:
PostPosted: Sun May 28, 2006 1:22 am 
Offline
Joined: Wed Mar 03, 2004 7:43 pm
Posts: 748
Location: Sydney, Australia
Ghengis, another way to do all this would be to have two hard disks in your your Linux PC.

Keep the 80GB one as is, but then add the 250GB one (which I think the BIOS can happily ignore the size of because it is not booring from it) as a mount on /myth/tv for your recordings.

I have been using a setup like this (80G + 150G) ever since I outgrew my 80Ger. Apart from a small challenge when upgrading (remembering to edit fstab) it is easy.

_________________
| Nigel Pearson, nigel.pearson.au@gmail.com
| "Things you own end up owning you" - Tyler, Fight Club


Top
 Profile  
 
 Post subject:
PostPosted: Sun May 28, 2006 10:19 am 
Offline
Joined: Sun Jul 03, 2005 9:50 pm
Posts: 23
I have not tried dropping my 250 gigger into the Linux box to see if I can successfully write to the whole thing; I wouldn't really know how to anyway. There's a little hiccup since I've already got a fair amount of data on it, and it's marked as a WinXP Dynamic Drive now, with it and one partition of another drive "merged" (I think Dynamic Disk is a lot like LVM, which I don't know much about). If I could find some place to offload the current contents of the drive (obviously, this will be easier the less I have on it...) I'd be able to reformat it, drop it in my myth box, and find out, but that's not likely to happen any time soon.

As it stands, the current scenario (record to Mythbox; move/softlink periodically) seems to be working out. I think I can safely just mv * and it will ignore the existing files, which should be fine. The ln command seems to have similar behavior.


Top
 Profile  
 
 Post subject:
PostPosted: Sat Jun 10, 2006 7:32 am 
Offline
Joined: Sun Jul 03, 2005 9:50 pm
Posts: 23
I have a new problem now: if my off-box storage goes down (e.g., the Windows box has to reboot), myth basically grinds to a halt waiting for samba timeouts on *every single linked file*, e.g. when the frontend wants to get the recording list. Is there an easy way to fix this? Nothing comes to mind...


Top
 Profile  
 
 Post subject:
PostPosted: Sat Jun 10, 2006 9:19 am 
Offline
Joined: Sun Sep 05, 2004 7:06 pm
Posts: 690
Are you sure that the 137gb barrrier still exists in R5B7?
I mean did you actually test it out?

With R5B7 and R5C7 I have successfully installed a 300GB drive in an old 1ghz machine with that limitation. In prior versions of Knoppmyth it was a problem and I tried everything to get it working. However, you can now do it without a card like Promise.

The only issue is that when you reboot the machine, bios does not recognize the drive. So you have to save the config first with no drive, and then it reboots again and bios finds a 137GB drive, save it again and then it reboots. The third time it boots, Lilo starts with the whole 300gb.

So basically bios can see 137GB and it will never see anything more than that amount. But what really matters is that Linux is able to see the whole drive. In my case I have an issue with Air2PC slow locking on startup and this lead to leaving my box on most of the time so I hardly ever notice this issue. It my opinion this will be the solution with the least number of tradeoffs and you should be able to keep moving up as you fill up the drive ...)


Top
 Profile  
 

Display posts from previous:  Sort by  
Post new topic Reply to topic  [ 12 posts ] 


All times are UTC - 6 hours




Who is online

Users browsing this forum: No registered users and 15 guests


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot post attachments in this forum

Jump to:  
Powered by phpBB® Forum Software © phpBB Group

Theme Created By ceyhansuyu