Browse Source

try to mount secondary filesystems after modules are loaded

Waldemar Brodkorb 14 năm trước cách đây
mục cha
commit
11a26c7947

+ 1 - 1
package/base-files/Makefile

@@ -6,7 +6,7 @@ include $(TOPDIR)/mk/rootfs.mk
 
 PKG_NAME:=		base-files
 PKG_VERSION:=		1.0
-PKG_RELEASE:=		48
+PKG_RELEASE:=		49
 PKG_SECTION:=		base
 PKG_DESCR:=		basic files and scripts
 

+ 4 - 0
package/base-files/src/etc/init.d/boot

@@ -26,4 +26,8 @@ for f in /etc/modules.d/*; do
 done
 # settle down, after module load
 sleep 2
+# any lvm volumes to activate?
+[ -x /usr/sbin/lvm ] && { lvm vgscan; lvm vgchange -ay;}
+# check and mount all filesystems not /
+[ -f /etc/fstab ] && { fsck -p >/dev/null; mount -a; swapon -a;}
 exit 0

+ 3 - 1
package/base-files/src/etc/network/if-pre-up.d/03-bridge

@@ -15,7 +15,9 @@ case "$IF_BRIDGE_PORTS" in
 esac
 
 brctl addbr $IFACE || exit 1
-[[ -n $IF_BRIDGE_FD ]] && brctl setfd $IFACE $IF_BRIDGE_FD
+if [ "$IF_BRIDGE_FD" != "" ]; then
+ brctl setfd $IFACE $IF_BRIDGE_FD
+fi
 
 for IF in $INTERFACES; do
   if ! grep -q $IF /proc/net/dev; then

+ 0 - 1
package/base-files/src/init

@@ -22,5 +22,4 @@ cat /etc/.rnd >/dev/urandom 2>&1
 [ -x /kexecinit ] && { /kexecinit; }
 [ -x /cryptinit ] && { /cryptinit; exec switch_root /mnt "/init";}
 [ -x /sbin/cfgfs ] && { cfgfs setup; mount -o remount,ro /;} || mount -o remount,rw /
-[ -f /etc/fstab ] && { fsck -p >/dev/null; mount -a; swapon -a;}
 exec /sbin/init