Author |
Message |
kmkittre
|
Posted: Wed Oct 05, 2005 6:09 pm |
|
Joined: Tue Jul 12, 2005 8:01 am
Posts: 670
Location:
Salem, MA
|
Okay, I'm pretty sure that I am correct in my assumptions, but I thought I would check here to make certain that I'm not going to hose my system...
In the next week I'm going to be moving my Mythtv box from it's ugly tower to a pretty silverstone case. At the same time the processor and mobo are going to change too. Essentially, the only part of my Mythtv box that I'm moving is the HDs (two of them), the TV Tuner, and the video card.
Here's how I plan on doing this:
1. backup Knoppmyth using the utility from the frontend
2. backup XF86Config-4, lircd.conf, lirc to my desktop
3. move hardware
4. boot from Knoppmyth cd and do an "upgrade"
5. restore backed up files and update xine and other settings
Are there any issues with this? The only thing I can think of that might cause problems is my two hard drives. The VG should carry over when I move the drives, right? And upgrading Knoppmyth only writes over hda, right?
Another (sort of related) question: My mythtv setup right now is an 80GB drive and a 300GB drive. I just bought a 160GB drive. I would like to replace the 80GB with my 160GB, is there any easy way to do this? Could I mount the 160GB drive, backup EVERYTHING on the 80GB drive to it and then swap the drives out without any issues?
thanks in advance.
|
|
Top |
|
 |
tjc
|
Posted: Wed Oct 05, 2005 6:32 pm |
|
Joined: Thu Mar 25, 2004 11:00 am
Posts: 9551
Location:
Arlington, MA
|
See the write up for my cutover from black to black2. To copy the contents of one drive to another you just format and partition the new drive, then mount it and use something like:
Code: rsync -av /old_partion_1 /new_partition_1 rsync -av /old_partion_2 /new_partition_2
For more details do a " man rsync". BTW - I strongly suggest doing this in single user mode, or when booted from the CD with the source partitions mounted "read only".
|
|
Top |
|
 |
kmkittre
|
Posted: Wed Oct 05, 2005 6:57 pm |
|
Joined: Tue Jul 12, 2005 8:01 am
Posts: 670
Location:
Salem, MA
|
Where can I find this write up?
Could I just install knoppmyth on the new drive to ensure that I get the partitions right and then do the rsync?
Will rsync copy over the instructions for my VG?
How do I boot from the CD and mount the partitions as read only?
Thanks for your help tjc, was I correct in the first part of my post?
|
|
Top |
|
 |
tjc
|
Posted: Wed Oct 05, 2005 7:28 pm |
|
Joined: Thu Mar 25, 2004 11:00 am
Posts: 9551
Location:
Arlington, MA
|
kmkittre wrote: Where can I find this write up? The Tier 2 Hardware Recommnedations forum. kmkittre wrote: Could I just install knoppmyth on the new drive to ensure that I get the partitions right and then do the rsync? Should work. kmkittre wrote: Will rsync copy over the instructions for my VG? I'm not sure what the real question is... rsync will clone everything in the one file tree into the other file tree. However it works at the filesystem level above lvm and the lower level structure are another matter. It will copy any related files in the filesystem but you'll need to do the VG setup first. kmkittre wrote: How do I boot from the CD and mount the partitions as read only? Beyond the scope of this message. I wrote brief instructions for someone recently on how to use the CD as a rescue disk. A search should turn them up. kmkittre wrote: Thanks for your help tjc, was I correct in the first part of my post?
Pretty much. You would need to reinstall any add ons you've set up.
|
|
Top |
|
 |
kmkittre
|
Posted: Mon Oct 10, 2005 10:28 pm |
|
Joined: Tue Jul 12, 2005 8:01 am
Posts: 670
Location:
Salem, MA
|
Okay, I'm not quite getting the answers I need (at least it's not making sense to me)...
I set up my additional hard drive (the 300GB one) using this tutorial:
http://www.knoppmythwiki.org/index.php?page=LvmHowTo
I then added hda4 (on the 80GB drive) to the VG following the second part of that tutorial. I am currently using 212GB.
Is there any way for me to replace the 80GB drive without losing any of my media? Since I have the room, can I move all of the info (if any) in hda4 to the 300GB drive and drop hda4 from the VG?
I'm looking for a process. Can anyone help me out?
This is what I was thinking maybe you guys can point out my errors:
1) remove both hard drives
2) install 160GB only and install knoppmyth
3) slave 80GB drive and use telinit 1 to set to 1 user and then rsync the partitions
4) remove 80GB and add 300GB
5)? What's the status of my VG?
|
|
Top |
|
 |
kmkittre
|
Posted: Mon Oct 10, 2005 10:46 pm |
|
Joined: Tue Jul 12, 2005 8:01 am
Posts: 670
Location:
Salem, MA
|
okay, i've educate myself some more. This is my new plan:
1)backup knoppmyth using backup command as well as other important stuff to me (XFree86, lircd.conf, lirc)
2) move the data off of hda4 into the rest of the volume group using:
Code: pvmove -v /dev/hda4 3)remove hda4 from the VG using: Code: vgreduce dev /dev/hda4
4) remove both hard drives
5) install 160GB only and install knoppmyth
6) slave 80GB drive and use telinit 1 to set to 1 user and then rsync the partitions hda1, hda2, and hda3 (hda4 should be empty and need not be rsync'd, right?)
7)remove 80GB and put 300GB back in
 run an "upgrade" of Knoppmyth
9)follow instructions at http://www.knoppmythwiki.org/index.php?page=LvmHowTo in order to add hda4 on the 160GB drive to my VG.
thoughts?
|
|
Top |
|
 |
tjc
|
Posted: Tue Oct 11, 2005 7:27 pm |
|
Joined: Thu Mar 25, 2004 11:00 am
Posts: 9551
Location:
Arlington, MA
|
Actually given this plan all you would need to sync is the former /dev/hda1 (remember as a slave it's going to show up as a different device) The swap and cache partitiions shouldn't contain anything that you need or want to sync.
|
|
Top |
|
 |
kmkittre
|
Posted: Thu Oct 13, 2005 10:01 am |
|
Joined: Tue Jul 12, 2005 8:01 am
Posts: 670
Location:
Salem, MA
|
Update:
If you followed the instructions on the wiki, you cannot do pvmove because there are no free extents in the VG. I got around this by reducing the size of the logical volume (lvreduce), however I corrupted a few files in the process (I am not sure of the total extent, but at least 5 of them are unplayable). I also ended up corrupting the file structure (fsck would not run properly).
What I ended up doing (and would have been better to begin with)
1) buy a new hard drive that can hold all of your media (for me, this was a 200GB drive)
2) copy all your media on to the new hd
3) restructure your vg (I ended up fdisk'ing and re-doing the vg because of the corruption)
4) after your new system is configured copy the media back to your (possibly new) vg
I'll post more updates as I go along. This has been fun and frustrating at the same time (I'm learning a lot)
|
|
Top |
|
 |