disklabel and gm0 (gmirror)

Miroslav Lachman 000.fbsd at quip.cz
Wed Apr 9 10:41:09 UTC 2008


hv wrote:

[...]

> why not just using gmirror to break and recreate the mirror, something  
> like this:
> 
> 1) remove one disk (it's a mirror!)
> 2) recreate the label on this disk, newfs it and  copy everything over  
> from the remaining mirror disk.
> 3) if you booted off the mirror, you need to adjust fstab to boot from  
> the disk 1) and reboot, then destroy the mirror.
> 4  recreate the mirror on the disk from 1), if you want to boot from  
> the mirror, re-adjust the fstab and reboot
> 5) insert the second disk into the recreated mirror in 4)
> 
> see  gmirror(8), hope this helps.

Yes, it is one of the possible ways of "backup all your data"... :)

And another way could be - remove one drive (provider) from gmirror, 
data remains on it.
Recreate the label on gmirror gm0 + newfs
Copy data from previously removed provider
Reinsert provider in to new gmirror
[and do some steps with fstab + reboot if needed]

I feel myself safer if data is backuped off the machine where I play 
with disks / newfs / gmirror etc.

Miroslav Lachman


More information about the freebsd-geom mailing list