[wplug] Backing up (cloning) to a smaller drive...

Moshe Hyzon mokatz at gmail.com
Mon Aug 13 17:17:58 EDT 2007


I second the reccomendation to use dump and restore (man dump, man restore)

assuming you are using ext2/3, it is nearly painless.
1. Set up the emtpy partitions on the the destination drive
2. run the command(s)
3. wait
4. profit! ;P

Moshe Hyzon

On 8/13/07, scoob8000 <scoob8000 at gmail.com> wrote:
> On 8/13/07, Jonathan Billings <billings at negate.org> wrote:
> > Is there any reason why you have to have a clone of the filesystem?
> > Resizing lvm volumes is possible, as well as resizing ext3 filesystems,
> > but why go through the effort unnecessarily?
> >
> > I assume that you aren't using the full capacity of the original drive,
> > so you could always copy the data from one disk to the other, without
> > needing to clone the filesystem.
> >
> > One thing you could do is this:
> > I assume you have /dev/Old/Root as /, and /dev/New/Root as the new disk,
> > at /mnt/newroot.  I'd then run:
> >
> > cd /mnt/newroot;
> > /sbin/dump 0f - / | /sbin/restore rf -
> >
> > That'll copy all the data from / to /mnt/newroot.  Since this is LVM, I
> > suspect you'll also have to create and copy a /boot partition too, which
> > isn't in LVM.
> >
> >
>
>
> I guess I left a few details out.  :(
>
> The new drive is actually in a second machine with identical hardware as the
> first.
>
> I was tasked with putting together a server with the hardware we had at
> hand.  I was asked
> to make a second box the same as the first so if it would ever die, anybody
> would be able to unplug
> it and plug the backup unit in.
>
> You are correct in that the 40gb drives are nowheres near full.
>
> Typically I would use DD and Netcat for this.  Which is how I learned my
> second drive is just slightly smaller
> than the first.  Assuming the end of the drive is all zero's, is it safe to
> just ignore any errors I receive?
>
> -Mike
>
> _______________________________________________
> wplug mailing list
> wplug at wplug.org
> http://www.wplug.org/mailman/listinfo/wplug
>
>


More information about the wplug mailing list