Find the answer to your Linux question:
Results 1 to 5 of 5
Enjoy an ad free experience by logging in. Not a member yet? Register.
  1. #1

    laptop new hard disk

    I have a Suse 9.1 Pro install on a laptop plus YOU patches working nicely. This uses GRUB to boot between it and W2K.

    I need to upgrade to a bigger hdd and I don't want to re-install. Laptop allows me to replace dvd with 2nd hdd. So this means I can copy old-hdd stuff straight to new-hdd.

    I'm willing to try things myself but I hope someone can point out problems or say if the following is ok.

    Old-hdd has a Primary and Extended, Suse is on the 2nd last logical, swap is last. I can set up the partitions on new-hdd much the same but I want to have bigger Suse partition and I want extra logicals before Suse.

    The latter means that at present Suse is /dev/hda6 but would be /dev/hda10 when new-hdd is in alone.

    My plan is to do a minimal Suse install on empty partition of old-hdd. I boot up to it and make sure my working /dev/hda6 is unmounted. I mount the new-hdd and use MC (Midnight Commander) to copy hda6 to new-hdd. I then edit mtab and fstab on new-hdd to reflect what they will be when it's the only hdd.


    Is using MC to do copy ok and do I need to use particular options for permissions or such?

    Any thing else over mtab and fstab?

    As for GRUB on new-hdd, what about that? I thought of booting my Suse dvd and tell it to boot the new hda10 and then use YAST bootloader option.

    Would it matter if I changed the filesystem? If I set up the new-hdd as Ext3, but my present is reiser?

    I hope the above makes sense and appreciate any help.

  2. #2
    I did such an upgrade on my laptop recently and the instructions below worked fine for me.

    1. Install new HDD

    2. Boot to SuSE

    3. Partition and format new drive the way you want (generally first primary as swap, second as reiserfs)

    4. Become root
    5. Mount you new hdd somewhere, let's say /mnt/new

    6. Change to / folder and run the following command for all folders in "/"
    cp -dpr /bin /mnt/new
    where r-recursive, p-preserve all permissions, d-preserve all symlinks. Run this command for all folders but /proc and /mnt.

    7. When done chroot to your new drives root dir
    chroot /mnt/new
    8. Create proc and mnt directories
    mkdir proc

    9. You must be using grub under SuSE, in that case run
    to install bootloader. It will alert that no cpuinfo found in proc, but this is not critical message, ignore it.

    10. reboot

  3. #3
    One note: Replace you old HDD with new one. You may want to edit /etc/fstab and grub.conf (and maybe not only there) on your old drive later on to be able to boot from old hdd also.

  4. $spacer_open
  5. #4
    thanks for reply. Funnily, I saw a magazine letter today which mentioned using 'cp' for this pirpose!

    Am I right in thinking your cp'ing is done having booted into the normal working setup? I suppose that's why doing /proc later is needed. I thought that some other dirs/files also might object to being copied 'live' using MC if I tried it that way, which is why I was going to do a min new install.

    And, using the 'mkinitrd' obviously does something to the present install that might upset it if I kept the old-hdd and tried to boot it again. Is that right?

  6. #5
    cp is just a copy command, and using it with correct options (-d -p -r in your case) will keep permissions and symlinks the same. You can run it either from your running system, or boot from floppy or rescue cd, it doesn't matter. You can do copy in MC also, anyway this is just a file copy operation, but make sure to preserve all symlinks and permission while doing copy in MC.

    Running mkinitrd will not do anything on your old drive cause before that you chroot (change root) to your new drive.

    proc contents are not physically located on your hard drive, it is kernel being mapped on your /proc dir at runtime, thus it can not be copied. But empty /proc directory must exist.

    After completing 10 steps in my previous post your new drive is the bootable working copy of your old hdd.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts