[PATCH] nvmet: return 'namespace not ready' for disabled namespaces
Christoph Hellwig
hch at lst.de
Wed Aug 21 23:56:30 PDT 2024
On Mon, Aug 19, 2024 at 05:22:18PM +0300, Sagi Grimberg wrote:
> subsystems in nvmet based implementations are not limited to a single
> server. The originated reporter ran a subsystem over multiple hosts
> with drbd as the backend.
>
> In this case, disabled NS does need to signal a path error, and hence why
> a path error was chosen.
>
> If you want to change that, please make sure that io failover works as
> expected in this case as well.
Exactly. nvmet_subsys_nsid_exists indicates the nsid is configured
in the subsystem, so NVME_SC_INTERNAL_PATH_ERROR is the right error
to return here. For the !nvmet_subsys_nsid_exists case we already
return NVME_SC_INVALID_NS, which is the correct error if it does not
exist. NVME_SC_NS_NOT_READY is always wrong.
More information about the Linux-nvme
mailing list