Re: Very low disk performance on 5.x

From: Arne (arne_woerner_at_yahoo.com)
Date: 05/03/05

  • Next message: Steven Hartland: "Re: Very low disk performance on 5.x"
    Date: Mon, 2 May 2005 15:19:10 -0700 (PDT)
    To: Steven Hartland <killing@multiplay.co.uk>, Poul-Henning Kamp <phk@phk.freebsd.dk>
    
    

    --- Steven Hartland <killing@multiplay.co.uk> wrote:
    > ----- Original Message -----
    > From: "Poul-Henning Kamp" <phk@phk.freebsd.dk>
    > > On -current and 5.4 you don't have to make partitions if you
    > > intend to use the entire disk (and provided you don't want
    > > to boot from it). You can simply:
    > >
    > > newfs /dev/da0
    > > mount /dev/da0 /where_ever
    >
    > /dev/da0: 1526216.3MB (3125691008 sectors) block size 16384,
    > fragment size 2048
    > using 8306 cylinder groups of 183.77MB, 11761 blks, 23552
    > inodes.
    > mount /dev/da0 /mnt
    >
    > dd if=/dev/zero of=/mnt/testfile bs=64k count=100000
    > 100000+0 records in
    > 100000+0 records out
    > 6553600000 bytes transferred in 44.424588 secs (147521908
    > bytes/sec)
    >
    > /usr/bin/time -h dd of=/dev/null if=/mnt/testfile bs=64k
    > count=100000
    > 100000+0 records in
    > 100000+0 records out
    > 6553600000 bytes transferred in 48.150473 secs (136106658
    > bytes/sec)
    > 48.27s real 0.01s user 12.33s
    > sys
    >
    > /usr/bin/time -h cat /mnt/testfile > /dev/null
    > 48.12s real 0.26s user 14.92s
    > sys
    >
    > Raw read:
    > /usr/bin/time -h dd of=/dev/null if=/dev/da0 bs=64k count=100000
    >
    > 100000+0 records in
    > 100000+0 records out
    > 6553600000 bytes transferred in 32.028544 secs (204617482
    > bytes/sec)
    > 32.02s real 0.02s user 2.73s
    > sys
    >
    > /usr/bin/time -h dd of=/dev/null if=/dev/da0 bs=1m count=6000
    > 6000+0 records in
    > 6000+0 records out
    > 6291456000 bytes transferred in 31.518195 secs (199613460
    > bytes/sec)
    > 31.51s real 0.00s user 1.87s
    > sys
    >
    > > One thing you could try is to use a larger block/fragment size
    > > on your filesystem. Try:
    > >
    > > newfs -b 32768 -f 4096 /dev/da0
    > /dev/da0: 1526216.3MB (3125691008 sectors) block size 32768,
    > fragment size 4096
    > using 2063 cylinder groups of 740.00MB, 23680 blks,
    > 47360 inodes.
    >
    > /usr/bin/time -h dd if=/dev/zero of=/mnt/testfile bs=64k
    > count=100000
    > 100000+0 records in
    > 100000+0 records out
    > 6553600000 bytes transferred in 35.237328 secs (185984590
    > bytes/sec)
    > 35.34s real 0.07s user 28.81s
    > sys
    >
    > /usr/bin/time -h dd of=/dev/null if=/mnt/testfile bs=64k
    > count=100000
    > 100000+0 records in
    > 100000+0 records out
    > 6553600000 bytes transferred in 39.154845 secs (167376477
    > bytes/sec)
    > 39.16s real 0.01s user 14.33s
    > sys
    >
    > Slower than the default :(
    >
    Why? It looks like the 32k-bs-fs terminates 20% earlier than the
    16k-bs-fs.

    Furthermore I would like to re-interpret my analysis about my hard
    disc /dev/ad0:
    It looks like, I damaged the write cache somehow... atacontrol's
    output is not consistent in this point (it changes from reboot to
    reboot, while the write rate is always 5 times lower than the read
    rate), while hw.ata.wc is always 1.

    So I just see, that there is some overhead. Example: my /dev/ad1:
    92MB/sec theoretical maximum (data transfer rate from the medium
    (disc) to device's buffer)
    60MB/sec if I read bs=128k
    40MB/sec if I read from a ufs+s with std bs (16kB?)

    -Arne

    __________________________________________________
    Do You Yahoo!?
    Tired of spam? Yahoo! Mail has the best spam protection around
    http://mail.yahoo.com
    _______________________________________________
    freebsd-performance@freebsd.org mailing list
    http://lists.freebsd.org/mailman/listinfo/freebsd-performance
    To unsubscribe, send any mail to "freebsd-performance-unsubscribe@freebsd.org"


  • Next message: Steven Hartland: "Re: Very low disk performance on 5.x"

    Relevant Pages