From: Jeremy Allison <jra@samba.org>
To: Steve French <smfrench@gmail.com>
Cc: "linux-cifs@vger.kernel.org" <linux-cifs@vger.kernel.org>,
linux-fsdevel <linux-fsdevel@vger.kernel.org>
Subject: Re: Samba symlinks and dcache collisions
Date: Tue, 29 Sep 2015 16:44:09 -0700 [thread overview]
Message-ID: <20150929234409.GC18915@jeremy-acer> (raw)
In-Reply-To: <CAH2r5mutOeX--Z1Vq+VhDuHf1d38aqYhRQxA=Eetaeqt8qHGkA@mail.gmail.com>
On Mon, Sep 28, 2015 at 09:48:06PM -0500, Steve French wrote:
> directory listings of large directories on smb2/smb3 mounts to Samba
> sometimes shows the
>
> "Autodisabling the use of server inode numbers ..." message in dmesg.
>
> I have narrowed it down to cases where Samba is displaying symlink
> source and target with the same inode number (the client does not know
> they are symlinks since Samba does not set that file type when Unix
> Extensions are not available). Interestingly small directories with
> either symlinks or hardlinks in them don't cause the client to detect
> the inode number collision (which causes the server inode message to
> be displayed).
Yes, that's going to happen if symlinks are within the share
without UNIX extensions I'm afraid. We report them as the same file
(as they are).
> cifs_find_inode in fs/cifs/inode.c has the following check (after
> making sure that the inode numbers and mode of the two are the same
> and that they are not directories and that their creation time is the
> same)
>
> /* if it's not a directory or has no dentries, then flag it */
> if (S_ISDIR(inode->i_mode) && !hlist_empty(&inode->i_dentry))
> fattr->cf_flags |= CIFS_FATTR_INO_COLLISION;
>
> Not sure what causes the collision in the case of a larger directory
> but not a smaller one. It is puzzling because the source and target
> look (to the SMB3 client) similar to hardlinks with the same metadata
> except for file name (Samba server does not emulate symlinks as SMB3
> symlink reparse points or apple style symlinks so they look more like
> hardlinks to the client)
Nothing to do with directory size. Any link is going to do this
if it points within the share.
next prev parent reply other threads:[~2015-09-29 23:44 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2015-09-29 2:48 Samba symlinks and dcache collisions Steve French
2015-09-29 23:44 ` Jeremy Allison [this message]
2015-09-30 16:18 ` Steve French
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=20150929234409.GC18915@jeremy-acer \
--to=jra@samba.org \
--cc=linux-cifs@vger.kernel.org \
--cc=linux-fsdevel@vger.kernel.org \
--cc=smfrench@gmail.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;
as well as URLs for NNTP newsgroup(s).