OT. Duplicating Disk.

Warren Block wblock at wonkity.com
Mon Sep 27 15:25:50 UTC 2010

On Tue, 28 Sep 2010, Jorge Biquez wrote:

> U have and "old" laptopn, an Acer Travelmate 4670. It has a sata disk, 120Gb. 
> It has been working fine in all these years. I have installed Freebsd with 
> its boot manager and inside has Windows and a distro linux. I choose what OS 
> to use depending on my needs every time I boot.
> My question is. What would be your advice on what tool to use to duplicate 
> entire disk? (the adjust of size for the partitions of each different OS can 
> be done later, no problem I guess).

Resizing partitions can be difficult.  FreeBSD's ufs has growfs(8), but 
otherwise resizing is usually done by dumping, resizing, and restoring.

Since you have Linux familiarity, I'd suggest http://www.clonezilla.org. 
It will make a backup of an entire disk, including binary copies of 
filesystems it doesn't understand, to 2G compressed files.  It can also 
copy device to device.  Later versions even recognize and understand UFS 

FreeBSD can also duplicate a disk byte-for-byte with dd(1).  Be warned: 
it will take a while, copying blank space as well as used.  Important: 
make a backup of the original drive somewhere else first (see above). 
When using dd for this, it's critical that the source and destination 
devices are correct.  To copy ad0 to da0 (make sure the source and 
destination devices are correct):

   # dd if=/dev/ad0 of=/dev/da0 bs=1m

The same thing can be done with Linux (Clonezilla provides a shell), 
although the bs parameter has to be 1M (case sensitive).

More information about the freebsd-questions mailing list