Installing a system to use both gjournal and gmirror

Aram Hăvărneanu aram.h at mgk.ro
Mon Aug 2 00:20:08 UTC 2010


On Sat, Jul 31, 2010 at 12:38 PM,  <perryh at pluto.rain.com> wrote:
> I've read the Handbook sections on gmirror and gjournal, and the
> gjournal-desktop article, and I'm still unclear on how to go about
> setting up a configuration that uses both.

I have GPT disks and do GEOM mirror for / plus GEOM stripe for
everything else. Everything is using GEOM Journal and the filesystem
is UFS2.

excelsior% gmirror status
              Name    Status  Components
mirror/rootmirror0  COMPLETE  ad4p2
                              ad6p2
excelsior% clear
%
excelsior% gpart show
=>       34  625142381  ad4  GPT  (298G)
         34        128    1  freebsd-boot  (64K)
        162    4194304    2  freebsd-ufs  (2.0G)
    4194466    4194304    3  freebsd-swap  (2.0G)
    8388770    6291456    4  freebsd-ufs  (3.0G)
   14680226   20971520    5  freebsd-ufs  (10G)
   35651746   10485760    6  freebsd-ufs  (5.0G)
   46137506  579004909    7  freebsd-ufs  (276G)

=>       34  625142381  ad6  GPT  (298G)
         34        128    1  freebsd-boot  (64K)
        162    4194304    2  freebsd-ufs  (2.0G)
    4194466    4194304    3  freebsd-swap  (2.0G)
    8388770    6291456    4  freebsd-ufs  (3.0G)
   14680226   20971520    5  freebsd-ufs  (10G)
   35651746   10485760    6  freebsd-ufs  (5.0G)
   46137506  579004909    7  freebsd-ufs  (276G)

excelsior% gmirror status
              Name    Status  Components
mirror/rootmirror0  COMPLETE  ad4p2
                              ad6p2
excelsior% gstripe status
                Name  Status  Components
   stripe/varstripe0      UP  ad4p4
                              ad6p4
   stripe/usrstripe0      UP  ad4p5
                              ad6p5
stripe/usrobjstripe0      UP  ad4p6
                              ad6p6
  stripe/tankstripe0      UP  ad4p7
                              ad6p7
excelsior% gjournal status
                        Name  Status  Components
  mirror/rootmirror0.journal     N/A  mirror/rootmirror0
   stripe/varstripe0.journal     N/A  stripe/varstripe0
   stripe/usrstripe0.journal     N/A  stripe/usrstripe0
stripe/usrobjstripe0.journal     N/A  stripe/usrobjstripe0
  stripe/tankstripe0.journal     N/A  stripe/tankstripe0
excelsior% mount
/dev/mirror/rootmirror0.journal on / (ufs, local, gjournal)
devfs on /dev (devfs, local, multilabel)
/dev/stripe/usrstripe0.journal on /usr (ufs, local, gjournal)
/dev/stripe/varstripe0.journal on /var (ufs, local, gjournal)
/dev/stripe/usrobjstripe0.journal on /usr/obj (ufs, local, gjournal)
/dev/stripe/tankstripe0.journal on /tank (ufs, local, gjournal)
excelsior% cat /boot/loader.conf
geom_mirror_load="YES"
geom_stripe_load="YES"
geom_journal_load="YES"

vfs.root.mountfrom="ufs:/dev/mirror/rootmirror0.journal"
vfs.root.mountfrom.options="rw"

excelsior% cat /etc/fstab
#Device                         MountPoint      FsType  Options Dump    Pass#
/dev/gpt/swap0                  none            swap    sw      0       0
/dev/gpt/swap1                  none            swap    sw      0       0
/dev/mirror/rootmirror0.journal /               ufs     rw      1       1
/dev/stripe/usrstripe0.journal  /usr            ufs     rw      2       2
/dev/stripe/varstripe0.journal  /var            ufs     rw      2       2
/dev/stripe/usrobjstripe0.journal       /usr/obj        ufs     rw
 2       2
/dev/stripe/tankstripe0.journal /tank           ufs     rw      2       2
/dev/acd0                       /cdrom          cd9660  ro,noauto 0     0

excelsior% ls /dev/mirror
rootmirror0             rootmirror0.journal
excelsior% ls /dev/stripe
tankstripe0             usrobjstripe0.journal   varstripe0
tankstripe0.journal     usrstripe0              varstripe0.journal
usrobjstripe0           usrstripe0.journal
excelsior%

-- 
Aram Hăvărneanu


More information about the freebsd-questions mailing list