public inbox for spdk@lists.linux.dev
 help / color / mirror / Atom feed
From: Jonas Pfefferle <pepperjo at japf.ch>
To: spdk@lists.01.org
Subject: [SPDK] Re: NVMf namespace masking 2nd
Date: Wed, 13 Oct 2021 09:21:34 +0200	[thread overview]
Message-ID: <ximss-197955883@switchplus-mail.ch> (raw)
In-Reply-To: 1790D03B-3E6C-4604-B7B5-F593B160184E@intel.com

[-- Attachment #1: Type: text/plain, Size: 3942 bytes --]

Thanks Jim.

Addressing those now.

  On Tue, 12 Oct 2021 22:44:17 +0000
  "Harris, James R" <james.r.harris(a)intel.com> wrote:
> Hi Jonas,
> 
> This is looking in pretty good shape.  I added some comments in the 
>Gerrit review.
> 
> Thanks,
> 
> Jim
> 
> 
> On 10/5/21, 12:34 AM, "Jonas Pfefferle" <pepperjo(a)japf.ch> wrote:
> 
>    Hi all,
> 
>    I updated the NVMf namespace masking PR:
>    https://review.spdk.io/gerrit/c/spdk/spdk/+/7821
> 
>    Changes to RFC:
>    - Address concerns of overhead of checking on IO path.
>       If a namepsace is active is only checked where needed and
>       validity checks for NSID is only done once.
>    - Allow to hot and cold attach/detach
>    - It is no longer possible to call the new RPCs without
>       hostNQN. The auto attach bevahior cannot be changed
>       after add_ns. We might add an additional RPC for this
>       later.
>    - identify ns now correctly response with zeros for
>       inactive namespace
>    - Address concurrency concerns: attaching/detaching
>       now pauses the subsystem for changes
>    - ns change log is updated on attach/detach
>    - tests
> 
>    I would be happy to get some feeedback.
> 
>    Thanks,
>    Jonas
> 
>      On Sat, 08 May 2021 15:37:09 +0200
>      "Jonas Pfefferle" <pepperjo(a)japf.ch> wrote:
>    > Hi all,
>    > 
>    > I would be happy to get some feedback on my NVMf target 
>namespace 
>    >masking implementation using attach/detach:
>    > https://review.spdk.io/gerrit/c/spdk/spdk/+/7821
>    > 
>    > The patch introduces namespace masking for NVMe-over-fabrics
>    > targets by allowing to (dynamically) attach and detach
>    > controllers to/from namespaces, cf. NVMe spec 1.4 - section 
>6.1.4.
>    > Since SPDK only supports the dynamic controller model a new
>    > controller is allocated on every fabric connect command.
>    > This allows to attach/detach controllers of a specific
>    > host NQN to/from a namespace. A host can only perform
>    > operations to an active namespace. Inactive namespaces can
>    > be listed (not supported by SPDK) but no additional
>    > information can be retrieved:
>    > "Unless otherwise noted, specifying an inactive NSID in a
>    > command that uses the Namespace Identifier (NSID) field shall
>    > cause the controller to abort the command with status
>    > Invalid Field in Command" - NVMe spec 1.4 - section 6.1.5
>    > Note that this patch does not implement the NVMe namespace
>    > attachment command but allows to attach/detach via RPCs only.
>    > To preserve current behavior all controllers are auto attached.
>    > To not not auto attach controllers the nvmf_subsystem_add_ns
>    > shall be called with "--no-auto-attach". We introduce two new
>    > RPC calls:
>    > - nvmf_ns_attach_ctrlr <subsysNQN> <NSID> [--host <hostNQN>]
>    > - nvmf_ns_detach_ctrlr <subsysNQN> <NSID> [--host <hostNQN>]
>    > If no host NQN is specified all controllers
>    > (new and currently connected) will attach/detach to/from the
>    > namespace specified.
>    > The list in spdk_nvmf_ns is used to keep track of hostNQNs
>    > which controllers should be attached on connect.
>    > The active_ns array in spdk_nvmf_ctrlr is used for fast lookup
>    > to check whether a NSID is active/inactive on command 
>execution.
>    > 
>    > Thanks,
>    > Jonas
>    > _______________________________________________
>    > SPDK mailing list -- spdk(a)lists.01.org
>    > To unsubscribe send an email to spdk-leave(a)lists.01.org
> 
>    _______________________________________________
>    SPDK mailing list -- spdk(a)lists.01.org
>    To unsubscribe send an email to spdk-leave(a)lists.01.org
> 
> _______________________________________________
> SPDK mailing list -- spdk(a)lists.01.org
> To unsubscribe send an email to spdk-leave(a)lists.01.org


             reply	other threads:[~2021-10-13  7:21 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2021-10-13  7:21 Jonas Pfefferle [this message]
  -- strict thread matches above, loose matches on Subject: below --
2021-10-12 22:44 [SPDK] Re: NVMf namespace masking 2nd Harris, James R

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=ximss-197955883@switchplus-mail.ch \
    --to=spdk@lists.01.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox