From owner-freebsd-performance@FreeBSD.ORG Thu Nov 17 21:36:53 2011 Return-Path: Delivered-To: freebsd-performance@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 58F67106566C for ; Thu, 17 Nov 2011 21:36:53 +0000 (UTC) (envelope-from m.seaman@infracaninophile.co.uk) Received: from smtp.infracaninophile.co.uk (smtp6.infracaninophile.co.uk [IPv6:2001:8b0:151:1:3fd3:cd67:fafa:3d78]) by mx1.freebsd.org (Postfix) with ESMTP id B781F8FC16 for ; Thu, 17 Nov 2011 21:36:52 +0000 (UTC) Received: from seedling.black-earth.co.uk (seedling.black-earth.co.uk [81.187.76.163]) (authenticated bits=0) by smtp.infracaninophile.co.uk (8.14.5/8.14.5) with ESMTP id pAHLahPS035302 (version=TLSv1/SSLv3 cipher=DHE-RSA-CAMELLIA256-SHA bits=256 verify=NO) for ; Thu, 17 Nov 2011 21:36:44 GMT (envelope-from m.seaman@infracaninophile.co.uk) X-DKIM: OpenDKIM Filter v2.4.1 smtp.infracaninophile.co.uk pAHLahPS035302 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=infracaninophile.co.uk; s=201001-infracaninophile; t=1321565804; bh=0I24T5EtCq4VScKEBf8pwkGcWe3wAwoxIcHXArCmajA=; h=Message-ID:Date:From:MIME-Version:To:Subject:References: In-Reply-To:Content-Type:Cc; b=p9ry2+cX/gdi5nuR2Qlc1fH1a1sDOU2mJ4BEder+rtDso9Gf8tc/3DhhnUaigd8uM rkiPWYdFIONe8UWR4Q7lv0RsKKQXqPg6Fz3/mRCsuhvG952NJAnALzUaV8Z9LSz0xS fayo5hJ0jyLv6PDH3IuATJE4LImZp+n8n4Tcu1qg= Message-ID: <4EC57E62.9000007@infracaninophile.co.uk> Date: Thu, 17 Nov 2011 21:36:34 +0000 From: Matthew Seaman User-Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10.6; rv:8.0) Gecko/20111105 Thunderbird/8.0 MIME-Version: 1.0 To: freebsd-performance@freebsd.org References: In-Reply-To: X-Enigmail-Version: 1.3.3 OpenPGP: id=60AE908C Content-Type: multipart/signed; micalg=pgp-sha1; protocol="application/pgp-signature"; boundary="------------enig41691E48561C4FB5B2B4712F" X-Virus-Scanned: clamav-milter 0.97.3 at lucid-nonsense.infracaninophile.co.uk X-Virus-Status: Clean X-Spam-Status: No, score=-0.6 required=5.0 tests=BAYES_05,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,SPF_FAIL autolearn=no version=3.3.2 X-Spam-Checker-Version: SpamAssassin 3.3.2 (2011-06-06) on lucid-nonsense.infracaninophile.co.uk Subject: Re: ZFS Few Questions X-BeenThere: freebsd-performance@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Performance/tuning List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 17 Nov 2011 21:36:53 -0000 This is an OpenPGP/MIME signed message (RFC 2440 and 3156) --------------enig41691E48561C4FB5B2B4712F Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: quoted-printable On 17/11/2011 19:04, Mark Felder wrote: >> Question 3: >> Anyone Recommend for MySQL server? (Performance) >=20 > No idea; I haven't run any SQL servers on ZFS The sort of randomly located small IOs that RDBMSes do is the hardest sort of IO pattern for ZFS (or any filesystem for that matter) to manage. ZFS has a particular problem in that its default storage unit is a 128kB block -- and the copy-on-write semantics mean that the filesystem layer can in principle end up doing a 128kB read, altering a few bytes, then doing a 128kB write to get that data back on disk. You can get pretty reasonable DB performance on ZFS, but it takes quite a bit of tuning. * ZFS needs plenty of RAM. The DB needs plenty of RAM. Exactly what the balance should be is hard to predict -- dependent on specific workloads -- so expect to spend some time benchmarking and experimenting with different settings. * Putting the ARC (Adaptive Replacement Cache) on a separate, fast device will make a big difference to performance. SSD cards are popular for this purpose. (Be aware though that SSDs have a limited lifetime, and tend to fail suddenly and completely when they do wear out. You will need multiple layers of resilience and very good backups...) While SSD cards are intrinsically faster than individual rotating magnetic media, they are no match for a large disk array that can spread the IO over lots of spindles. But that costs a very great deal of money... * Reducing the ZFS block size (the recordsize property when creating a zfs) to match the IO size of your DB system can help a lot. Do this before creating the database. * Separating the DB's data and transaction logging onto separate ZFS pools helps. See http://www.solarisinternals.com/wiki/index.php/ZFS_for_Databases for more details. Just about everything on that page applies equally to FreeBSD as it does to Solaris. Cheers, Matthew --=20 Dr Matthew J Seaman MA, D.Phil. 7 Priory Courtyard Flat 3 PGP: http://www.infracaninophile.co.uk/pgpkey Ramsgate JID: matthew@infracaninophile.co.uk Kent, CT11 9PW --------------enig41691E48561C4FB5B2B4712F Content-Type: application/pgp-signature; name="signature.asc" Content-Description: OpenPGP digital signature Content-Disposition: attachment; filename="signature.asc" -----BEGIN PGP SIGNATURE----- Version: GnuPG/MacGPG2 v2.0.16 (Darwin) Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org/ iEYEARECAAYFAk7FfmsACgkQ8Mjk52CukIwIHQCeIMrBAvwSsPKGgtdkFBB54VyM d40AniX0/CDfvD3T1CR1/IFMOJNH9S3E =5nYt -----END PGP SIGNATURE----- --------------enig41691E48561C4FB5B2B4712F--