You are not logged in.
Hi everyone,
I have a working Arch Install and I love it. The only problem is that I need to repartition my HDD. The partition scheme is just slightly different. One partition that is now logical will be primary and most partitions (except one) will be slightly larger but that's it.
Meanwhile I need to reinstall Windows (I have a dual boot), then "copy/paste" my whole Arch system back and reinstall GRUB. For now I can think of a few problems.
1) If I reinstall GRUB from a live CD (would it work with Arch's install CD ?), will pacman still handle updates for it ?
2a) A friend advised me to use rsync to copy ALL of my system to an external HDD (I have JFS and ext2/3 partitions) and then use rsync again to recover my system (I was thinking of using a JFS external hard drive). Is it a good idea ? Will this keep all the needed metadata (privileges and such) ? Will it preserve symlinks ? hardlinks ?
2b) Is rsyncing really better than just copy-pasting all files ?
3) I guess I'll have to change my /etc/fstab once I have repartitioned, are there any other files to edit when I have my new partition scheme ?
4) How can I check that nothing has been broken/corrupted in the process ?
Are there "better"/alternative ways to do what I want (Repartition disk, reinstall Windows and get back my whole Arch system) ? What other problems could I encounter ?
Thank you in advance for your answers and sorry for my English (it is not my first language).
Sorry for any English mistakes, I am not a native speaker.
Offline
Is there a problem in:
a> Repartition disk
b> Re-install 'doze [ *IF* the 'doze partition has been touched by the above step ]
c> Re-install Arch, from scratch ?
I presume there is an over-riding reason why the above will not do ?
Deej
Last edited by deej (2009-10-10 12:13:51)
Offline
Hi,
I'll reinstall Windows anyway because my university gives away licenses for Windows 7 and I currently have Vista installed (I hope they fixed a few things in Windows 7).
The reason I don't want to reinstall Arch from scratch is that I've spent tens of hours configuring everything this summer and now that (almost) everything works, I want to keep my config files and such.
Sorry for any English mistakes, I am not a native speaker.
Offline
You could simply burn your 'specially modified' configs to cd/dvd and use them
to replace the standard ones provided by a new install. On my system I have a
separate '/backup' partition [ wait for the screams "...a backup on the same hard
drive...!"; it's mine, I'll do what I like ], where I keep my configs. I have a script
I run on a new install to copy them over to the correct places, and the jobs done !
Deej
Offline
Use rsync, use tar, use "cp -a" ... whatever you're happy with, they all work.
I had a great day yesterday reconfiguring my laptop:
1) defragged vista on sda1
2) used a kubuntu livecd gparted to shrink the vista partition to 33 GB
3) used an arch live CD to transfer my two arch, kubuntu, and other partitions over the network to another pc (netcat)
4) set up a 150MB sda2 ext2 /boot
5) set up an encrypted sda3 over the rest of the disk
6) set up LVM2 on the encrypted partition
7) loaded back all the distros and file stores using netcat onto the new logical volumes
Went like a dream. There's enough on the Arch boot image. So if you forget to edit an fstab ist isn't a show-stopper.
And I find transferring an entire Arch partition far less work than installing from scratch - though I'd take the opportunity to re-install if I had a distro I thought might be broken somewhere.
Offline
For re-installing grub take a look up bootloader on the wiki. Pretty sure you'll just need to update fstab to get all your disks set back up again.
Setting Up a Scripting Environment | Proud donor to wikipedia - link
Offline
1) If I reinstall GRUB from a live CD (would it work with Arch's install CD ?), will pacman still handle updates for it ?
Should be fine. Grub doesn't change that often, and I don't think I've ever needed to re-do grub-install because of an update.
2a) A friend advised me to use rsync to copy ALL of my system to an external HDD (I have JFS and ext2/3 partitions) and then use rsync again to recover my system (I was thinking of using a JFS external hard drive). Is it a good idea ? Will this keep all the needed metadata (privileges and such) ? Will it preserve symlinks ? hardlinks ?
Yes, yes, and yes. However, so will cp -a. If you're just using an external drive attached to your local system to do this, cp -a should be fine.
2b) Is rsyncing really better than just copy-pasting all files ?
If you're copying to a separate machine over a network, I prefer rsync. It's easier than net-mounting the target drive and then copying to it, and network filesystems have a way of sometimes mangling ownership & permissions, depending what your setup is. This doesn't apply in your case though.
One caution about just copy&pasting your filesystem (not sure if this still applies with current udev, actually) -- you can't boot with a totally empty /dev. Copying all of the device entries from a booted, mounted /dev/ into your backup and then copying them back works fine, but it's probably better to do this:
mount -o bind / /mnt/temp-root
cp -a /mnt/temp-root/dev /your-backup-root/dev
umount /mnt/temp-root
That'll give you the device entries that are actually in your root filesystem's /dev, before /dev gets mounted on top of it.
3) I guess I'll have to change my /etc/fstab once I have repartitioned, are there any other files to edit when I have my new partition scheme ?
crypttab, if you have any encrypted partitions. /etc/suspend.conf if you're using userspace suspend (it'll need to know the new swap partition to resume from after s2disk). mdadm.conf if you have software RAID and are using that. Likewise for stuff in /etc/lvm (possibly).
4) How can I check that nothing has been broken/corrupted in the process ?
On your current system:
find / -type f -print0 | xargs -0 md5sum >> /big-file-checksum-list
When you've got everything copied back:
find / -type f -print0 | xargs -0 md5sum >> /big-file-checksum-list2
Then sort those two files and compare them.
Are there "better"/alternative ways to do what I want (Repartition disk, reinstall Windows and get back my whole Arch system) ? What other problems could I encounter ?
Some things I ran into while installing Windows 7:
- Win7 has a separate 100MB boot partition. As far as I know, it's not easy to pick an existing partition and tell it, "this is your boot partition." I just let the installer create it for me.
- Win7 does not obey some partition table conventions -- I can't edit my partition table with cfdisk because Windows 7 apparently got some disk geometry slightly wrong (You know that 8mb of free space that XP & NT used to leave at the end of disks? I don't think they've fixed that yet). fdisk, parted, and sfdisk are all OK though.
Edit: one of the Win7 problems turned out to be something else; removed it.
Last edited by thetrivialstuff (2009-11-04 19:34:27)
Offline