Bug#886811: Can't do system-wide mounts/unmounts in a ssh sessions
Package: openssh-server
Version: 1:7.6p1-2
Mounting or unmounting filesystems from within a ssh session used to
affect all processes, but now it only affects ssh sessions (all of them,
not just the one doing the mounts/unmounts).
To reproduce:
$ ssh root@debian-box
# dd if=/dev/zero of=/disk.img bs=1M count=20
# dev=$(losetup --show --find /disk.img)
# mkfs.ext4 $dev
# mount $dev /mnt
# grep /mnt /proc/self/mounts
/dev/loop0 /mnt ext4 rw,relatime,data=ordered 0 0
# grep /mnt /proc/1/mounts
<empty>
It seems that sshd and all its sessions are now in a single dedicated
"mnt" namespace:
# lsns
NS TYPE NPROCS PID USER COMMAND
...
4026532316 mnt 1 508 root /usr/sbin/sshd -D
...
Reply to: