All the mail mirrored from lore.kernel.org
 help / color / mirror / Atom feed
* Problem with virtio-scsi timeouts
@ 2017-06-21 14:21 Douglas Miller
  2017-06-21 14:36 ` Paolo Bonzini
  0 siblings, 1 reply; 3+ messages in thread
From: Douglas Miller @ 2017-06-21 14:21 UTC (permalink / raw
  To: kvm

The problem I have seen is that the standard SCSI driver has a default 
timeout on I/O of 30 seconds. But when this driver is used on a KVM 
guest via virtio-scsi, the host should be controlling the timeout based 
on the actual type of media, and those timeouts may need to be longer. 
The KVM guest 'sd' I/O then happily timeout at 30 seconds and try to 
abort the commands. With a heavy I/O load it become likely that an abort 
will also timeout and this leads to fatal errors like filesystems going 
offline.

It seems that the virtio-scsi driver should disable the 'sd' timeout and 
allow the host to handle that. Maybe this has been done already and just 
not been backported to distros, but is it reasonable to disable the 'sd' 
timeout in KVM guests? Or at least should the default timeout be 
increased to a much larger value?

Thanks,

Doug

^ permalink raw reply	[flat|nested] 3+ messages in thread

* Re: Problem with virtio-scsi timeouts
  2017-06-21 14:21 Problem with virtio-scsi timeouts Douglas Miller
@ 2017-06-21 14:36 ` Paolo Bonzini
  2017-06-21 14:46   ` Douglas Miller
  0 siblings, 1 reply; 3+ messages in thread
From: Paolo Bonzini @ 2017-06-21 14:36 UTC (permalink / raw
  To: Douglas Miller, kvm



On 21/06/2017 16:21, Douglas Miller wrote:
> The problem I have seen is that the standard SCSI driver has a default
> timeout on I/O of 30 seconds. But when this driver is used on a KVM
> guest via virtio-scsi, the host should be controlling the timeout based
> on the actual type of media, and those timeouts may need to be longer.
> The KVM guest 'sd' I/O then happily timeout at 30 seconds and try to
> abort the commands. With a heavy I/O load it become likely that an abort
> will also timeout and this leads to fatal errors like filesystems going
> offline.
> 
> It seems that the virtio-scsi driver should disable the 'sd' timeout and
> allow the host to handle that. Maybe this has been done already and just
> not been backported to distros, but is it reasonable to disable the 'sd'
> timeout in KVM guests? Or at least should the default timeout be
> increased to a much larger value?

Actually that patch has been posted, but never committed.  I have just
sent it again.

Paolo

^ permalink raw reply	[flat|nested] 3+ messages in thread

* Re: Problem with virtio-scsi timeouts
  2017-06-21 14:36 ` Paolo Bonzini
@ 2017-06-21 14:46   ` Douglas Miller
  0 siblings, 0 replies; 3+ messages in thread
From: Douglas Miller @ 2017-06-21 14:46 UTC (permalink / raw
  To: Paolo Bonzini, kvm

Thanks Paolo! I will try and get some test time on this patch.


On 06/21/2017 09:36 AM, Paolo Bonzini wrote:
>
> On 21/06/2017 16:21, Douglas Miller wrote:
>> The problem I have seen is that the standard SCSI driver has a default
>> timeout on I/O of 30 seconds. But when this driver is used on a KVM
>> guest via virtio-scsi, the host should be controlling the timeout based
>> on the actual type of media, and those timeouts may need to be longer.
>> The KVM guest 'sd' I/O then happily timeout at 30 seconds and try to
>> abort the commands. With a heavy I/O load it become likely that an abort
>> will also timeout and this leads to fatal errors like filesystems going
>> offline.
>>
>> It seems that the virtio-scsi driver should disable the 'sd' timeout and
>> allow the host to handle that. Maybe this has been done already and just
>> not been backported to distros, but is it reasonable to disable the 'sd'
>> timeout in KVM guests? Or at least should the default timeout be
>> increased to a much larger value?
> Actually that patch has been posted, but never committed.  I have just
> sent it again.
>
> Paolo
>

^ permalink raw reply	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2017-06-21 14:46 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2017-06-21 14:21 Problem with virtio-scsi timeouts Douglas Miller
2017-06-21 14:36 ` Paolo Bonzini
2017-06-21 14:46   ` Douglas Miller

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.