dCore Import Debian Packages to Mountable SCE extensions > dCore x86_64
Unable to umount bind-mount
(1/1)
sm8ps:
In '/opt/bootlocal.sh', I add the following to '/etc/fstab' and create the directory '/mnt/.crypt/'.
--- Code: ---/dev/sda9 /mnt/.crypt ext4 noauto,users,exec 0 0
/mnt/.crypt/crypt /home/tc/crypt ext4 noauto,users,exec,bind 0 0
--- End code ---
Mounting either one as regular user does work fine; however, unmounting the bind-mounted directory '/home/tc/crypt/' fails with "Operation not permitted.". The order of unmounting (device or the bind-mount) does not matter. Unmounting with "sudo" works fine.
The only reference I have found to anything similar was from 2013 in the Tinycore forum. Something about the group permission of '/etc/busybox.conf', though in my case they are fine as stated there.
--- Code: ----rw------- 1 root root 140 Jun 15 2015 /etc/busybox.conf
--- End code ---
Anybody got any ideas? I need the mount points in scripts where I using sudo has proven cumbersome as far as I recall.
sm8ps:
BTW, this happens on dCore-bionic:2018.08.10.22.24 which makes me realize that I am on the wrong forum. Sorry! However, I suspect this is not particular to this specific release. Can anybody verify on dCore-bionic64 for example?
Here is the relevant part of '/etc/mtab' with all mounts on the device in question. I have also mounted '/mnt/sda9' as prepared in '/etc/fstab' by TC at boot time.
--- Code: ---/dev/sda9 /mnt/sda9 ext4 rw,nosuid,nodev,relatime,data=ordered 0 0
/dev/sda9 /mnt/.crypt ext4 rw,nosuid,nodev,relatime,data=ordered 0 0
/dev/sda9 /home/tc/crypt ext4 rw,nosuid,nodev,relatime,data=ordered 0 0
--- End code ---
This is what happens either what order I try:
--- Code: ---$ umount /home/tc/crypt
umount: /home/tc/crypt: umount failed: Operation not permitted.
$ umount /mnt/sda9
$ umount /home/tc/crypt
umount: /home/tc/crypt: umount failed: Operation not permitted.
$ umount /mnt/.crypt
$ umount /home/tc/crypt
umount: /home/tc/crypt: umount failed: Operation not permitted.
--- End code ---
The final state of '/etc/mtab' is
--- Code: ---/dev/sda9 /home/tc/crypt ext4 rw,nosuid,nodev,relatime,data=ordered 0 0
--- End code ---
The device sda9 contains an Ext4 filesystem with encryption enabled but not decrypted in all these steps. So I think that does not play a role here. I shall double-check later, though.
sm8ps:
Puzzle solved! It was '/bin/umount' that did not play according to the rules. Somehow that must have been loaded by some extension and overruled Busybox umount. Using '/bb/umount' works as expected.
Jason W:
Hi sm8ps. Do you see the same behavior when using standard Core in regards to the Busybox mount/umount and the mount/umount from util-linux.tcz?
sm8ps:
I do not have any TinyCore installation to compare to, sorry. I am a strict dCore follower. :)
Navigation
[0] Message Index
Go to full version