Detecting GMIRROR volumes without using gmirror utility
Eric Anderson
anderson at centtech.com
Fri Jul 7 20:53:51 UTC 2006
On 07/07/06 15:13, Scott Ullrich wrote:
> On 7/7/06, Mike Jakubik <mikej at rogers.com> wrote:
>> Finally someone steps up to the job! Thanks for the work, I am looking
>> forward to this feature. Whats the status of the BSD Installer? When/if
>> can we expect to see it in a release?
>
> Well it will be included with future FreeSBIE2 builds and also
> pfSense. Not sure how long it will take, I've had it working prior
> but it was pretty evil hacks against BSD Installer. I plan on
> redoing it the right way so that Chris Pressey doesn't hunt me down
> with an axe. :)
>
> In all seriousness, I hope to have something working in the next
> couple weeks now that the sysctl is available.
>
> Thanks again to everyone that responded.
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.
Eric
--
------------------------------------------------------------------------
Eric Anderson Sr. Systems Administrator Centaur Technology
Anything that works is better than anything that doesn't.
------------------------------------------------------------------------
More information about the freebsd-geom
mailing list