VNCONFIG(8)

NAME
vnconfig - configure and enable vnode disks

SYNOPSIS
vnconfig [-cdeguv] [-s option] [-r option] special_file regular_file [feature]
vnconfig -a [-cdeguv] [-s option] [-r option] [-f config_file]

DESCRIPTION
The vnconfig command configures and enables vnode pseudo disk devices. The first form of the command will associate the special file special_file with the regular file regular_file allowing the latter to be accessed as though it were a disk. Hence a regular file within the filesystem can be used for swapping or can contain a filesystem that is mounted in the name space.

Options indicate an action to be performed:

-a  Read a command file and performs the specified actions for each device/file pair.

-c  Configure the device. If successful, references to special_file will access the contents of regular_file.

-d  Disable (if possible) the specified feature.

-e  Configure the device and enables any feature that was specified. If no feature was specified, -e is the same as -c.

-f config_file
    Use config_file as an alternate config file.

-g  Fiddle global options.

-r flag
    Reset flag. The list of allowed flags and their meanings are:

    labels
        use disk/slice labels.

    follow
        debug flow in the vn(4) driver.

    debug
        debug data in the vn(4) driver.

    io  debug I/O in the vn(4) driver.

    all turn on all flags.

    none
        turn off all flags.

-s flag
    Set flag. The list of allowed flags and their meanings are the same as for the -r option.

-u  Disable and ``unconfigure'' the device.

-v  Print messages to stdout describing actions taken.

If no action option is given, -c is assumed.

The feature argument specifies a feature that can be enabled via the -e option:

swap
    Swapping is enabled on the special file. See swapon(2).

mountro=mount_point
    The special file is mounted read-only on mount_point. See mount(2).

mountrw=mount_point
    The special file is mounted read-write on mount_point. See mount(2).

mount=mount_point
    Same as ``mountrw=''.

A configuration file contains one line per device/file pair in the form:

    	special_file	regular_file	[ feature ]

where fields are seperated by white space. The previously described action options serve to configure, enable, disable or unconfigure all devices in the configuration file.

FILES
/etc/vntab
    default configuration file for -a option.

EXAMPLES

    vnconfig /dev/vn0c /tmp/diskimage

Configures the vnode disk vn0c.

    vnconfig -e /dev/vn0c /var/swapfile swap

Configures vn0c and enables swapping on it.

    vnconfig -d /dev/vn0c myfilesystem mount=/mnt

Unmounts (disables) vn0c.

    vnconfig -ae

Configures and enables all devices specified in /etc/vntab.

SEE ALSO
mount(2), swapon(2), unmount(2), vn(4).