Linux CIFS filesystem development
 help / color / mirror / Atom feed
From: "Pali Rohár" <pali@kernel.org>
To: Volker Lendecke <Volker.Lendecke@sernet.de>
Cc: linux-cifs@vger.kernel.org
Subject: Re: [PATCH 6/7] cifs: Fix creating of SFU fifo and socket special files
Date: Mon, 16 Sep 2024 18:31:23 +0200	[thread overview]
Message-ID: <20240916163123.lj3pm4dhqfcv4ivi@pali> (raw)
In-Reply-To: <Zugp5RiYKqFUW_bk@sernet.de>

Hello Volker,

On Monday 16 September 2024 14:51:49 Volker Lendecke wrote:
> Hello Pali,
> 
> Am Sun, Sep 15, 2024 at 07:41:26PM +0200 schrieb Pali Rohár:
> > Now I have figured out that even the latest Windows Server 2022 version
> > provides interoperability of FIFOs in SFU format with Windows NFS 4.1
> > Server. So if you configure on Windows Server 2022 one share which is
> > exported over SMB and also NFS at the same time, and over SMB you create
> > SFU-style fifo, then Windows NFS4.1 server recognize it and properly
> > reports nfs4type as NFS4FIFO for NFSv4.1 client.
> 
> it might work in this direction. However, in my tests if you create a
> fifo over NFS you end up with a NFS-style reparse point, which is much
> less prone to misinterpretation.

Yes, that is truth. New NFS server versions by default create reparse
points with NFS tags for special files. I just pointed out that even new
NFS server can recognize old SFU-style of special files, which is useful
to know in some situation (e.g. for mix of old and cifs clients together
with nfs clients).

> So my suggestion would be to use the
> way that Microsoft properly documented in
> 
> https://learn.microsoft.com/en-us/openspecs/windows_protocols/ms-fscc/ff4df658-7f27-476a-8025-4074c0121eec
> 
> for anything that is newly created on all servers that can do reparse
> points. For servers that don't support reparse points, WSL might be an
> alternative. For me it would be highly confusing to add yet another
> representation of unix special files from new code.
> 
> Reading existing special files -- sure, where strictly required for
> compat reasons. Creating them? No. Too many options make the test
> matrix explode.
> 
> Volker

Important is that all my changes and whole discussion is about the
non-default cifs mount option '-o sfu' which disables creating reparse
points and uses only SFU-style of special files. So this is not a new
code but special compatibility case used in scenarios where reparse
points are either not supported or cifs client want to use normal files
for storing fifos/sockets/... in SFU-style.

I fully agree with you that in the default conditions new reparse points
should be used and created. And this behavior is not changed or affected
by these my patches.

But in this compatibility mode, which has to be manually activated by
user at cifs mount time by -o sfu option, we should follow what SFU is.

Note that when this -o sfu option is not specified then these special
system files are not recognized (or created) at all.

  reply	other threads:[~2024-09-16 16:31 UTC|newest]

Thread overview: 32+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2024-09-12 12:05 [PATCH 0/7] cifs: Improve client SFU support for special files Pali Rohár
2024-09-12 12:05 ` [PATCH 1/7] cifs: Fix recognizing SFU symlinks Pali Rohár
2024-09-13 20:04   ` Pali Rohár
2024-09-12 12:05 ` [PATCH 2/7] cifs: Add support for reading SFU symlink location Pali Rohár
2024-09-12 12:05 ` [PATCH 3/7] cifs: Put explicit zero byte into SFU block/char types Pali Rohár
2024-09-12 12:05 ` [PATCH 4/7] cifs: Show debug message when SFU Fifo type was detected Pali Rohár
2024-09-12 12:05 ` [PATCH 5/7] cifs: Recognize SFU socket type Pali Rohár
2024-09-12 12:05 ` [PATCH 6/7] cifs: Fix creating of SFU fifo and socket special files Pali Rohár
2024-09-13 20:07   ` Pali Rohár
2024-09-13 22:14     ` Steve French
2024-09-13 22:33       ` Steve French
2024-09-13 22:45         ` Pali Rohár
2024-09-13 22:42       ` Pali Rohár
2024-09-14  6:21         ` Steve French
2024-09-14  8:17           ` Pali Rohár
2024-09-15 17:41             ` Pali Rohár
     [not found]               ` <CAH2r5muXcyMxc=F2WsTtwQyKZ9TL64TWEBzX7bXJqZky2g0TzA@mail.gmail.com>
2024-09-15 17:48                 ` Pali Rohár
2024-09-16 16:23                   ` Pali Rohár
2024-09-16 12:51               ` Volker Lendecke
2024-09-16 16:31                 ` Pali Rohár [this message]
2024-09-15 19:45   ` [PATCH 0/4] cifs: Improve client SFU support for special files (2) Pali Rohár
2024-09-15 19:45     ` [PATCH 1/4] cifs: Add support for creating SFU symlinks Pali Rohár
2024-09-15 21:15       ` Steve French
2024-09-27 17:54       ` Enzo Matsumiya
2024-09-27 18:11         ` Pali Rohár
2024-09-15 19:45     ` [PATCH 2/4] cifs: Fix creating of SFU socket special files Pali Rohár
2024-09-15 19:45     ` [PATCH 3/4] cifs: Fix creating of SFU fifo " Pali Rohár
2024-09-15 19:45     ` [PATCH 4/4] cifs: Update SFU comments about fifos and sockets Pali Rohár
2024-09-15 21:14       ` Steve French
2024-09-12 12:05 ` [PATCH 7/7] cifs: Add support for creating SFU symlinks Pali Rohár
2024-09-13  3:44 ` [PATCH 0/7] cifs: Improve client SFU support for special files Steve French
2024-09-13  7:42   ` Pali Rohá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=20240916163123.lj3pm4dhqfcv4ivi@pali \
    --to=pali@kernel.org \
    --cc=Volker.Lendecke@sernet.de \
    --cc=linux-cifs@vger.kernel.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