From: Yunseong Kim <yunseong.kim@est.tech>
To: Namjae Jeon <linkinjeon@kernel.org>
Cc: Yunseong Kim <yunseong.kim@est.tech>,
Sergey Senozhatsky <senozhatsky@chromium.org>,
Tom Talpey <tom@talpey.com>,
ChenXiaoSong <chenxiaosong@chenxiaosong.com>,
linux-cifs@vger.kernel.org, linux-kernel@vger.kernel.org,
ysk@kzalloc.com
Subject: Re: [PATCH 0/4] ksmbd: implement Continuously Available (CA) share support
Date: Thu, 27 Aug 2026 23:21:14 +0200 [thread overview]
Message-ID: <20260827212118.1509990-1-yunseong.kim@est.tech> (raw)
In-Reply-To: <CAKYAXd_Pp=197vL1w88d2=Y6yrpbfxzULuR04gDo1Y0-woTinA@mail.gmail.com>
Hi Namjae,
On Thu, 27 Aug 2026 16:54:30 +0900 Namjae Jeon <linkinjeon@kernel.org> wrote:
> On Mon, Aug 24, 2026 at 9:56 AM Yunseong Kim <yunseong.kim@est.tech> wrote:
> >
> > Enable the Continuously Available (CA) share infrastructure in ksmbd,
> > allowing SMB clients to request and use persistent handles on configured shares.
> >
> > Background
> > =====
> >
> > KSMBD already has a complete in-memory durable handle v1/v2
> > implementation including the persistent handle data model
> > (fp->is_persistent), protocol parsing (DH2Q with
> > SMB2_DHANDLE_FLAG_PERSISTENT), and reconnect validation (DH2C). However,
> > the server never advertises SMB2_GLOBAL_CAP_PERSISTENT_HANDLES or sets
> > SMB2_SHARE_CAP_CONTINUOUS_AVAILABILITY, making this code path unreachable
> > by clients.
> >
> > Per MS-SMB2, a client can only request a persistent handle on a share
> > that advertises SMB2_SHARE_CAP_CONTINUOUS_AVAILABILITY. This creates a
> > chicken-and-egg: we cannot test persistent handles without first
> > advertising the CA capability.
> This looks like a useful first step, but I don't think it provides CA
> support yet.
I agree, I was considering the validation aspects when I wrote this
v1 draft patch series.
> The handle state is still kept only in memory. The existing code can
> reconnect a durable handle after a connection or session loss while
> the server is still running, but that state is lost when ksmbd or the
> kernel is restarted. The server therefore can not reconstruct the open
> from the persistent-id or CreateGuid.
Thank you for summarizing this information.
> I think this should be implemented in two stages:
> 1. Standalone CA: add a local crash-safe journal/state store and
> recover the open state after a server restart, including
> persistent-handle, lease/oplock, ownership, and replay state.
Okay, I've been starting "Standalone CA" supports for the next v2 patch
series.
> 2. Cluster CA: make the persistent open state available to the node
> that takes over the share, then add cluster ownership management,
> stale-node fencing, and cross-node failover support.
After the standalone version has been verified and merged, I will work on it.
> Standalone CA should be implemented and validated first. Cluster CA,
> including cross-node failover, should then be built on top of it.
> Until standalone recovery is available, advertising the
> persistent-handle and CA capabilities seems premature. It seems that
> many updates will be needed to ksmbd-tools when implementing Cluster
> CA.
Understood, making a solid foundation first.
> Thanks.
>
Thank you!
Best regards,
Yunseong
prev parent reply other threads:[~2026-08-27 21:21 UTC|newest]
Thread overview: 7+ messages / expand[flat|nested] mbox.gz Atom feed top
2026-08-24 0:56 [PATCH 0/4] ksmbd: implement Continuously Available (CA) share support Yunseong Kim
2026-08-24 0:56 ` [PATCH 1/4] ksmbd: advertise SMB2_GLOBAL_CAP_PERSISTENT_HANDLES Yunseong Kim
2026-08-24 0:56 ` [PATCH 2/4] ksmbd: set SMB2_SHARE_CAP_CONTINUOUS_AVAILABILITY in tree connect Yunseong Kim
2026-08-24 0:56 ` [PATCH 3/4] ksmbd: add fencing for disconnected persistent handles Yunseong Kim
2026-08-24 0:56 ` [PATCH 4/4] ksmbd: enforce write-through on CA share opens Yunseong Kim
2026-08-27 7:54 ` [PATCH 0/4] ksmbd: implement Continuously Available (CA) share support Namjae Jeon
2026-08-27 21:21 ` Yunseong Kim [this message]
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=20260827212118.1509990-1-yunseong.kim@est.tech \
--to=yunseong.kim@est.tech \
--cc=chenxiaosong@chenxiaosong.com \
--cc=linkinjeon@kernel.org \
--cc=linux-cifs@vger.kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=senozhatsky@chromium.org \
--cc=tom@talpey.com \
--cc=ysk@kzalloc.com \
/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