Linux LVM users
 help / color / mirror / Atom feed
From: David Greaves <david@dgreaves.com>
To: Guy <bugzilla@watkins-home.com>
Cc: linux-raid@vger.kernel.org,
	'Steven Ihde' <x-linux-raid@hamachi.dyndns.org>,
	linux-lvm@redhat.com
Subject: [linux-lvm] Re: Looking for the cause of poor I/O performance - a test script
Date: Sun, 12 Dec 2004 08:56:34 +0000	[thread overview]
Message-ID: <41BC07C2.5020303@dgreaves.com> (raw)
In-Reply-To: <200412082241.iB8Mfo915469@www.watkins-home.com>

I hacked up a quick script to test permutations of readahead - it's not 
exactly bonnie+++ but it may be useful.
I wish I'd bothered with mdadm stripe sizes too - but the array is 
pretty full now and I'll live with what it delivers.

Essentially I found the best performance on *my* system with all low 
level devices and the md device set to a 0 readahead and the lvm device 
set to 4096.
I'm only interested in video streaming big (1+Gb) files. Your needs (and 
hence test) may differ.

my system is 2.6.10-rc2, xfs, lvm2, raid5, sata disks.

cc'ed the lvm group since this often seems to come up in conjunction 
with you guys :)

For your entertainment...

#!/bin/bash
RAW_DEVS="/dev/sda /dev/sdb /dev/sdc /dev/sdd /dev/sde /dev/sdf /dev/hdb"
MD_DEVS=/dev/md0
LV_DEVS=/dev/huge_vg/huge_lv

LV_RAS="0 128 256 1024 4096 8192"
MD_RAS="0 128 256 1024 4096 8192"
RAW_RAS="0 128 256 1024 4096 8192"

function show_ra()
{
for i in $RAW_DEVS $MD_DEVS $LV_DEVS
 do echo -n "$i `blockdev --getra $i`  ::  "
done
echo
}

function set_ra()
{
  RA=$1
  shift
  for dev in $@
  do
    blockdev --setra $RA $dev
  done
}

function show_performance()
{
  COUNT=4000000
  dd if=/dev/huge_vg/huge_lv of=/dev/null count=$COUNT 2>&1 | grep seconds
}

for RAW_RA in $RAW_RAS
  do
  set_ra $RAW_RA $RAW_DEVS
  for MD_RA in $MD_RAS
    do
    set_ra $MD_RA $MD_DEVS
    for LV_RA in $LV_RAS
      do
      set_ra $LV_RA $LV_DEVS
      show_ra
      show_performance
      done
    done
  done

       reply	other threads:[~2004-12-12  8:56 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
     [not found] <200412082241.iB8Mfo915469@www.watkins-home.com>
2004-12-12  8:56 ` David Greaves [this message]
2004-12-28  0:13   ` [linux-lvm] Re: Looking for the cause of poor I/O performance - a test script Steven Ihde

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=41BC07C2.5020303@dgreaves.com \
    --to=david@dgreaves.com \
    --cc=bugzilla@watkins-home.com \
    --cc=linux-lvm@redhat.com \
    --cc=linux-raid@vger.kernel.org \
    --cc=x-linux-raid@hamachi.dyndns.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox