May 042012
 

Taken verbatim from a post to tech@openbsd.org from December 2001, found here. Triple check parameters and think before running dd on a mounted disk.

Shouldn’t be run on a live disk, so here’s an alternative.

WARNING: This will also clone the disk UID. Which means that if fstab mounts the disk by UID instead of device, as it does by default for OpenBSD 5.0+, it might mount the wrong disk. Also, running this on a live system will leave the clone in an unclean state, as it wasn’t and will not be unmounted, in addition to other obvious problems. Which means that if you do this remotely and reboot without (someone) pulling out the clone, you’re likely screwed. Disk UID can be changed with disklabel(8), see the “i” command.

 Leave a Reply

You may use these HTML tags and attributes: <a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code class="" title="" data-url=""> <del datetime=""> <em> <i> <q cite=""> <s> <strike> <strong> <pre class="" title="" data-url=""> <span class="" title="" data-url="">

(required)

(required)