Skip site navigation (1)Skip section navigation (2)
Date:      Tue, 30 Oct 2007 23:49:08 +0100
From:      Ivan Voras <ivoras@freebsd.org>
To:        freebsd-questions@freebsd.org
Cc:        freebsd-geom@freebsd.org
Subject:   Re: Fw: Best way for a gmirrored gjournal?
Message-ID:  <fg8cd6$u0d$1@ger.gmane.org>
In-Reply-To: <20071030001228.65816a87@mobility.bytephobia.de>
References:  <20071030001228.65816a87@mobility.bytephobia.de>

next in thread | previous in thread | raw e-mail | index | archive | help
This is an OpenPGP/MIME signed message (RFC 2440 and 3156)
--------------enig61483D53659D56FCCA8A7EF9
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: quoted-printable

Patrick Hurrelmann wrote:

> I kindly ask you for your ideas and proposals on my questions below.

Some of the questions seem a bit confused.


> The server in question is a amd64 with 512mb of ram and 2x 80gb sata
> hdds. So I was thinking of a mount-point layout like the following:
>=20
> ad0s1
>  /       (1gb)
>  swap    (1gb)
>  /var    (8gb)
>  /tmp    (1gb)
>  /home   (4gb)
>  /usr   (13gb)
>  /jails (39gb)
> ad0s2
>  10gb for journaling
>=20
> Which would leave a space of 10gb for journaling. I digged through the
> mailinglist-archives and man-pages of gmirror and gjournal but all I
> ended up with are questions and doubts :)
>=20
> Now I wanted to create 2 mirrors (gm0s1 and gm0s2). Gmirror gm0s1
> containing the slices ad0s1 and ad2s1, while gm0s2 should contain ad0s2=

> and ad2s2. I created 2 slices, as with the above shown partitioning I
> was running out of mount-points for this slice.

What do you mean by "running out of mount-points"? Do you mean you don't
have any more bsdlabel entries available (e.g. the "a" part of
"ad0s1a")? If so, you should probably stop using bsdlabels for
everything except the root partition (i.e. make ad0s1a the root, make
all other space into ad0s2 and sub-partition ad0s2 with GPT. This
"weird" setup is required because 7.0 can't boot from GPT).

> Is such a layout reasonable? Or is it stupid to use a dedicated slice
> just for journaling and better skip e.g /tmp partition to leave space
> for a dedicated journaling partition on this slice?=20

In your case, it doesn't really matter from the technical point of view.
It's easier for administration when the journal is embedded on the same
slice as the file system.

>Btw. are 10gb
> enough for journaling of 6 partitions? Or do I need one dedicated
> partition for journaling each?

Required journal size depends on the speed of your drive and journal
switch (sync) time intervals. You need at least (drive_speed *
switch_time * 2) space for the journal (e.g. for a drive that does 50
MB/s and for switch time of 10 seconds, you need 50*10*2=3D1 GB). The
reasoning behind the magic number "2" is that you need two journal
areas, one being used and the other committed.

> What do you people out there suggest? How do you handle systems with
> gmirror and gjournal combined? Or even use ZFS although ram is limited
> (as the machine will serve up several jails with e.g. postgres)?=20

You probably don't want to use ZFS with 512 MB of RAM if you need the
machine up 24/7. If you have that many file systems, one journal per
file system is about the only thing you can do (and it doesn't matter if
the file system is on a regular or gmirrored drive). A slightly simpler
solution would be to mirror the whole drives (ad0+ad2) but it's mostly a
cosmetical issue.




--------------enig61483D53659D56FCCA8A7EF9
Content-Type: application/pgp-signature; name="signature.asc"
Content-Description: OpenPGP digital signature
Content-Disposition: attachment; filename="signature.asc"

-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.2.5 (MingW32)
Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org

iD8DBQFHJ7TkldnAQVacBcgRAkv9AJ0f+yiWQnPLD9naE+4nlEikKOVOhACZAdN/
CXHqM5TktUL8qMYDAJz7UUk=
=6jg8
-----END PGP SIGNATURE-----

--------------enig61483D53659D56FCCA8A7EF9--




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