[K12OSN] restore backup with chroot + grub-install

Robert Arkiletian robark at telus.net
Sat Dec 11 06:14:39 UTC 2004

Robert Arkiletian wrote:

> I backed up our RH9 server today using tar to save both / and /home 
> partitions to a mobile drive. Wondering if I can use a different 
> version of grub to restore once I untar to the new drive. I'm thinking 
> "chroot /sbin/grub-install". (Not sure of syntax for chroot and 
> grub-install). Can someone explain it.  Do I use grub on gnoppix or 
> the untared RH9 that I'm restoring? Also booting with gnoppix, grub is 
> version .95 and in RH9 it's 0.93. Does it matter if the version of 
> grub is different? BTW the server has / on /dev/sda1 and the backup 
> drive with the tar files is /dev/hdb3 which I would mount from gnoppix 
> as /mnt/hdb3
After some reading I'm going to take a guess. After I
1) fdisk the brand new drive to the same parameters as before and
2) then mke2fs -j the filesystem.
3) Then mount it (/dev/sda1) from gnoppix as /mnt/sda1
4) then untar my backup from mobile drive to the new drive
5) then  chroot /mnt/sda1 /sbin/grub-install /dev/sda
6) then umount /dev/sda

Line number 5 is the one I want confirmation on.


More information about the K12OSN mailing list