shadow_copy2_realpath() snapshot path component removal

Richard Sharpe realrichardsharpe at
Thu Feb 13 15:00:37 MST 2014

On Wed, Feb 12, 2014 at 5:43 AM, David Disseldorp <ddiss at> wrote:
> Hi Volker,
> As part of the shadow_copy2 module rewrite, logic was added to remove
> any snapshot component (e.g. @GMT-1984...) from the path returned by the
> realpath VFS hook.
> Do you recall whether there was something at a protocol level that
> required this behaviour, or was it done to avoid wide link checks
> so that snapshots could reside outside of the base share?

One thing I notice in looking at the code is that it does not seem to
behave the way Windows really does.

For example, if your snapshots are read-only, I suspect that users
will get ACCESS_DENIED messages when trying to open a shadow-copy file
for write-like access, but Windows allows such access and returns
VOLUME_WRITE_PROTECTED when you try to actually perform write-like

Richard Sharpe

More information about the samba-technical mailing list