Skip site navigation (1)Skip section navigation (2)
Date:      Sat, 8 Jul 2006 21:57:07 -0400
From:      "Scott Ullrich" <sullrich@gmail.com>
To:        "Eric Anderson" <anderson@centtech.com>
Cc:        Mike Jakubik <mikej@rogers.com>, freebsd-geom@freebsd.org
Subject:   Re: Detecting GMIRROR volumes without using gmirror utility
Message-ID:  <d5992baf0607081857ic71683dl2118266c3b0db084@mail.gmail.com>
In-Reply-To: <44AEC9E1.50002@centtech.com>
References:  <d5992baf0607071155m7f37ab8ds2a9b6ea92a82cddd@mail.gmail.com> <44AEBEF3.6010703@rogers.com> <d5992baf0607071313y66386d04y507629c16c9d4418@mail.gmail.com> <44AEC9E1.50002@centtech.com>

next in thread | previous in thread | raw e-mail | index | archive | help
On 7/7/06, Eric Anderson <anderson@centtech.com> wrote:
> The problem with the sysctl, is that it doesn't know about the GEOM
> markers that don't have kernel modules loaded.  For instance, I have a
> drive that is part of a geom_journal.  Without geom_journal loaded, the
> conftxt reports:
>
> 0 DISK da0 400088457216 512 hd 255 sc 63
> 1 MBR da0s2 24281026560 512 i 1 o 375804817920 ty 6
> 1 MBR da0s1 375804785664 512 i 0 o 32256 ty 165
> 2 BSD da0s1e 5363856384 512 i 4 o 370440929280 ty 7
> 3 LABEL label/journal 5363855872 512 i 0 o 0
> 2 BSD da0s1d 370440929280 512 i 3 o 0 ty 7
> 3 LABEL label/backup 370440928768 512 i 0 o 0
> 2 BSD da0s1c 375804785664 512 i 2 o 0 ty 0
> 0 DISK ad0 100030242816 512 hd 16 sc 63
> 1 MBR ad0s2 69791500800 512 i 1 o 16162675200 ty 165
> 2 BSD ad0s2e 11020913152 512 i 4 o 58770587648 ty 7
> 3 LABEL ufs/alt 11020913152 512 i 0 o 0
> 2 BSD ad0s2d 19922944000 512 i 3 o 38847643648 ty 7
> 3 LABEL ufs/home 19922944000 512 i 0 o 0
> 2 BSD ad0s2c 69791500800 512 i 2 o 0 ty 0
> 2 BSD ad0s2b 2147483648 512 i 1 o 0 ty 1
> 2 BSD ad0s2a 36700160000 512 i 0 o 2147483648 ty 7
> 1 MBR ad0s1 16162642944 512 i 0 o 32256 ty 12
>
> see the da0s* stuff?  That is actually part of a geom_journal, but since
> the kernel module isn't loaded, it doesn't taste for it.  Now, I simply
> load the geom_journal module, and check the sysctl again:
>
> 0 DISK da0 400088457216 512 hd 255 sc 63
> 1 MBR da0s2 24281026560 512 i 1 o 375804817920 ty 6
> 1 MBR da0s1 375804785664 512 i 0 o 32256 ty 165
> 2 BSD da0s1e 5363856384 512 i 4 o 370440929280 ty 7
> 3 LABEL label/journal 5363855872 512 i 0 o 0
> 4 JOURNAL label/backup.journal 370440928256 512
> 5 BSD label/backup.journale 5363856384 512 i 4 o 370440929280 ty 7
> 5 BSD label/backup.journald 370440929280 512 i 3 o 0 ty 7
> 5 BSD label/backup.journalc 375804785664 512 i 2 o 0 ty 0
> 2 BSD da0s1d 370440929280 512 i 3 o 0 ty 7
> 3 LABEL label/backup 370440928768 512 i 0 o 0
> 4 JOURNAL label/backup.journal 370440928256 512
> 5 BSD label/backup.journale 5363856384 512 i 4 o 370440929280 ty 7
> 5 BSD label/backup.journald 370440929280 512 i 3 o 0 ty 7
> 5 BSD label/backup.journalc 375804785664 512 i 2 o 0 ty 0
> 2 BSD da0s1c 375804785664 512 i 2 o 0 ty 0
> 0 DISK ad0 100030242816 512 hd 16 sc 63
> 1 MBR ad0s2 69791500800 512 i 1 o 16162675200 ty 165
> 2 BSD ad0s2e 11020913152 512 i 4 o 58770587648 ty 7
> 3 LABEL ufs/alt 11020913152 512 i 0 o 0
> 2 BSD ad0s2d 19922944000 512 i 3 o 38847643648 ty 7
> 3 LABEL ufs/home 19922944000 512 i 0 o 0
> 2 BSD ad0s2c 69791500800 512 i 2 o 0 ty 0
> 2 BSD ad0s2b 2147483648 512 i 1 o 0 ty 1
> 2 BSD ad0s2a 36700160000 512 i 0 o 2147483648 ty 7
> 1 MBR ad0s1 16162642944 512 i 0 o 32256 ty 12
>
>
> Now it sees the journal.
>
> I think you will not be able to get away from loading the geom modules,
> because they are what do the tasting for their class.

I see what you mean.   I've got it working!!   I've got a bit of
cleanup to do but should be able to post a FreeSBIE test ISO in the
next week.

Thanks to everyone that replied.   This feature is quite handy!!

Scott



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?d5992baf0607081857ic71683dl2118266c3b0db084>