View Single Post
Old 09-03-04, 08:37 PM   #1
satimis
Registered User
 
Join Date: Sep 2004
Posts: 10
Default Cloning hard drive with dump and restore commands

Hi folks,

Debian

I'm prepared to clone a hard drive of 7G capacity (ATA-33) to a new drive of 40G (ATA-100) with 'dump and restore' commands as follows;
(Remark: old and new drives of unequal capacity)

1)
connect ATA-100 drive as Primary slave

2)
# fdisk -l (to find the partitions on ATA-33 drive, e.g.)
Code:
   Device Boot      System
/dev/hda1   *       Linux
/dev/hda2           Linux
/dev/hda3           Linux swap
/dev/hda4 /var      Linux
etc.
3)
Make partitions on ATA-100 drive same as ATA-33 drive but of different capacity
# fdisk n /dev/hdb
etc.

4)
Then make following mount points (still on ATA-33)
# mkdir /mnt/boot
# mkdir /mnt/root
# mkdir /mnt/var

5)
# mount /dev/hdb1 /mnt/boot
# mount /dev/hdb2 /mnt/root
(/dev/hdb3 is swap)
# mount /dev/hdb4 /mnt/var

6)
Do follows;
Code:
# dump f - /boot | (cd /mnt/boot; restore rf -)
# dump f - / | (cd /mnt/root; restore rf -)
# dump f - /var | (cd /mnt/var; restore rf -)
Can folks on the forum shed me some light because I'm inexperienced on 'dump and restore' commands in particular cloning drives with them. This is my first time. I searched Internet but could not find identical case.

Furthermore I still face a problem about the cable. Old drive ATA-33 uses 40-wire cable but the new drive ATA-100 80-wire cable. 40-wire cable can go into the sock of a ATA-100 drive but a 80-wire cable can't go into the socket of ATA-33 drive because of a blind hole on its plug. I shall use a 40-wire cable connecting the new drive ATA-100 as slave. If it can't be detected by BIOS then I will connect the ATA-100 drive to Secondary IDE, removing the burner and CDrom temporily. Because 80-wire cable also can't go into the socket of burner and CDrom respectively.

Kindly advise. TIA

B.R.
satimis
satimis is offline   Reply With Quote