Mount fs from /etc/fstab.overlay only if overlayfs supported

This commit is contained in:
Calin Crisan 2019-12-13 22:19:33 +02:00
parent c97c991cb2
commit 4aa87f28e0
4 changed files with 3 additions and 1 deletions

View File

@ -1,4 +1,3 @@
# <file system> <mount pt> <type> <options> <dump> <pass>
/dev/mmcblk0p1 /boot vfat ro,defaults 0 0
/dev/mmcblk0p3 /data ext4 defaults,noatime 0 0
overlay /usr overlay lowerdir=/usr,upperdir=/data/usr,workdir=/data/.overlay 0 0

View File

@ -0,0 +1,2 @@
# <file system> <mount pt> <type> <options> <dump> <pass>
overlay /usr overlay lowerdir=/usr,upperdir=/data/usr,workdir=/data/.overlay-usr 0 0

View File

@ -6,6 +6,7 @@ mount_fs() {
msg_begin "Mounting filesystems"
/bin/mount -T /etc/fstab.disk -a &&
/bin/mount -T /etc/fstab.extra -a &&
if grep -qw overlay /proc/filesystems; then /bin/mount -T /data/etc/fstab.overlay -a; fi &&
if [[ -r /data/etc/fstab.user ]]; then /bin/mount -T /data/etc/fstab.user -a; fi
test $? == 0 && msg_done || msg_fail