[SPDK] Re: is it possible to add a blacklist for the lvol module?
Zawadzki, Tomasz <tomasz.zawadzki at intel.com>
| Newsgroups | dev.linux.lists.spdk |
|---|---|
| Message-ID | <BN6PR11MB1713DF341875C8AA233C4FEFEEC80@BN6PR11MB1713.namprd11.prod.outlook.com> |
Hi Peng Yu, Described scenario can occur for any bdev module that examines device being attached for metadata. Lvols, GPT, OCF, Raid5 (in future) and other custom ones. At this time there is no way to disable bdevs from examining the devices, without code changes. The proposed API would have to be on bdev layer, rather than any of the bdev module types. There is bdev subsystem options that could be changed (bdev_set_options() RPC). Another argument could be added that disables all examination, or as suggested blacklists examination on bdev name/alias/uuid. Drawback here is those options can be set only before subsystems are started (see framework_start_init()). So one cannot change mind after that. Bdev API could be extended with explicit 'examine' RPC to allow run-time examination for all or select bdev. Personally I'm not set on an approach, as examine functionality was supposed to be "straightforward" to use. Yet your example shows that in scenarios where SPDK is used on both ends of a connection (NVMe-oF/iSCSI/vhost), needs more thought. I'll add this topic to today's Community meeting agenda, please feel free to attend: https://spdk.io/community/ Thanks, Tomek > -----Original Message----- > From: peng yu <yupeng0921(a)gmail.com> > Sent: Monday, March 30, 2020 8:56 PM > To: Storage Performance Development Kit <spdk(a)lists.01.org> > Subject: [SPDK] is it possible to add a blacklist for the lvol module? > > I have a below scenario: > A disk is controlled by SPDK APP A. > SPDK APP A exports the disk as a NVMEoF target SPDK APP B is a NVMEoF > initiator, it connects to that disk. > SPDk APP B creates a lvs and a lvol on the disk. > When I restart the APP A and APP B. The APP A will examine the disk and find > there is a lvs, and then the lvol module on APP A will claim this disk, then this > disk can't be exported over NVMEoF. > > Could we add a api to the lvol module? The api could add a dev name pattern > to a black list. When the lvol module examine a disk, it will check against the > black list, if a dev name matches the black list, it will ignore this device. > > Best regards. > _______________________________________________ > SPDK mailing list -- spdk(a)lists.01.org > To unsubscribe send an email to spdk-leave(a)lists.01.org