Journaling UFS with gjournal.

Pawel Jakub Dawidek pjd at FreeBSD.org
Tue Jun 20 08:39:17 UTC 2006


On Mon, Jun 19, 2006 at 09:32:18PM +0300, Niki Denev wrote:
+> I wonder if it's possible to use gjournal on
+> existing file system with the journal on a vnode/(swap?) backed md(4) device?
+> (i want to test on a existing installation without free unpartitioned space)

Depend on what do you want to test. If you just want to look around,
swap-backed md(4) device for journal should be fine.
If you want to perform some crash tests, you may want to turn off the
swap and use its provider for journal directly (without md(4)), so it
will be available after a reboot.

You can configure gjournal on an existing file system, but, as always,
the last sector will be used for metadata.
For example, you have your file system on ad0s1d and swap on ad0s1b.
You can try to configure gjournal this way:

	# swapoff /dev/ad0s1b
	# umount /dev/ad0s1d
	# gjournal label ad0s1d ad0s1b

Your swap should have at least 2GB if your file system will be heavy
loaded. Be warned that this will overwrite the last sector on ad0s1d,
which should be safe, but you never know.

+> And if it is possible, how can i do this for the root filesystem? i'll need the md(4)
+> device before mounting of the root fs which seems hard/impossible?
+> What's going to happen if my root mount is gjournal labeled and has gjournal option in
+> fstab but at boot time the journal GEOM provider does not exist?

I forgot to mention this in my initial mail. This is not yet possible to
use gjournal for the root file system.

-- 
Pawel Jakub Dawidek                       http://www.wheel.pl
pjd at FreeBSD.org                           http://www.FreeBSD.org
FreeBSD committer                         Am I Evil? Yes, I Am!
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 187 bytes
Desc: not available
Url : http://lists.freebsd.org/pipermail/freebsd-fs/attachments/20060620/363e420c/attachment.pgp


More information about the freebsd-fs mailing list