Remove "none" test to be able to manage bind mounts
This impact /var/tmp bind mount. If a device don't have a mount path (none), the `grep` in /etc/mtab will ignore this device.
This commit is contained in:
parent
0bb95412a2
commit
57ca51b307
|
@ -4,7 +4,7 @@
|
||||||
|
|
||||||
if [ "$(id -u)" -eq 0 ]; then
|
if [ "$(id -u)" -eq 0 ]; then
|
||||||
# get the mountpath list from fstab
|
# get the mountpath list from fstab
|
||||||
for mountpath in $(grep -v -E "(^#|none)" /etc/fstab | awk '{print $2}'); do
|
for mountpath in $(grep -v -E "(^#)" /etc/fstab | awk '{print $2}'); do
|
||||||
# ensure "${mountpath}" is already mounted
|
# ensure "${mountpath}" is already mounted
|
||||||
if grep -q " ${mountpath} " /etc/mtab; then
|
if grep -q " ${mountpath} " /etc/mtab; then
|
||||||
mount "${mountpath}" -o remount
|
mount "${mountpath}" -o remount
|
||||||
|
|
Loading…
Reference in New Issue