From 94f8c783520e9f83b949ce85c58847c2fd6506bb Mon Sep 17 00:00:00 2001 From: dillon Date: Tue, 21 Sep 1999 01:03:11 +0000 Subject: Bring documentation up to date, add a few more vnconfig examples. --- usr.sbin/vnconfig/vnconfig.8 | 28 ++++++++++++++++++++++++++++ 1 file changed, 28 insertions(+) (limited to 'usr.sbin/vnconfig') diff --git a/usr.sbin/vnconfig/vnconfig.8 b/usr.sbin/vnconfig/vnconfig.8 index 7cfe5170..9b2e3c8 100644 --- a/usr.sbin/vnconfig/vnconfig.8 +++ b/usr.sbin/vnconfig/vnconfig.8 @@ -225,6 +225,34 @@ Unmounts (disables) .Pp Configures and enables all devices specified in .Pa /etc/vntab . +.Pp +.Dl vnconfig -s labels -c vn0 somebackingfile +.Dl disklabel -r -w vn0 auto +.Dl disklabel -e vn0 +.Pp +Is an example of how to configure a file-backed VN disk with a disk label +and to initialize and then edit the label. Once you create the label, you +can partition your VN disk and, for example, create a filesystem on one of +the partitions. If you are using a file as backing store, it may be possible +to recover your VN disk after a crash by vnconfig'ing the same file again +and using the VN configuration already stored in the file rather then +relabeling and recreating the filesystem. It is even possible to fsck the +VN partitions that previously contained filesystems. +.Pp +.Dl vnconfig -e -s labels,reserve -S 400m vn0 +.Dl disklabel -r -w vn1 auto +.Dl newfs /dev/rvn1c +.Dl mount /dev/vn1c /usr/obj +.Pp +Is an example of a swap-backed VN disk configuration. This example assumes +that you have at least 400 megabytes of swap free (and hopefully much more). +The swap space is pre-reserved in order to maintain maximum performance. +We then label the disk, newfs it, and mount it as /usr/obj. Swap-backed VN +devices are recoverable after a crash if you (A) use the reserve flag, and if +(B) the same swap is reserved as was the last time, meaning that such +vnconfig's would have to be run in your rc.local. In general, though, you +only use swap-backed VN devices to hold information you don't mind losing +on every reboot. .Sh SEE ALSO .Xr mount 2 , .Xr swapon 2 , -- cgit v1.1