Modify

Opened 5 years ago

Last modified 4 years ago

#12851 new defect

Unable to use extroot on ar71xx (WNDR3700v1)

Reported by: openwrt@… Owned by: developers
Priority: normal Milestone: Barrier Breaker 14.07
Component: base system Version: Trunk
Keywords: extroot Cc:

Description

I'm having the same problem as someone else in the forum: https://forum.openwrt.org/viewtopic.php?pid=189402

We're both using a USB storage device correctly mounted under /overlay. /dev/mtdblock4 is not being unmounted first, so opkg installations and other work end up written to /dev/mtdblock4 instead of the overlay device.

r35240 is installed. The other forum user has r33821, and I was testing with another trunk build in between before I tried updating to the latest trunk build to fix the problem.

/dev/fstab and /etc/config/fstab both appear correct:

config mount

option device '/dev/sda1'
option fstype 'ext4'
option target '/overlay'
option enabled '1'
option options 'rw,data=ordered,errors=remount-ro,sync,noatime,barrier=1'
option enabled_fsck '0'
option is_rootfs '1'

mount produces:

rootfs on / type rootfs (rw)
/dev/root on /rom type squashfs (ro,relatime)
proc on /proc type proc (rw,noatime)
sysfs on /sys type sysfs (rw,noatime)
tmpfs on /tmp type tmpfs (rw,nosuid,nodev,noatime)
tmpfs on /dev type tmpfs (rw,noatime,size=512k,mode=755)
devpts on /dev/pts type devpts (rw,noatime,mode=600)
/dev/mtdblock4 on /overlay type jffs2 (rw,noatime)
overlayfs:/overlay on / type overlayfs (rw,noatime,lowerdir=/,upperdir=/overlay)
debugfs on /sys/kernel/debug type debugfs (rw,noatime)
/dev/sda1 on /overlay type ext4 (rw,sync,noatime,errors=remount-ro,data=ordered)

df -h produces:

Filesystem Size Used Available Use% Mounted on
rootfs 4.9M 1.3M 3.7M 26% /
/dev/root 1.5M 1.5M 0 100% /rom
tmpfs 30.0M 88.0K 29.9M 0% /tmp
tmpfs 512.0K 0 512.0K 0% /dev
/dev/mtdblock4 3.7G 74.0M 3.6G 2% /overlay
overlayfs:/overlay 4.9M 1.3M 3.7M 26% /
/dev/sda1 3.7G 74.0M 3.6G 2% /overlay

Attachments (0)

Change History (2)

comment:1 Changed 4 years ago by Chris H.

I didn't quite had the same symptoms, but mounting a USB-HDD to /overlay failed all together on my WNDR3700v1, running the final Attitude Adjustment.

I found out that modifying the extroot_settle_time, fixed it for me.

This variable is found in the file /lib/preinit/00_extroot.conf and standard set to 20 (seconds). I've changed it to 60 seconds, to give my USB-HDD more than enough time to init, spin-up and settle and ever since the Pivot-overlay is running just fine.

root@Homer:/lib/preinit# mount
rootfs on / type rootfs (rw)
/dev/root on /rom type squashfs (ro,relatime)
proc on /proc type proc (rw,noatime)
sysfs on /sys type sysfs (rw,noatime)
tmpfs on /tmp type tmpfs (rw,nosuid,nodev,noatime,size=30852k)
tmpfs on /dev type tmpfs (rw,noatime,size=512k,mode=755)
devpts on /dev/pts type devpts (rw,noatime,mode=600)
/dev/sda2 on /overlay type ext4 (rw,relatime,user_xattr,barrier=1,data=ordered)
overlayfs:/overlay on / type overlayfs (rw,relatime,lowerdir=/,upperdir=/overlay)
debugfs on /sys/kernel/debug type debugfs (rw,relatime)
/dev/sda4 on /mnt/data type ext4 (rw,sync,relatime,user_xattr,barrier=1,data=ordered)
/dev/sda3 on /usr/share/htdocs type ext3 (rw,sync,relatime,user_xattr,barrier=1,nodelalloc,data=ordered)
none on /proc/bus/usb type usbfs (rw,relatime)
root@Homer:/lib/preinit# df -h
Filesystem                Size      Used Available Use% Mounted on
rootfs                    9.3G    280.4M      8.5G   3% /
/dev/root                 2.0M      2.0M         0 100% /rom
tmpfs                    30.1M    656.0K     29.5M   2% /tmp
tmpfs                   512.0K         0    512.0K   0% /dev
/dev/sda2                 9.3G    280.4M      8.5G   3% /overlay
overlayfs:/overlay        9.3G    280.4M      8.5G   3% /
/dev/sda4                61.8G     33.4G     25.3G  57% /mnt/data
/dev/sda3                 1.9G     77.0M      1.7G   4% /usr/share/htdocs

/dev/mtdblock4 no longer mounts I've got access to the full 9.3GB.

Because changing the extroot_settle_time to quite a long timeout fixed it for me, I don't really think this can be considered as a bug. Maybe it should be included as a fix in the wiki, when using a USB-HDD, which takes up more time to settle than a USB-stick.

comment:2 Changed 4 years ago by jow

  • Milestone changed from Attitude Adjustment 12.09 to Barrier Breaker 14.07

Milestone Attitude Adjustment 12.09 deleted

Add Comment

Modify Ticket

Action
as new .
Author


E-mail address and user name can be saved in the Preferences.

 
Note: See TracTickets for help on using tickets.