Lock/reboot, no dump (ugh)

Doug White dwhite at gumbysoft.com
Wed Feb 9 10:30:06 PST 2005


On Tue, 8 Feb 2005, Karl Denninger wrote:

> Hi folks;
>
> FreeBSD 5.3-STABLE #1: Wed Feb  2 22:57:48 CST 2005     karl at FS.denninger.net:/usr/obj/usr/src/sys/KSD-SMP
>
> Sources from January 30th.
>
> Scenario:
>
> 1.	Using GEOM_MIRROR to mirror two SATA drives.
>
> 2.	Nightly, a third drive is used to back up, as follows:
>
> 	a. Check to see if the drive is visible on the SATA interface.
> 	b. If not, "atacontrol attach 2" to scan the bus it is plugged into
> 	c. Verify that it is now online.
> 	d. Use "gmirror insert ...." to insert it into the mirror.
> 	e. Wait for it to sync.
> 	f. Stop critical processes (e.g. DBMS, etc)
> 	g. "gmirror deactivate ...." to remove the backup from the mirror.
> 	h. "gmirror forget" to clean up the RAID
> 	i. "atacontrol detach 2" to detach and spin down the disk.

This is only safe if you also unmount the filesystem(s) that are stored on
the mirror volume.  If you don't unmount it then you'll get behavior like
this -- unflushed blocks vanish.  If you insist on doing dirty copies then
you might try mounting the FS sync, but performance will fall through the
floor.

If you're testing simple attach/detach then you might start with a
quiescent volume (unmounted or filled with test patterns) and do mirror
attach/sync/detach in a loop.  THat would take the FS, and any in-memory
filesystem state corruption, out of the picture.

-- 
Doug White                    |  FreeBSD: The Power to Serve
dwhite at gumbysoft.com          |  www.FreeBSD.org


More information about the freebsd-stable mailing list