Return to rc CVS log | Up to [ELWIX - Embedded LightWeight unIX -] / elwix / config / etc / rootfs |
1.1 ! misho 1: #!/bin/sh ! 2: # ! 3: # Boot startup script for ELWIX RootFS ... ! 4: # ! 5: # $Id: rc,v 1.3.2.16 2010/08/14 23:14:15 misho Exp $ ! 6: ! 7: stty status '^T' ! 8: ! 9: trap : 2 ! 10: trap : 3 ! 11: trap : 18 ! 12: ! 13: HOME=/root ! 14: PATH=/bin:/sbin:/usr/bin:/usr/sbin:/usr/pkg/bin:/usr/pkg/sbin:/usr/local/bin:/usr/local/sbin ! 15: TERM=xterm ! 16: BLOCKSIZE=1k ! 17: EDITOR=vi ! 18: PAGER=less ! 19: export HOME PATH TERM BLOCKSIZE EDITOR PAGER ! 20: ! 21: umask 022 ! 22: ! 23: failed_sysvol() ! 24: { ! 25: echo " RootFS: Failed $1 ELWIX system ... Go to emergency shell !!!" ! 26: ! 27: exit 127 ! 28: } ! 29: ! 30: boot_elwix() ! 31: { ! 32: echo " RootFS: Load ELWIX system firmware" ! 33: if ! test -r /elwix/elwix-firmware.sys; then ! 34: failed_sysvol "not found" ! 35: fi ! 36: ! 37: mdconfig -a -t vnode -u 1 -f /elwix/elwix-firmware.sys; ! 38: mount -r /dev/md1.uzip /usr; ! 39: sleep 2 ! 40: } ! 41: ! 42: # ! 43: ## main() ! 44: # ! 45: ! 46: echo "ELWIX>>> Firmware RootFS boot stage ..." ! 47: echo " RootFS: Mount ELWIX system volume" ! 48: fsck -q -y 1>/dev/null 2>&1 && mount -a || fsck -y 1>/dev/null 2>&1 && mount -a || \ ! 49: fsck -f -y 1>/dev/null 2>&1 && mount -a || failed_sysvol mount ! 50: ! 51: boot_elwix ! 52: ! 53: /etc/rc.init