From owner-freebsd-database@FreeBSD.ORG Fri Jul 12 19:15:45 2013 Return-Path: Delivered-To: freebsd-database@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [8.8.178.115]) by hub.freebsd.org (Postfix) with ESMTP id B5DC82C5; Fri, 12 Jul 2013 19:15:45 +0000 (UTC) (envelope-from artem.naluzhnyy@gmail.com) Received: from mail-wi0-x22d.google.com (mail-wi0-x22d.google.com [IPv6:2a00:1450:400c:c05::22d]) by mx1.freebsd.org (Postfix) with ESMTP id 040611A15; Fri, 12 Jul 2013 19:15:44 +0000 (UTC) Received: by mail-wi0-f173.google.com with SMTP id hq4so1038469wib.6 for ; Fri, 12 Jul 2013 12:15:44 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=mime-version:in-reply-to:references:from:date:message-id:subject:to :cc:content-type; bh=+88swS6fEFYbjY/PJZ6w5Z5I9iLpjMWv67ummD29GBg=; b=FRCfri8cFg4xxuHSYBw9aqzFmv7Okow/FR2ck8d1gkCdowAqejOKSs78Vb2fz2RrJ0 /qB6C/tYKA4GtT6mXlgpkxGlJORHd35vyOVKFZdK3q9HaxEPh09cX45+Ja4okfRNoSTn bbIA0QOO+zB7zil3ZzyawzKfwVm7mVeewG0wMN2WXGxJmAVw8GW2763OMVHsyHr2QFZ8 rzQbnMjX9EftVhLvQ8XjrsMUKDvDe47NApDY4jFEfzyNmdtz54znkwKD7+suElQXhnoW FClU2B9FUbZeZHc7K0+uz9wYump5LJrd13zFDz5BDhxvroPAS1yJ82mvKobL8QwaqeuI QDhw== X-Received: by 10.180.36.107 with SMTP id p11mr2507885wij.31.1373656544076; Fri, 12 Jul 2013 12:15:44 -0700 (PDT) MIME-Version: 1.0 Received: by 10.216.203.68 with HTTP; Fri, 12 Jul 2013 12:15:03 -0700 (PDT) In-Reply-To: References: From: Artem Naluzhnyy Date: Fri, 12 Jul 2013 22:15:03 +0300 Message-ID: Subject: Re: RAID10 stripe size and PostgreSQL performance To: Ivan Voras Content-Type: text/plain; charset=UTF-8 Cc: freebsd-database@freebsd.org, freebsd-fs@freebsd.org X-BeenThere: freebsd-database@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: Database use and development under FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 12 Jul 2013 19:15:45 -0000 On Fri, Jul 12, 2013 at 4:55 PM, Ivan Voras wrote: > I just looked at your RAID configuration at http://pastebin.com/F8uZEZdm > and you have a mirror of stripes (RAID-01) nor a stripe of mirrors > (RAID-10). And apparently, is I parse your configuration correctly, you > have a 1M stripe in the MIRROR part of the RAID, and an unknown stripe > size in the STRIPE part. This is probably a bug in mfiutil output. There is no "RAID 01" option in the controller configuration, and its documentation says (http://goo.gl/6X5pe): "RAID 10, a combination of RAID 0 and RAID 1, consists of striped data across mirrored spans. A RAID 10 drive group is a spanned drive group that creates a striped set from a series of mirrored drives. RAID 10 allows a maximum of eight spans. You must use an even number of configuration Scenarios 1-7 drives in each RAID virtual drive in the span. The RAID 1 virtual drives must have the same stripe size." There is also no options to configure a different stripe size for the mirrors, I can only set it globally for the whole RAID 10 volume. > Anyway, could you please do one more test: > > 1) create a large file with "dd if=/dev/zero of=file bs=1m count=48000" > 2) install /usr/ports/benchmarks/randomio > 3) run "randomio file 8 0.5 1 8192 10 10" > > ... and report the results. See results at the end of http://pastebin.com/F8uZEZdm There is yet another issue that makes (I guess it should) all previous benchmarks kinda inaccurate and irrelevant - looks like the the UFS partitions are not aligned properly: $ gpart show => 63 1167966145 mfid0 MBR (557G) 63 1167957567 1 freebsd [active] (556G) 1167957630 8578 - free - (4.2M) => 0 1167957567 mfid0s1 BSD (556G) 0 4194304 1 freebsd-ufs (2.0G) 4194304 16777216 2 freebsd-swap (8.0G) 20971520 1130217472 5 freebsd-ufs (539G) 1151188992 16768575 4 freebsd-ufs (8G) Will also try to fix the alignment and make some tests. -- Artem Naluzhnyy