Poor disk drive performance with FC3 RC3

David Zeuthen david at fubar.dk
Thu Nov 11 20:16:27 UTC 2004


On Fri, 2004-11-05 at 09:07 +0100, Arjan van de Ven wrote:
> On Thu, 2004-11-04 at 19:27 -0500, Alan Cox wrote:
> > On Thu, Nov 04, 2004 at 01:59:48PM -0500, David Zeuthen wrote:
> > > Basically hal does this (every two seconds)
> > > 
> > >  open("/dev/hdc", O_RDONLY|O_NONBLOCK|O_EXCL|O_LARGEFILE) = 0
> > >  ioctl(0, CDROM_DRIVE_STATUS, 0x7fffffff) = 1
> > >  close(0) 
> > > 
> > > Can some kernel person comment on why this is killing performance on
> > > the /dev/hda harddrive when the optical drive at /dev/hdb is polled?
> > 
> > Because /dev/hdb is powersaved. Every time you poll it the laptop powers up
> > the drive (costly on power/time), polls the TOC, replies and a second or so
> > later powers back down.  During the power up, poll TOC sequence it locks the
> > bus so your IDE bus spends 1.5 of every 2 seconds jammed by the drive.
> 
> it sounds like HAL should measure how long such a poll takes (shouldn't
> be too hard) and then add like 10 times that time to the 2 seconds
> interval. On fast hw you get almost a 2 second interval but on really
> slow cdroms you still can get decent performance.

Another more straightforward option is of course to poll more than once
a second so the drive never goes into power saving mode and thus never
jams the bus :-). No, seriously, it would best not to poll as well, but
we do need the media change notifications.

Cheers,
David




More information about the fedora-test-list mailing list