[suse-sparc] RE: Cloning boot disk

From: Solarisexpert.com (submissions_at_solarisexpert.com)
Date: Wed May 08 2002 - 04:08:17 CEST

  • Next message: Ziegler, Bernd: "AW: [suse-sparc] Installation via NFS"

    From: "Solarisexpert.com" <submissions@solarisexpert.com>
    Date: Tue, 7 May 2002 22:08:17 -0400
    Message-ID: <IBEALMOLEDIGBEMJPPDAAEFMCDAA.submissions@solarisexpert.com>
    Subject: [suse-sparc] RE: Cloning boot disk
    

    >
    > On Tue, May 07, 2002 at 06:36:56PM -0400, Solarisexpert.com wrote:
    > > I have 2 SCSI hard drives, different geometries (1Gb vs. 9GB ;
    > dd will not
    > > work).
    > >
    > > How do I clone them (tar may be ok ?) so that my new disk
    > becomes bootable
    > > (meaning, what is the Linux equivalent of the solaris
    > 'installboot'?) and
    > > all the data is preserved ?
    >
    > Boot a rescue disk, mount both disks like in /target and /target2, then
    > do[1]:
    >
    > cp -a /target/. /target2/.
    >
    > When that's done, do:
    >
    > chroot /target2 /sbin/silo -f
    >
    > That should do it for you.
    >
    >
    > Ben
    >

    Well, moved more by laziness more than anything else, I partially took the
    advice here and I made a live copy of the disk with tar instead. I created a
    tarball on the new drive I had mounted under /mnt using a simple 'tar cvf
    /mnt/root.tar /' . Later on I changed directory and issued a 'tar xvf
    ./root.tar'.

    That could have probably been accomplished with a cleaner approach, using
    something like

    tar -cvO / | tar xv -C /mnt

    The version of tar I use under Solaris has a different sintax and I was not
    comfortable taking chances on my only good disk with my finally fully
    functional kernel and 4 days of work on getting the socal driver to work...
    I am pretty sure it will do the job.

    I almost forgot, make sure you use the --exclude flag on tar to keep at
    least /proc/kcore out of the tarball. If you forget, you will be reading
    through all of your physical memory. (I am not sure if you cn leave out all
    of /proc. I think this should be built dynamically every time the kernel
    initializes, but I am not sure if the kernel expects to find at least the
    mount points for the virtual filesystems... Any hints here ?)

    I stil needed the bootblock to contain the boot code. The line from Ben's
    recommendation above worked nicely for that purpose:

     chroot /target2 /sbin/silo -f

    which in my case was

     chroot /mnt /sbin/silo -f

    Regards

    Raoul Volpe
    Phone (877) 44 SOL EX (Toll Free)
    Phone +001 407 323 1668 (outside US)
    Fax +001 586 816 7086
    raoul.volpe@solarisexpert.com
    http://www.solarisexpert.com <http://www.solarisexpert.com/>

    
    
    

    -- 
    To unsubscribe, e-mail: suse-sparc-unsubscribe@suse.com
    For additional commands, e-mail: suse-sparc-help@suse.com
    



    This archive was generated by hypermail 2.1.0 : Wed May 08 2002 - 04:07:01 CEST