OpenVZ / Virtuozzo kernel development (devel@openvz.org)
 help / color / mirror / Atom feed
* [Devel] [PATCH hci-8.2 0/7] dm-qcow2, dm-ploop: report ENOSPC at once for vhost-blk disks
@ 2026-11-27 11:15 Alexander Ivanov
  2026-11-27 11:15 ` [Devel] [PATCH hci-8.2 1/7] dm-qcow2: always resubmit delayed ENOSPC requests in presuspend Alexander Ivanov
                   ` (7 more replies)
  0 siblings, 8 replies; 15+ messages in thread
From: Alexander Ivanov @ 2026-11-27 11:15 UTC (permalink / raw)
  To: andrey.zhadchenko; +Cc: devel

dm-qcow2 and dm-ploop delay a request that fails with ENOSPC, retry
it every 20 seconds and report the error with a dm event. QEMU cannot
wait for dm events or send dm messages without CAP_SYS_ADMIN, so a VM
on a vhost-blk disk is never paused and just hangs until space is
freed.

ENOSPC of a VM is to be held in vhost-blk instead: it keeps the failed
request out of the used ring and signals QEMU, which pauses the VM
with io-error and resubmits the request on resume or after migration.
For that the error has to reach vhost-blk, so the dm targets get a
table argument that turns their delay off. Containers keep the delay.

Patches 1-3 fix the existing ENOSPC delay of dm-qcow2:
- a suspend stalled by a request delayed while the timer runs
- a retry postponed indefinitely by new failures
- a WARN on a read failing with ENOSPC, fatal with panic_on_warn

Patches 4-5 fix the same in dm-ploop:
- a retry postponed indefinitely by new failures
- a WARN on a flush or a read failing with ENOSPC

Patches 6-7 add the report_enospc table argument to dm-qcow2 and
dm-ploop. Userspace passes it with every table it loads, and the
table status shows it.

The vhost-blk, QEMU, ploop.ovz and libvirt changes follow as separate
series.

https://virtuozzo.atlassian.net/browse/VSTOR-152175

Assisted-by: LLM

Alexander Ivanov (7):
  dm-qcow2: always resubmit delayed ENOSPC requests in presuspend
  dm-qcow2: arm the ENOSPC timer only for the first delayed request
  dm-qcow2: drop the WARN on a read failing with ENOSPC
  dm-ploop: arm the ENOSPC timer only for the first delayed request
  dm-ploop: drop the WARN on a non-write request failing with ENOSPC
  dm-qcow2: add the report_enospc table argument
  dm-ploop: add the report_enospc table argument

 drivers/md/dm-ploop-map.c    | 23 +++++++++++------------
 drivers/md/dm-ploop-target.c |  9 ++++++++-
 drivers/md/dm-ploop.h        |  1 +
 drivers/md/dm-qcow2-map.c    | 23 +++++++++++------------
 drivers/md/dm-qcow2-target.c | 29 ++++++++++++++++++++++++-----
 drivers/md/dm-qcow2.h        |  1 +
 6 files changed, 56 insertions(+), 30 deletions(-)

-- 
2.53.0

_______________________________________________
Devel mailing list
Devel@openvz.org
https://lists.openvz.org/mailman/listinfo/devel

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

end of thread, other threads:[~2026-11-30 16:28 UTC | newest]

Thread overview: 15+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2026-11-27 11:15 [Devel] [PATCH hci-8.2 0/7] dm-qcow2, dm-ploop: report ENOSPC at once for vhost-blk disks Alexander Ivanov
2026-11-27 11:15 ` [Devel] [PATCH hci-8.2 1/7] dm-qcow2: always resubmit delayed ENOSPC requests in presuspend Alexander Ivanov
2026-11-27 11:15 ` [Devel] [PATCH hci-8.2 2/7] dm-qcow2: arm the ENOSPC timer only for the first delayed request Alexander Ivanov
2026-11-27 11:51   ` Konstantin Khorenko
2026-11-27 11:15 ` [Devel] [PATCH hci-8.2 3/7] dm-qcow2: drop the WARN on a read failing with ENOSPC Alexander Ivanov
2026-11-27 11:51   ` Konstantin Khorenko
2026-11-27 11:15 ` [Devel] [PATCH hci-8.2 4/7] dm-ploop: arm the ENOSPC timer only for the first delayed request Alexander Ivanov
2026-11-27 11:15 ` [Devel] [PATCH hci-8.2 5/7] dm-ploop: drop the WARN on a non-write request failing with ENOSPC Alexander Ivanov
2026-11-27 11:15 ` [Devel] [PATCH hci-8.2 6/7] dm-qcow2: add the report_enospc table argument Alexander Ivanov
2026-11-27 11:51   ` Konstantin Khorenko
2026-11-27 11:15 ` [Devel] [PATCH hci-8.2 7/7] dm-ploop: " Alexander Ivanov
2026-11-27 11:51   ` Konstantin Khorenko
2026-11-27 11:51 ` [Devel] [PATCH hci-8.2 0/7] dm-qcow2, dm-ploop: report ENOSPC at once for vhost-blk disks Konstantin Khorenko
2026-11-30  9:14   ` Alexander Ivanov
2026-11-30 16:27     ` Konstantin Khorenko

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox