umount problem with trailing slashes
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
util-linux (Ubuntu) |
New
|
Undecided
|
Unassigned |
Bug Description
Binary package hint: util-linux
The umount program can not unmount CIFS shares if the CIFS address has no a trailing slash and if the "user" option is enabled.
One example:
From /etc/fstab:
//linux/steve /media/test cifs defaults,
$ mount /media/test
Password:
$ mount | grep /media/test
//linux/steve/ on /media/test type cifs (rw,mand,
$ umount /media/test
umount: /media/test mount disagrees with the fstab
After some searching, I found that "//linux/steve/" from "mount" (or /etc/mtab or /proc/mounts) has a trailing slash, but "//linux/steve" from /etc/fstab has no trailing slash. Anyway mounting as normal user works, but unmounting does not work. As a workaround, I can add a trailing slash to the entry in /etc/fstab:
//linux/steve/ /media/test cifs defaults,
I think, that "umount" should be more tolerant with trailing slashes. The canonicalize function currently does not handle the problem right.
I tested with
mount from util-linux-ng 2.17.2 (with libblkid and selinux support) - from Ubuntu 10.10
and with
mount from util-linux-ng 2.17.2 (with libblkid support) - from Launchpad (with util-linux_