inital commit of 20040316
[openwrt/svn-archive/archive.git] / root / etc / preinit
1 #!/bin/sh
2 mount none /proc -t proc
3 if /sbin/resetmon ; then
4 mtd unlock mtd4
5 mount -t jffs2 /dev/mtdblock/4 /jffs
6 pivot_root /jffs /jffs/rom
7 mount none /dev -t devfs
8 mount none /proc -t proc
9 umount rom/proc
10 umount rom/dev
11 else
12 FAILSAFE=true
13 export FAILSAFE
14 fi
15 mount none /tmp -t ramfs
16 exec /sbin/init