Bug#939767: fuse3: Installing fuse3 breaks fuse2 applications using -o nonempty

2019-11-05 Thread Nikolaus Rath
Hi Dmitry,

I think you are confusing mounting into a directory that already contains files 
with re-mounting the same filesystem on top of itself.

Refusing to use a non-empty directory as a mountpoint does not prevent you from 
mounting the same filesystem multiple times, because the file system may be 
empty.  ext4 does not refuse such mounts either.

ext4 does prevent you from mounting the same filesystem onto the same 
mountpoint, but so (apparently) does FUSE: 

$ ls -l mnt
total 4
-rw-r--r-- 1 nikratio nikratio 4 Nov  5 00:40 testfile

$ ~/in-progress/sshfs/build/sshfs localhost:$PWD/empty mnt
$ ls -l mnt
total 0

$ ~/in-progress/sshfs/build/sshfs localhost:$PWD/empty mnt
fusermount3: failed to access mountpoint /home/nikratio/tmp/mnt: Permission 
denied

 I've never looked into this feature before and have no idea how/where it is 
implemented, but it is unrelated to -o nonempty.

Best,
Nikolaus

--
GPG Fingerprint: ED31 791B 2C5C 1613 AF38 8B8A D113 FCAC 3C4E 599F

 »Time flies like an arrow, fruit flies like a Banana.«

On Sun, 3 Nov 2019, at 19:40, Dmitry Smirnov wrote:
> > ...the one who mounts the filesystem need to be sure
> > s/he doesn't shadow real files / directories with the mount.
> 
> No, this is a very unsafe default because benign `mount -av` will create more 
> layered mounts on every invocation.
> 
> Mount should be idempotent by default.
> 
> 
> > This is the same with any other mounts as I know.
> 
> Not really. FYI attempt to mount ext4 for the second time comes back with 
> "already mounted" error and exit code 32.
> 
> IMHO mounting over non-empty folder should be only allowed with explicit 
> "force" option such as "-o nonempty".
> 
> 
> > Why this is a behavior change, the only callers just need to remove
> > the '-o nonempty' option, right? From the user point of view
> > everything will work exactly the same as I see.
> 
> Too many problems with that. First of all some software must be re-compiled 
> to remove "nonempty" option. Secondly, that makes file systems unsafe in 
> regards to `mount -av`.
> 
> I wonder what FUSE3 developers were thinking when they did such unsafe 
> breaking change?  :( :(
> 
> -- 
> All the best,
>  Dmitry Smirnov
> 
> ---
> 
> Truth never damages a cause that is just.
> -- Mahatma Gandhi
> 
> Attachments:
> * signature.asc



Bug#939767: fuse3: Installing fuse3 breaks fuse2 applications using -o nonempty

2019-11-03 Thread Dmitry Smirnov
> ...the one who mounts the filesystem need to be sure
> s/he doesn't shadow real files / directories with the mount.

No, this is a very unsafe default because benign `mount -av` will create more 
layered mounts on every invocation.

Mount should be idempotent by default.


> This is the same with any other mounts as I know.

Not really. FYI attempt to mount ext4 for the second time comes back with 
"already mounted" error and exit code 32.

IMHO mounting over non-empty folder should be only allowed with explicit 
"force" option such as "-o nonempty".


> Why this is a behavior change, the only callers just need to remove
> the '-o nonempty' option, right? From the user point of view
> everything will work exactly the same as I see.

Too many problems with that. First of all some software must be re-compiled 
to remove "nonempty" option. Secondly, that makes file systems unsafe in 
regards to `mount -av`.

I wonder what FUSE3 developers were thinking when they did such unsafe 
breaking change?  :( :(

-- 
All the best,
 Dmitry Smirnov

---

Truth never damages a cause that is just.
-- Mahatma Gandhi


signature.asc
Description: This is a digitally signed message part.


Bug#939767: fuse3: Installing fuse3 breaks fuse2 applications using -o nonempty

2019-09-08 Thread Nikolaus Rath
Hi,

Some files systems (eg S3QL) pass this option automatically to libfuse, in an 
attempt behave like regular mount even for libfuse 2.x. The user has no control 
over this, so the filesystem becomes unusable.

Best,


--
GPG Fingerprint: ED31 791B 2C5C 1613 AF38 8B8A D113 FCAC 3C4E 599F

 »Time flies like an arrow, fruit flies like a Banana.«

On Sun, 8 Sep 2019, at 16:54, László Böszörményi (GCS) wrote:
> On Sun, Sep 8, 2019 at 5:24 PM Nikolaus Rath  wrote:
> > fuse3 currently declares 'Replaces: fuse', but it is not actually a
> > drop-in replacement. FUSE 2.x filesystems that use the '-o nonempty' mount
> > option (which was removed in FUSE 3) break with
> >
> > fusermount: unknown option 'nonempty'
> >
> > if fuse3 is installed instead of fuse.
>  Thanks for the heads-up Nikolaus. As I know, FUSE 2.x doesn't allow
> mounting on non-empty directories by default, that's why you added
> that command line option. You removed this from FUSE 3 as being
> non-standard and the one who mounts the filesystem need to be sure
> s/he doesn't shadow real files / directories with the mount. This is
> the same with any other mounts as I know.
> Why this is a behavior change, the only callers just need to remove
> the '-o nonempty' option, right? From the user point of view
> everything will work exactly the same as I see.
> 
> Cheers,
> Laszlo/GCS
>



Bug#939767: fuse3: Installing fuse3 breaks fuse2 applications using -o nonempty

2019-09-08 Thread GCS
On Sun, Sep 8, 2019 at 5:24 PM Nikolaus Rath  wrote:
> fuse3 currently declares 'Replaces: fuse', but it is not actually a
> drop-in replacement. FUSE 2.x filesystems that use the '-o nonempty' mount
> option (which was removed in FUSE 3) break with
>
> fusermount: unknown option 'nonempty'
>
> if fuse3 is installed instead of fuse.
 Thanks for the heads-up Nikolaus. As I know, FUSE 2.x doesn't allow
mounting on non-empty directories by default, that's why you added
that command line option. You removed this from FUSE 3 as being
non-standard and the one who mounts the filesystem need to be sure
s/he doesn't shadow real files / directories with the mount. This is
the same with any other mounts as I know.
Why this is a behavior change, the only callers just need to remove
the '-o nonempty' option, right? From the user point of view
everything will work exactly the same as I see.

Cheers,
Laszlo/GCS



Bug#939767: fuse3: Installing fuse3 breaks fuse2 applications using -o nonempty

2019-09-08 Thread Nikolaus Rath
Package: fuse3
Version: 3.4.1-1
Severity: important

fuse3 currently declares 'Replaces: fuse', but it is not actually a
drop-in replacement. FUSE 2.x filesystems that use the '-o nonempty' mount
option (which was removed in FUSE 3) break with

fusermount: unknown option 'nonempty'

if fuse3 is installed instead of fuse.



-- System Information:
Debian Release: 10.1
  APT prefers stable-updates
  APT policy: (500, 'stable-updates'), (500, 'stable')
Architecture: amd64 (x86_64)

Kernel: Linux 4.19.0-5-amd64 (SMP w/8 CPU cores)
Kernel taint flags: TAINT_PROPRIETARY_MODULE, TAINT_OOT_MODULE, 
TAINT_UNSIGNED_MODULE
Locale: LANG=en_US.UTF-8, LC_CTYPE=en_US.UTF-8 (charmap=UTF-8), 
LANGUAGE=en_US.UTF-8 (charmap=UTF-8)
Shell: /bin/sh linked to /bin/dash
Init: systemd (via /run/systemd/system)
LSM: AppArmor: enabled

Versions of packages fuse3 depends on:
ii  adduser 3.118
ii  libc6   2.28-10
ii  libfuse3-3  3.6.2-1
ii  lsb-base10.2019051400
ii  mount   2.33.1-0.1
ii  sed 4.7-1

fuse3 recommends no packages.

fuse3 suggests no packages.

-- Configuration Files:
/etc/fuse.conf changed [not included]