NetBSD/usr.sbin/fssconfig/fssconfig.8

164 lines
3.8 KiB
Groff
Raw Normal View History

.\" $NetBSD: fssconfig.8,v 1.8 2012/06/11 15:25:14 hannken Exp $ */
.\"
.\"
.\" Copyright (c) 2003 The NetBSD Foundation, Inc.
.\" All rights reserved.
.\"
.\" This code is derived from software contributed to The NetBSD Foundation
.\" by Juergen Hannken-Illjes.
.\"
.\" Redistribution and use in source and binary forms, with or without
.\" modification, are permitted provided that the following conditions
.\" are met:
.\" 1. Redistributions of source code must retain the above copyright
.\" notice, this list of conditions and the following disclaimer.
.\" 2. Redistributions in binary form must reproduce the above copyright
.\" notice, this list of conditions and the following disclaimer in the
.\" documentation and/or other materials provided with the distribution.
.\"
.\" THIS SOFTWARE IS PROVIDED BY THE NETBSD FOUNDATION, INC. AND CONTRIBUTORS
.\" ``AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED
.\" TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
.\" PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE FOUNDATION OR CONTRIBUTORS
.\" BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR
.\" CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF
.\" SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS
.\" INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN
.\" CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
.\" ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
.\" POSSIBILITY OF SUCH DAMAGE.
.\"
.Dd June 11, 2012
.Dt FSSCONFIG 8
.Os
.Sh NAME
.Nm fssconfig
.Nd configure file system snapshot devices
.Sh SYNOPSIS
.Nm
.Op Fl cxv
.Ar device
.Ar path
.Ar backup
.Op Ar cluster Op Ar size
.Nm
.Fl u Op Fl v
.Ar device
.Nm
.Fl l Op Fl v
.Op Ar device
.Sh DESCRIPTION
The
.Nm
command configures file system snapshot pseudo disk devices.
It will associate the file system snapshot disk
.Ar device
with a snapshot of
.Ar path
allowing the latter to be accessed as though it were a disk.
2005-02-01 01:08:55 +03:00
.Pp
If
.Ar backup
resides on the snapshotted file system a persistent snapshot will be created.
This snapshot is active until
.Ar backup
is unlinked.
This snapshot mode is only supported for ffs files systems.
.Pp
Otherwise data written through the
.Ar path
will be saved in
2005-02-01 01:08:55 +03:00
.Ar backup .
If
.Ar backup
is a regular file, it will be created with length
.Ar size .
Default size is the size of
.Ar path .
Data is saved to
.Ar backup
in units of
.Ar cluster
bytes.
.Pp
Options indicate an action to be performed:
.Bl -tag -width 3n
.It Fl c
Configures the device.
If successful, references to
.Ar device
will access the contents of
.Ar path
at the time the snapshot was taken.
If
.Ar backup
is a directory, a temporary file will be created in this directory.
This file will be unlinked on exit.
.It Fl l
List the snapshot devices and indicate which ones are in use.
If a specific
.Ar device
is given, then only that will be described.
.It Fl u
Unconfigures the
.Ar device .
.It Fl v
Be more verbose listing the snapshot devices.
.It Fl x
Unlink
.Ar backup
after the
.Ar device
is configured.
.El
.Pp
If no action option is given,
.Fl c
is assumed.
.Sh FILES
.Bl -tag -width /etc/disktab -compact
.It Pa /dev/rfss?
.It Pa /dev/fss?
.El
.Sh EXAMPLES
.Dl fssconfig fss0 /usr /tmp/back
.Pp
Configures the snapshot device
.Pa fss0
for a snapshot of the
.Pa /usr
file system.
Data written through
.Pa /usr
will be backed up in
.Pa /tmp/back .
.Pp
.Dl fssconfig fss1 / /dev/rsd0e 8192
.Pp
Configures the snapshot device
.Pa fss1
for a snapshot of the
.Pa /
file system.
Data written through
.Pa /
will be backed up in
.Pa /dev/rsd0e .
The backup will take place in units of 8192 bytes.
.Pp
.Dl fssconfig -u fss0
.Pp
Unconfigures the
.Pa fss0
device.
.Sh SEE ALSO
.Xr opendisk 3 ,
.Xr fss 4 ,
.Xr mount 8 ,
.Xr umount 8
.Sh HISTORY
The
.Nm
command appeared in
.Nx 2.0 .