gmirror performance

Ivan Voras ivoras at freebsd.org
Wed Mar 16 12:01:12 UTC 2011


On 15/03/2011 15:56, Lorenzo Perone wrote:
>
> Hi @ list, Hi Pawel,
>
> just a question about gmirror performance. I have 2 15k SAS drives,
> mirrored by gmirror. the mirror was setup like this (like manpage example):
>
> gmirror label -v -b split -s 2048 mirr0 da0 da1
>
> on a partition of this drive, I make the following test:
>
> # dd if=/dev/zero bs=1m count=2000 of=/mnt/2gigfile.dat
> 2000+0 records in
> 2000+0 records out
> 2097152000 bytes transferred in 11.203763 secs (187182824 bytes/sec)
>
> # umount /mnt
> # mount /dev/mirror/mirr0p4 /mnt
>
> # dd if=/mnt/2gigfile.dat of=/dev/null bs=1m
> 2000+0 records in
> 2000+0 records out
> 2097152000 bytes transferred in 12.061197 secs (173875942 bytes/sec)
>
> I'd expect read performance to be noticeably higher than write
> performance. Why is it not the case? Wrong expectation? :/

Maybe. You can't expect that RAID-1 will have as good performance as 
RAID-0 but you might achieve better performance for sequential reads 
with long buffers. Try setting the vfs.read_max sysctl to 128 and see if 
it helps you. (you might want to leave the gmirror algorithm to the 
default "load" and increase the stripe size to something sane, like 16k).




More information about the freebsd-fs mailing list