From owner-freebsd-current Wed Dec 11 11:12:35 2002 Delivered-To: freebsd-current@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id A59B837B401 for ; Wed, 11 Dec 2002 11:12:33 -0800 (PST) Received: from i171026.ap.plala.or.jp (i171026.ap.plala.or.jp [218.47.171.26]) by mx1.FreeBSD.org (Postfix) with ESMTP id 4993343EA9 for ; Wed, 11 Dec 2002 11:12:33 -0800 (PST) (envelope-from sf@FreeBSD.org) Date: Thu, 12 Dec 2002 04:12:31 +0900 Message-ID: <86isy0nzds.wl@gray.plala.or.jp> From: FUJISHIMA Satsuki To: current@FreeBSD.org Subject: ${swapfile} in rc.conf User-Agent: Wanderlust/2.11.0 (Wonderwall) SEMI/1.14.4 (Hosorogi) FLIM/1.14.4 (=?ISO-8859-4?Q?Kashiharajing=FE-mae?=) APEL/10.4 Emacs/20.7 (i386--freebsd) MULE/4.1 (AOI) MIME-Version: 1.0 (generated by SEMI 1.14.4 - "Hosorogi") Content-Type: text/plain; charset=US-ASCII Sender: owner-freebsd-current@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG 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