--- elwix/config/etc/default/rc.init 2017/02/13 16:52:47 1.6 +++ elwix/config/etc/default/rc.init 2021/03/11 13:59:50 1.7 @@ -2,7 +2,7 @@ # # Boot startup script for elwix :) # -# $Id: rc.init,v 1.6 2017/02/13 16:52:47 misho Exp $ +# $Id: rc.init,v 1.7 2021/03/11 13:59:50 misho Exp $ stty status '^T' @@ -18,6 +18,7 @@ EDITOR=vi PAGER=less export HOME PATH TERM BLOCKSIZE EDITOR PAGER +CFDIR="/elwix/cf" SYSPKGDIR="/var/frm" BOOTLOG="/var/run/elwix.boot" @@ -30,10 +31,11 @@ umask 022 boot() { echo "Loading ELWIX configz ..." + cd /elwix/altroot pax -rw -pe var / chmod 1777 /var/tmp - mount -tunionfs -onoatime /var/db /elwix/etc + mount -ttmpfs tmpfs /var/db/pkg cd / } @@ -59,7 +61,7 @@ passwd() local() { echo "Configurate localhost ..." | tee -a $BOOTLOG - ifconfig lo0 127.0.0.1 | tee -a $BOOTLOG 1>/dev/null 2>&1 + ifconfig lo0 inet 127.0.0.1 netmask 255.0.0.0 | tee -a $BOOTLOG 1>/dev/null 2>&1 hostname `cat /etc/myname` } @@ -96,7 +98,7 @@ syspkg() echo "Mounting firmware system packages:" | tee -a $BOOTLOG # Raw images - for i in /elwix/cf/*-pkg.frm; do + for i in ${CFDIR}/*-pkg.frm; do if [ -r $i ]; then MDDEV=$(mdconfig -a -t vnode -f $i); install -d $SYSPKGDIR/$MDDEV; @@ -118,7 +120,7 @@ syspkg() fi done # UZIP images - for i in /elwix/cf/*-pkg.frz; do + for i in ${CFDIR}/*-pkg.frz; do if [ -r $i ]; then MDDEV=$(mdconfig -a -t vnode -f $i); install -d $SYSPKGDIR/$MDDEV; @@ -145,7 +147,7 @@ service() { echo "Starting distribution static services:" | tee -a $BOOTLOG for i in /etc/rc.d/*.run; do - if [ -x $i ]; then + if [ -x "$i" ]; then $i fi done @@ -155,7 +157,7 @@ service() echo "Starting distribution services:" | tee -a $BOOTLOG for i in /etc/rc.S/*.run; do - if [ -x $i ]; then + if [ -x "$i" ]; then $i fi done