Extroot Configuration

Hello,

I recently added an SD card to my Slate AXT, and used it to expand storage for installing plugins etc.

Now there are some issues in the GL.iNet panel, and I’m not sure if that’s something to be worried about:

It looks good in LuCi:




I used these commands to configure it, it’s working fine so far, just want to check I won’t run into any issues down the line:

opkg update
opkg install block-mount kmod-fs-ext4 e2fsprogs
DEVICE="$(sed -n -e "/\s\/overlay\s.*$/s///p" /etc/mtab)"
uci -q delete fstab.rwm
uci set fstab.rwm="mount"
uci set fstab.rwm.device="${DEVICE}"
uci set fstab.rwm.target="/rwm"
uci commit fstab
block info
umount /dev/mmcblk0p1
DEVICE="/dev/mmcblk0p1"
mkfs.ext4 -L extroot ${DEVICE}
eval $(block info ${DEVICE} | grep -o -e "UUID=\S*")
uci -q delete fstab.overlay
uci set fstab.overlay="mount"
uci set fstab.overlay.uuid="${UUID}"
uci set fstab.overlay.target="/overlay"
uci commit fstab
mount ${DEVICE} /mnt
tar -C /overlay -cvf - . | tar -C /mnt -xf -
reboot

If anyone spots something I did wrong here, please let me know. No issues yet, but I thought I’d better check before hand :smile:

1 Like

Thank you for sharing.