A few things from my perspective: 1) Using dd to test disk performance is somewhat of a misnomer. You should consider a tool like bonnie++ instead (ports/benchmarks/bonnie++). 2) Using block sizes of 512 bytes is pretty absurd. Try other block sizes, preferably 8KB, 16KB, 32KB, and 64KB. You may find disk performance is quite a bit better in such cases. 3) I happen to agree with Arne -- Linux is probably tricking you into believing the disk performance is higher than what it is due to memory caching. 4) There was a recent thread about ICH2-related issues (I believe performance was one of them) here on freebsd-current: http://lists.freebsd.org/mailman/htdig/freebsd-current/2004-September/036841.html 5) I have no idea what's up with the ATA channel re-init. Soren should (and probably will) chime in here. 6) I'm still amazed people have systems in production that use ICH2. AFAIK, the chipset is deprecated. -- | Jeremy Chadwick jdc at parodius.com | | Parodius Networking http://www.parodius.com/ | | UNIX Systems Administrator Mountain View, CA, USA | | Making life hard for others since 1977. | On Sat, Sep 25, 2004 at 10:59:43PM +0200, Mauro Triulzi wrote: > Hello, > > I post some tests about the performance of my ATA disk (which is not > very spectacular under FREEBSD 6.0). > Notice that the write performance improves considerably after > reinitializing the ATA channel. I've given a comparison with > the performance under Linux (kernel 2.6.5) which is far better (with > identical HW of course, since I can boot > both Linux 2.6.5 and FreeBSD current). Can someone help me to explain > this facts or tell me what I am doing wrong? > > Kind regards, Mauro > > i) System & hardware > > foo# uname -a > FreeBSD foo.bar.com 6.0-CURRENT FreeBSD 6.0-CURRENT #0: Sat Sep 25 > 17:54:29 CEST 2004 > triulzi_at_foo.bar.com:/usr/src/sys/i386/compile/MYKERNEL i386 > > source tree actualized and built today, all debugging options disabled. > > My HW: > > foo# pciconf -v -l > (...) > atapci0_at_pci0:31:1: class=0x010180 card=0x01451028 chip=0x244b8086 > rev=0x04 hdr=0x00 > vendor = 'Intel Corporation' > device = '82801BA (ICH2) UltraATA/100 IDE Controller' > class = mass storage > subclass = ATA > (...) > > Mode (before reinitialization, see below) > > foo# atacontrol mode 0 > Master = UDMA100 > Slave = BIOSPIO > > Kernel parameters (also before reinitialization): > foo# sysctl hw.ata. > > hw.ata.ata_dma: 1 > hw.ata.wc: 1 > hw.ata.atapi_dma: 1 > > ii) TESTS: all tests with 512B blocks read/write > > a) under FreeBSD > > Write test: > > foo# date && dd if=/dev/zero of=deleteme.now count=1000000 && date > Sat Sep 25 22:04:02 CEST 2004 > 1000000+0 records in > 1000000+0 records out > 512000000 bytes transferred in 34.238161 secs (14954074 bytes/sec) > Sat Sep 25 22:04:36 CEST 2004 > > Read test: > > foo# date && dd if=/dev/ad0s3g of=/dev/null count=1000000 && date > Sat Sep 25 22:08:13 CEST 2004 > 1000000+0 records in > 1000000+0 records out > 512000000 bytes transferred in 125.686697 secs (4073621 bytes/sec) > Sat Sep 25 22:10:18 CEST 2004 > > Reinitialize the ATA channel: > > foo# atacontrol reinit 0 > Master: ad0 <IC35L060AVV207-0/V22OA63A> ATA/ATAPI revision 6 > Slave: no device present > > Write test after reinitialization: > > foo# date && dd if=/dev/zero of=deleteme.now count=1000000 && date > Sat Sep 25 22:12:30 CEST 2004 > 1000000+0 records in > 1000000+0 records out > 512000000 bytes transferred in 15.110452 secs (33883831 bytes/sec) > Sat Sep 25 22:12:45 CEST 2004 > > (about twice faster!! Why?) > > Read test after reinitialization: > > foo# date && dd if=/dev/ad0s3f of=/dev/null count=1000000 && date > Sat Sep 25 22:14:51 CEST 2004 > 1000000+0 records in > 1000000+0 records out > 512000000 bytes transferred in 125.860301 secs (4068002 bytes/sec) > Sat Sep 25 22:16:56 CEST 2004 > > (read from another device to avoid caching effects) > > Reinitialization of the ATA channel has effects only on write performance. > Read performance is very bad. > > b) Now the same under Linux (kernel 2.6.5) > > Write performance > > linux:/usr # date && dd if=/dev/zero of=deleteme.now count=1000000 && date > Sat Sep 25 21:38:30 CEST 2004 > 1000000+0 records in > 1000000+0 records out > Sat Sep 25 21:38:35 CEST 2004 > > deleteme.now is about 488 MB, rate about 100 MB/sec!! > > Read performance > > linux:/usr # date && dd if=/dev/hda11 of=/dev/null count=1000000 && date > Sat Sep 25 21:41:31 CEST 2004 > 1000000+0 records in > 1000000+0 records out > Sat Sep 25 21:41:43 CEST 2004 > > that is about 40MB/sec!! (/dev/hda11 read for the first time, to avoid > caching). > > Kind regards, > Mauro > > > _______________________________________________ > freebsd-current_at_freebsd.org mailing list > http://lists.freebsd.org/mailman/listinfo/freebsd-current > To unsubscribe, send any mail to "freebsd-current-unsubscribe_at_freebsd.org"Received on Sat Sep 25 2004 - 19:45:16 UTC
This archive was generated by hypermail 2.4.0 : Wed May 19 2021 - 11:38:13 UTC