freebsd-dev/release/picobsd/mfs_tree/etc/rc
Luigi Rizzo e5b68d5513 The magic for autodetecting the boot media does not work anymore
on STABLE or CURRENT.  Put the explicit name for the floppy.
2001-01-27 03:23:44 +00:00

32 lines
671 B
Bash

#!/bin/sh
# $FreeBSD$
# WARNING !!! We overwrite this file during execution with a new rc file.
# Awful things happen if this file's size is > 1024B
stty status '^T'
trap : 2
trap : 3
HOME=/; export HOME
PATH=/sbin:/bin:/usr/sbin:/usr/bin:/usr/local/sbin
export PATH
trap "echo 'Reboot interrupted'; exit 1" 3
### Special setup for one floppy PICOBSD ###
dev="/dev/fd0c"
echo "Reading /etc from ${dev}..."
mount -o rdonly ${dev} /mnt
cd /mnt/etc ; cp -Rp . /etc/
cp -Rp /mnt/root /
cd /etc
#rm files to stop overwrite warning
rm rc login.conf
gzip -d *.gz
pwd_mkdb -p ./master.passwd
umount /mnt
echo "Ok. (Now you can remove ${dev} if you like)"
echo ""
. rc
exit 0