I'm using an up to date fedora 18.
I've been asking this question in several forums and not found an answer yet. Does mount --move work? I've tried this with selinux enabled and disabled and never been able to make it work:
# cd /var/tmp/ # mkdir -p foo bar # mount -t tmpfs tmpfs foo # mount --move foo bar mount: wrong fs type, bad option, bad superblock on /var/tmp/foo, missing codepage or helper program, or other error In some cases useful info is found in syslog - try dmesg | tail or so
The filesystem does not have to be tmpfs. Works for ext2 as well like this:
# dd if=/dev/zero of=ext2fs count=2048 # mkfs.ext2 ./ext2fs # umount foo # mount -o loop ext2fs foo # mount --move foo bar mount: wrong fs type, bad option, bad superblock on /var/tmp/foo, missing codepage or helper program, or other error In some cases useful info is found in syslog - try dmesg | tail or so
Similar information can be found in this old bug which was a sandbox problem.
https://bugzilla.redhat.com/show_bug.cgi?id=838447
So it seems that this is related to pam_namespace, sessions and polyinstantiated directories. Can't say I've got my head around this yet, but I can make the mount --move work:
On 20 May 2013 17:01, Norman Gaywood ngaywood@une.edu.au wrote:
# cd /var/tmp/ # mkdir -p foo bar # mount -t tmpfs tmpfs foo
mount --make-runbindable /
# mount --move foo bar
Homework now is to understand "man pam_namespace", http://lwn.net/Articles/159077 and http://lwn.net/Articles/159092
kernel@lists.fedoraproject.org