Use machdep.guessed_bootdev to guess the boot device.
This commit is contained in:
parent
fd43aa1c2c
commit
45b51b4564
@ -5,8 +5,8 @@
|
|||||||
thefiles=$*
|
thefiles=$*
|
||||||
[ -z "$thefiles" ] && \
|
[ -z "$thefiles" ] && \
|
||||||
thefiles="/etc/rc.conf /etc/rc.firewall /etc/master.passwd"
|
thefiles="/etc/rc.conf /etc/rc.firewall /etc/master.passwd"
|
||||||
dev=`sysctl -n kern.bootdevname`
|
dev=`sysctl -n machdep.guessed_bootdev`
|
||||||
[ -z ${dev} ] && dev="/dev/fd0"
|
[ -c "${dev}" ] || dev="/dev/fd0"
|
||||||
mount ${dev} /mnt
|
mount ${dev} /mnt
|
||||||
if [ "$?" != "0" ] ; then
|
if [ "$?" != "0" ] ; then
|
||||||
echo ""
|
echo ""
|
||||||
|
Loading…
x
Reference in New Issue
Block a user