Re: [PATCH v5 3/3] dm mpath: add CONFIG_DM_MULTIPATH_SG_IO - failover for SG_IO

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On 05/07/21 15:48, Martin Wilck wrote:
On Mo, 2021-07-05 at 15:11 +0200, Hannes Reinecke wrote:
On 7/5/21 3:02 PM, Paolo Bonzini wrote:
On 02/07/21 16:21, Martin Wilck wrote:
SG_IO gives you raw access to the SCSI logic unit, and you get
to
keep the pieces if anything goes wrong.

That's a very fragile user space API, on the fringe of being
useless
IMO.

Indeed.  If SG_IO is for raw access to an ITL nexus, it shouldn't
be supported at all by mpath devices.  If on the other hand SG_IO is
for raw access to a LUN, there is no reason for it to not support
failover.

Or we look at IO_URING_OP_URING_CMD, to send raw cdbs via io_uring.
And delegate SG_IO to raw access to an ITL nexus.
Doesn't help with existing issues, but should get a clean way
forward.

I still have to understand how this would help with the retrying
semantics. Wouldn't we get the exact same problem if a path error
occurs?

Also, how would the URING_CMD API differ from SG_IO modulo one being a ioctl and one being io_uring-based? In the end what you have to do is 1) send a CDB and optionally some data 2) get back a status and optionally some data and sense. Whether the intended use of the API is for an ITL nexus or a LUN doesn't really matter. So, what is the rationale for "SG_IO is for a nexus" in the first place, if you think that "raw CDBs for a LUN" is a useful operation? You can still use DM_TABLE_STATUS (iirc) to address a specific ITL nexus if desired.

Besides the virtualization case, think of udev rules that use SG_IO to retrieve the device identification page for an mpath device and create corresponding symlinks in /dev. They would fail if the first path is not responding, which is not desirable.

Paolo

--
dm-devel mailing list
dm-devel@xxxxxxxxxx
https://listman.redhat.com/mailman/listinfo/dm-devel





[Index of Archives]     [DM Crypt]     [Fedora Desktop]     [ATA RAID]     [Fedora Marketing]     [Fedora Packaging]     [Fedora SELinux]     [Yosemite Discussion]     [KDE Users]     [Fedora Docs]

  Powered by Linux