Package: util-linux
Version: 2.25.1-3ubuntu4
Severity: normal

According to manpage, mount $single_argument looks for that argument
in /etc/fstab. However, when said argument is an existing mountpoint not
listed in the fstab, mount still tries to perform something, apparently
mount the same device over the same mountpoint. Usually that results in
“device busy” error (a particularly funny one if special filesystems
such as /sys/kernel/debug are involved), but not in case of tmpfs,
where it just creates a new tmpfs and attaches it to the same directory,
hiding existing files until the new tmpfs is unmounted.

For example, call mount /run and ls /run.
Expected: an error because there’s no entry for /run in fstab.
Actually: all files under /run disappear until umount /run is called.

Apparently mount behaves as though the contents of /proc/mounts were
appended to /etc/fstab. This is contrary to documentation and doesn’t
sound like a good idea anyway. What are the reasons for such behavior?

Also, even when a tmpfs entry is present in fstab, having mount create
new tmpfs’es each time seems error-prone. Given that uses for attaching
more than one FS to the same mountpoint are narrow, I suggest mount only
do that if explicitly instructed by means of the two-argument form,
otherwise decline to perform a duplicate mount.


-- System Information:
Debian Release: jessie/sid
  APT prefers utopic-updates
  APT policy: (500, 'utopic-updates'), (500, 'utopic-security'), (500, 'utopic')
Architecture: i386 (i686)

Kernel: Linux 3.16.0-25-generic (SMP w/2 CPU cores)
Locale: LANG=en_US.UTF-8, LC_CTYPE=en_US.UTF-8 (charmap=UTF-8)
Shell: /bin/sh linked to /bin/dash

Versions of packages util-linux depends on:
ii  initscripts    2.88dsf-41ubuntu18
ii  libblkid1      2.25.1-3ubuntu4
ii  libc6          2.19-10ubuntu2
ii  libmount1      2.25.1-3ubuntu4
ii  libncurses5    5.9+20140712-2ubuntu1
ii  libpam0g       1.1.8-3ubuntu4
ii  libselinux1    2.3-1build1
ii  libslang2      2.2.4-17ubuntu1
ii  libsmartcols1  2.25.1-3ubuntu4
ii  libtinfo5      5.9+20140712-2ubuntu1
ii  libuuid1       2.25.1-3ubuntu4
ii  lsb-base       4.1+Debian11ubuntu8
ii  tzdata         2014i-0ubuntu0.14.10
ii  zlib1g         1:1.2.8.dfsg-1ubuntu1

util-linux recommends no packages.

Versions of packages util-linux suggests:
ii  dosfstools          3.0.26-3
ii  kbd                 1.15.5-1ubuntu1
ii  util-linux-locales  2.25.1-3ubuntu4

-- debconf information excluded


-- 
To UNSUBSCRIBE, email to [email protected]
with a subject of "unsubscribe". Trouble? Contact [email protected]

Reply via email to