Index: etc/defaults/rc.conf =================================================================== RCS file: /private/FreeBSD/src/etc/defaults/rc.conf,v retrieving revision 1.212.2.3 diff -u -p -r1.212.2.3 rc.conf --- etc/defaults/rc.conf 14 Oct 2004 04:36:15 -0000 1.212.2.3 +++ etc/defaults/rc.conf 16 Oct 2004 06:49:20 -0000 @@ -470,6 +470,7 @@ virecover_enable="YES" # Perform houseke ugidfw_enable="NO" # Load mac_bsdextended(4) rules on boot bsdextended_script="/etc/rc.bsdextended" # Default mac_bsdextended(4) # ruleset file. +swapoff="NO" # Remove swap partitions upon shutdown ############################################################## ### Jail Configuration ####################################### Index: etc/rc.d/swap1 =================================================================== RCS file: /private/FreeBSD/src/etc/rc.d/swap1,v retrieving revision 1.6.2.2 diff -u -p -r1.6.2.2 swap1 --- etc/rc.d/swap1 10 Oct 2004 09:50:54 -0000 1.6.2.2 +++ etc/rc.d/swap1 16 Oct 2004 06:47:01 -0000 @@ -11,6 +11,7 @@ . /etc/rc.subr name="swap1" +stop_precmd='checkyesno swapoff || [ -n "$rc_force" ]' start_cmd='swapon -a' stop_cmd='swapoff -a' Index: sbin/geom/class/mirror/gmirror.8 =================================================================== RCS file: /private/FreeBSD/src/sbin/geom/class/mirror/gmirror.8,v retrieving revision 1.4.2.2 diff -u -p -r1.4.2.2 gmirror.8 --- sbin/geom/class/mirror/gmirror.8 28 Sep 2004 18:14:29 -0000 1.4.2.2 +++ sbin/geom/class/mirror/gmirror.8 16 Oct 2004 06:52:59 -0000 @@ -273,6 +273,17 @@ gmirror deactivate data da1 dd if=/dev/da1 of=/backup/data.img bs=1m gmirror activate data da1 .Ed +.Sh NOTES +If you are using swap-on-mirror configuration be sure to put: +.Bd -literal -offset indent +swapoff="YES" +.Ed +.Pp +into your +.Pa /etc/rc.conf +and use +.Xr shutdown 8 +command to reboot/shutdown your system. .Sh DIAGNOSTICS Exit status is 0 on success, and 1 if the command fails. .Sh SEE ALSO Index: share/man/man5/rc.conf.5 =================================================================== RCS file: /private/FreeBSD/src/share/man/man5/rc.conf.5,v retrieving revision 1.221.2.3 diff -u -p -r1.221.2.3 rc.conf.5 --- share/man/man5/rc.conf.5 14 Oct 2004 04:36:15 -0000 1.221.2.3 +++ share/man/man5/rc.conf.5 16 Oct 2004 07:03:47 -0000 @@ -2961,6 +2961,11 @@ ruleset file. The default .Xr mac_bsdextended 4 ruleset file to load. +.It Va swapoff +.Pq Vt bool +Set to +.Dq Li YES +to remove swap partitions upon shutdown. .It Va ramdisk_units .Pq Vt str A list of one or more ramdisk units to configure with