Debian KVM guest won't allow dma to be set on /dev/hda - lots of DMA timeout errors

yatesco

Renowned Member
Sep 25, 2009
214
5
83
Hi all,

I have a KVM Debian lenny machine running on an up to date proxmox 1.5, 2.6.24 kernel with a RAW file mapped as an IDE file (/dev/hda).

It is a postgres server and is *really* slow until you turn on DMA (hdparm -d1 /dev/hda). The problem is that after a while it goes slow again and it turns out that DMA has been turned off. dmesg contains a few entries of:

Code:
[36400.000040] hda: dma_timer_expiry: dma status == 0x21
[36410.000041] hda: DMA timeout error
[36410.004022] hda: dma timeout error: status=0xd8 { Busy }
[36410.004022] ide: failed opcode was: unknown
[36410.004022] hda: DMA disabled
[36428.256238] ide0: reset: success

Has anyone experienced this before? What does this mean - is dma unreliable in KVM? If so, what can I do about it as the performance is terrible without it? As a non-scientific benchmark, rendering the JIRA home page without DMA takes 10 seconds or so, it is almost instant with DMA enabled.

Would reverting back to a 2.6.18 kernel resolve this issue? I cannot move to the .32 kernel as I need the containers.
 
Re: Debian KVM guest won't allow dma to be set on /dev/hda - lots of DMA timeout erro

did you try virtio instead of ide?
 
Re: Debian KVM guest won't allow dma to be set on /dev/hda - lots of DMA timeout erro

Nope, not yet.

Thinking about it, this whole machine has a massive IO bottleneck (150 FSYNCS) so given the nature of the error (DMA timeouts), I wonder whether the writing is on the wall, so to speak. I am getting a new server soon with a decent RAID card and SAS disks, so I might put this on hold until then....

Thanks for your help anyway.
 
Re: Debian KVM guest won't allow dma to be set on /dev/hda - lots of DMA timeout erro

Is virtio considered more stable than IDE now?