[nflug] quick partition table mirroring

Robert Meyer meyer_rm at yahoo.com
Fri Sep 5 12:46:57 EDT 2008


'dd'? :-)

Actually, you can probably use something like sfdisk to do it.
sfdisk -d /dev/hda > hda.out
sfdisk /dev/hdb <  hda.out

or, more succinctly:
sfdisk -d /dev/hda | sfdisk /dev/hdb

How's that?

Cheers!

Bob

 --
"When once you have tasted flight, you will forever walk the earth with your eyes turned skyward, for there you have been, and there you will always long to return."
--Leonardo da Vinci



----- Original Message ----
From: Darin Perusich <Darin.Perusich at cognigencorp.com>
To: nflug at nflug.org
Sent: Friday, September 5, 2008 12:31:41 PM
Subject: [nflug] quick partition table mirroring

I'm not sure the subject of this message accurately describes what I'm 
looking but it's kind of close.

I have a Linux server with mirrored drives and one of the drives died. 
I've replaced the dead drive with an identical disk and want to recreate 
the partition layout and rebuild the mirrors, simple tasks. Because the 
disks are identical I'd rather not have to manually create all the 
partitions, I want to suck that info from disk1 and apply it to disk2.

On Solaris I'd use prtvtoc from grab the disks partitions and fmthard to 
apply it to the new drive but haven't been able to locate equivalents on 
  Linux yet. Is anyone aware of how this can be done on Linux?

-- 
Darin Perusich
Unix Systems Administrator
Cognigen Corporation
395 Youngs Rd.
Williamsville, NY 14221
Phone: 716-633-3463
Email: darinper at cognigencorp.com
_______________________________________________
nflug mailing list
nflug at nflug.org
http://www.nflug.org/mailman/listinfo/nflug



      
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://www.nflug.org/pipermail/nflug/attachments/20080905/fc14a163/attachment.html


More information about the nflug mailing list