Date: Thu, 12 Dec 2002 04:12:31 +0900
From: FUJISHIMA Satsuki <sf@FreeBSD.org>
To: current@FreeBSD.org
Subject: ${swapfile} in rc.conf
Message-ID: <86isy0nzds.wl@gray.plala.or.jp>
index | next in thread | raw e-mail
A keyword ${swapfile} in rc.conf, for adding a file as additional
swap space, does not work regardless of rc_ng=YES or NO. These scripts
test existence of /dev/mdctl, but it does not exist because it will be
created automatically at the first configuration of md device. So the
test would alwaiys fail at coldboot.
Can we omit these test?
--
FUJISHIMA Satsuki
Index: src/etc/rc
===================================================================
RCS file: /home/ncvs/src/etc/rc,v
retrieving revision 1.323
diff -u -r1.323 rc
--- src/etc/rc 26 Nov 2002 17:51:03 -0000 1.323
+++ src/etc/rc 11 Dec 2002 18:52:56 -0000
@@ -465,7 +465,7 @@
[Nn][Oo] | '')
;;
*)
- if [ -w "${swapfile}" -a -c /dev/mdctl ]; then
+ if [ -w "${swapfile}" ]; then
echo "Adding ${swapfile} as additional swap"
mdev=`mdconfig -a -t vnode -f ${swapfile}` && swapon /dev/${mdev}
fi
Index: src/etc/rc.d/addswap
===================================================================
RCS file: /home/ncvs/src/etc/rc.d/addswap,v
retrieving revision 1.2
diff -u -r1.2 addswap
--- src/etc/rc.d/addswap 12 Oct 2002 10:31:31 -0000 1.2
+++ src/etc/rc.d/addswap 11 Dec 2002 18:52:45 -0000
@@ -22,7 +22,7 @@
[Nn][Oo] | '')
;;
*)
- if [ -w "${swapfile}" -a -c /dev/mdctl ]; then
+ if [ -w "${swapfile}" ]; then
echo "Adding ${swapfile} as additional swap"
mdev=`mdconfig -a -t vnode -f ${swapfile}` && swapon /dev/${mdev}
fi
To Unsubscribe: send mail to majordomo@FreeBSD.org
with "unsubscribe freebsd-current" in the body of the message
help
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?86isy0nzds.wl>
