OpenWrt Forum Archive

Topic: ExtRoot SD card mounts as /tmp/overlay-disabled or nothing at all

The content of this topic has been archived on 1 Apr 2018. There are no obvious gaps in this topic, but there may still be some posts missing at the end.

Having just installed an SD card in my whr-g54s:

I followed this guide:

https://forum.openwrt.org/viewtopic.php?pid=107591

When I boot I either get my card mounting on /tmp/overlay-disabled or not mounting at all when I remove target from /etc/config/fstab.


My fstab reads:


config 'global' 'automount'
    option 'from_fstab' '1'
    option 'anon_mount' '1'

config 'global' 'autoswap'
    option 'from_fstab' '1'
    option 'anon_swap' '0'

config 'mount'
    # option 'target' '/'
    option 'device' '/dev/mmcblk0p1'
    option 'fstype' 'ext3'
    option 'enabled' '1'
    option 'enabled_fsck' '0'
    option 'options' 'rw,noatime'
    option 'is_rootfs' '1'

config 'swap'
    option 'device' '/dev/sda2'
    option 'enabled' '0'


I've deleted the md5sums and copied root to the SD card. What is going on here? Do I have to build a custom image. I thought that wasn't required with latest SVN. What am I missing?

cp /.extroot.md5sum /tmp/overlay-disabled/etc/extroot.md5sum

I tried this. Also just deleted root and copied just /overlay to root of sd card with md5 sums. I'll try deleting and copying again on full root fs.

The only condition to mount an external storage to /tmp/overlay-disabled is a md5sum file mismatch...
P.S. Just copy/paste the command string above to your console. md5sum filename at /etc should be without dot!

(Last edited by regressor on 8 Mar 2011, 07:58)

I'll try doing it from scratch. I've gotten it to mount on /overlay but the flash stays mounted too. Sometimes it just mounts on fall back mount point. Maybe I've changed something.

With a freshly wiped router its still not working. I had to set fstab init to 20 and gpip_mmc init.d/rc.d to 15 to get it to automount at first.
Then:

root@OpenWrt:~# cat /etc/extroot.md5sum
a5e4a17a921f6d74b08ab033ef37d2b1

root@OpenWrt:~# cat /.extroot.md5sum
a5e4a17a921f6d74b08ab033ef37d2b1

root@OpenWrt:~# cat /overlay/etc/extroot.md5sum
a5e4a17a921f6d74b08ab033ef37d2b1

root@OpenWrt:~# cat /tmp/overlay-disabled/etc/extroot.md5sum
a5e4a17a921f6d74b08ab033ef37d2b1

Then:

Filesystem                Size      Used Available Use% Mounted on
/dev/root                 1.5M      1.5M         0 100% /rom
tmpfs                    30.4M     44.0K     30.4M   0% /tmp
tmpfs                   512.0K         0    512.0K   0% /dev
/dev/mtdblock3            1.4M    828.0K    580.0K  59% /overlay
mini_fo:/overlay          1.5M      1.5M         0 100% /
/dev/mmcblk0p1          955.1M     24.7M    881.9M   3% /tmp/overlay-disabled


Any way to view more logs? logread and dmesg show nothing about extroot.

I started from scratch again and now it only mounts /mnt/mmc but the md5 sums are created.

If I do a /etc/init.d/fstab restart /tmp/overlay-disabled mounts again.

I had this problem and the cp command in the second post solved it for me.

Something is wrong in pre-init. Your solution would work otherwise.  I don't think it can pivot root after init is over.

regressor wrote:

cp /.extroot.md5sum /tmp/overlay-disabled/etc/extroot.md5sum

thanks, it really helped me!

The discussion might have continued from here.