You are not logged in.

#1 2004-08-29 23:12:40

mladen
Member
From: Home
Registered: 2004-03-03
Posts: 46

cloning HD with arch - different HDs --> working !

Hi all,

I want to retire my old 3.2GB disk after I clone it to a bigger one.
Followed previous threads on this and focused on Knoppix' liveCD and partimage - it works ok to the point when MBR or just bootloader needs to be written to new disk. Partimage reports an error (beforehand it advises on the different drive geometry), but I thought that is the known "glitch" that still allows proper (re)booting. It wasn't - on reboot, instead of lilo I get "L99 99 99 99 99 99...." etc.

Any comments or hints?

Also, I made my new drive partitions larger (apart from /swap - will have same RAM). One of the threads says that after partimage restores an image, it's possible to use parted to widen/expand it to the full extent of the new partition. Any issues here?


No past, no future. It's all one long, never ending present.

Offline

#2 2004-08-31 20:32:42

hypermegachi
Member
Registered: 2004-07-25
Posts: 311

Re: cloning HD with arch - different HDs --> working !

just use cp -a to copy everything from the old hd to the new hd.  don't include /proc, /tmp, or /sys (basically anything mounted as tmpfs)

Offline

#3 2004-09-02 10:30:35

mladen
Member
From: Home
Registered: 2004-03-03
Posts: 46

Re: cloning HD with arch - different HDs --> working !

:?  thanks hypermegachi,
I *will* give it a go once I clear out few other issues that might plague me even with your option.

Just to recap:  I've cloned (using partimage) my old HD to a new one. Can't make proper image/restore of the new MBR, so I'd like to manually install lilo to boot Arch from my new HD.

Now, I've followed archdoc.txt (installation CD) and did:

    boot with install CD;
    mount /dev/discs/disc0/part3 /mnt           (my root on the new HD)
    mount /dev/discs/disc0/part1 /mnt/boot   (my boot on the new HD)
    chroot /mnt
    lilo

It returns this (I'm concerned with the second line):
    "Warning: COMPACT may conflict with LBA32 on some systems.
     Fatal: raid-setup: stat("dev/disc/disc0/disc")  "


My lilo.conf:

   compact
   boot=/dev/discs/disc0/disc
   default=arch
   timeout=50
   lba32
   prompt
   image=/boot/vmlinuz26
        label=arch
        root=/dev/discs/disc0/part3
        read-only
        append="acpi=force"

Of course, help is greatly appreciated!


No past, no future. It's all one long, never ending present.

Offline

#4 2004-09-02 15:00:41

hypermegachi
Member
Registered: 2004-07-25
Posts: 311

Re: cloning HD with arch - different HDs --> working !

i'm not sure if it does or not, but if partimage uses dd to clone your partition you're gonna run into major problems.  i tried dd before and it worked like a charm.  the problem was that it was the same size, and when i tried to resize on the new bigger hard drive everything screwed up big time.  i think it had something to do with dd copying it exactly, so when you resize to make it bigger it gets confused or something because the old hard drive wasn't as big.

anyways, to your question, maybe removing "compact" at the top of your lilo.conf will get rid of that error.  i don't know what it does tho, i'm a grub fan.

Offline

#5 2004-09-02 21:53:11

mladen
Member
From: Home
Registered: 2004-03-03
Posts: 46

Re: cloning HD with arch - different HDs --> working !

smile  thanks!

I'm running out of time/options, so I'll just redo this with cp -a, as you suggested.

Cheers,  8)
mladen


No past, no future. It's all one long, never ending present.

Offline

#6 2004-09-04 04:54:34

mladen
Member
From: Home
Registered: 2004-03-03
Posts: 46

Re: cloning HD with arch - different HDs --> working !

big_smile heh, finaly.

FYI, I've done "cloning" between two different HD's without using any special software i.e. partimage or similar.

Steps involved:

- cfdisk new HD and made desired partitions (boot via installed Arch or Arch CD or any liveCD);
- reboot (for fstab to catch up - didn't know any better);
- mount desired partitions (old and corresponding new ones);
- cp -a * desired partitions one by one from old to the new HD (in my case it was /boot, / and /home);

At this stage the only remaining thingy is the proper MBR/boot loader, in my case lilo. And lilo was a huge pita - something was simply wrong. I've tried many variations and it was always complaining about ..." Fatal: raid-setup: stat("dev/disc/disc0/disc".

Only way/variation I found to make it work is :

- while booted via Arch CD;
# mount /dev/discs/disc0/part2 /mnt/         (my root on the new HD)
# mount /dev/discs/disc0/part1 /mnt/boot  (my boot on the new HD)
# /mnt/bin/mount --bind /dev /mnt/dev
# chroot /mnt
# lilo    (sure, lilo.conf has to be adjusted properly, along with the fstab).

This worked, though lilo reported small (?) error, but loaded fine upon reboot. When all was fine, I re-run lilo just to make it run latest version on its own and reported no errors.

All done. New HD "cloned" and running. Big thanks to hypermegachi 8) for cp -a idea  (though not sure would it work with plain cp).

Cheers,
mladen


No past, no future. It's all one long, never ending present.

Offline

Board footer

Powered by FluxBB