168 lines
5.5 KiB
Groff
168 lines
5.5 KiB
Groff
.\" $NetBSD: bioctl.8,v 1.21 2014/09/30 08:20:29 wiz Exp $
|
|
.\" $OpenBSD: bioctl.8,v 1.43 2007/03/20 06:12:11 jmc Exp $
|
|
.\"
|
|
.\" Copyright (c) 2007, 2008 Juan Romero Pardines
|
|
.\" Copyright (c) 2004, 2005 Marco Peereboom
|
|
.\"
|
|
.\" 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 AUTHORS 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 AUTHORS 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 March 16, 2008
|
|
.Dt BIOCTL 8
|
|
.Os
|
|
.Sh NAME
|
|
.Nm bioctl
|
|
.Nd RAID management interface
|
|
.Sh SYNOPSIS
|
|
.Nm bioctl
|
|
.Ar device
|
|
.Ar command
|
|
.Op Ar arg Op ...
|
|
.Sh DESCRIPTION
|
|
RAID device drivers which support management functionality can
|
|
register their services with the
|
|
.Xr bio 4
|
|
driver.
|
|
.Nm bioctl
|
|
then can be used to manage the RAID controller's properties.
|
|
.Sh COMMANDS
|
|
The following commands are supported:
|
|
.Bl -tag -width XXstrategyXXnameXX
|
|
.It Ic show Op Ar disks | volumes
|
|
Without any argument by default
|
|
.Nm
|
|
will show information about all volumes and the logical disks used
|
|
on them.
|
|
If
|
|
.Ar disks
|
|
is specified, only information about physical disks will be shown.
|
|
If
|
|
.Ar volumes
|
|
is specified, only information about the volumes will be shown.
|
|
.It Ic alarm Op Ar disable | enable | silence | test
|
|
Control the RAID card's alarm functionality, if supported.
|
|
By default if no argument is specified, its current state will be
|
|
shown.
|
|
Optionally the
|
|
.Ar disable ,
|
|
.Ar enable ,
|
|
.Ar silence ,
|
|
or
|
|
.Ar test
|
|
arguments may be specified to enable, disable, silence, or test
|
|
the RAID card's alarm.
|
|
.It Ic blink Ar start channel:target.lun | stop channel:target.lun
|
|
Instruct the device at
|
|
.Ar channel:target.lun
|
|
to start or cease blinking, if there's
|
|
.Xr ses 4
|
|
support in the enclosure.
|
|
.It Ic hotspare Ar add channel:target.lun | remove channel:target.lun
|
|
Create or remove a hot-spare drive at location
|
|
.Ar channel:target.lun .
|
|
.It Ic passthru Ar add DISKID channel:target.lun | remove Ar channel:target.lun
|
|
Create or remove a
|
|
.Ar pass-through
|
|
device.
|
|
The
|
|
.Ar DISKID
|
|
argument specifies the disk that will be used for the new device, and
|
|
it will be created at the location
|
|
.Ar channel:target.lun .
|
|
.Em NOTE :
|
|
Removing a pass-through device that has a mounted filesystem will
|
|
lead to undefined behaviour.
|
|
.It Ic check Ar start VOLID | stop VOLID
|
|
Start or stop consistency volume check in the volume with index
|
|
.Ar VOLID .
|
|
.Em NOTE :
|
|
Not many RAID controllers support this feature.
|
|
.It Ic create volume Ar VOLID DISKIDs Oo Ar SIZE Oc Ar STRIPE RAID_LEVEL channel:target.lun
|
|
Create a volume at index
|
|
.Ar VOLID .
|
|
The
|
|
.Ar DISKIDs
|
|
argument will specify the first and last disk, i.e.:
|
|
.Em 0-3
|
|
will use the disks 0, 1, 2, and 3.
|
|
The
|
|
.Ar SIZE
|
|
argument is optional and may be specified if not all available disk
|
|
space is wanted (also dependent of the
|
|
.Ar RAID_LEVEL ) .
|
|
The volume will have a stripe size defined in the
|
|
.Ar STRIPE
|
|
argument and it will be located at
|
|
.Ar channel:target.lun .
|
|
.It Ic remove volume Ar VOLID channel:target.lun
|
|
Remove a volume at index
|
|
.Ar VOLID
|
|
and located at
|
|
.Ar channel:target.lun .
|
|
.Em NOTE :
|
|
Removing a RAID volume that has a mounted filesystem will lead to
|
|
undefined behaviour.
|
|
.El
|
|
.Sh EXAMPLES
|
|
The following command, executed from the command line, shows the
|
|
status of the volumes and its logical disks on the RAID controller:
|
|
.Bd -literal
|
|
$ bioctl arcmsr0 show
|
|
Volume Status Size Device/Label RAID Level Stripe
|
|
=================================================================
|
|
0 Building 468G sd0 ARC-1210-VOL#00 RAID 6 128KB 0% done
|
|
0:0 Online 234G 0:0.0 noencl \*[Lt]WDC WD2500YS-01SHB1 20.06C06\*[Gt]
|
|
0:1 Online 234G 0:1.0 noencl \*[Lt]WDC WD2500YS-01SHB1 20.06C06\*[Gt]
|
|
0:2 Online 234G 0:2.0 noencl \*[Lt]WDC WD2500YS-01SHB1 20.06C06\*[Gt]
|
|
0:3 Online 234G 0:3.0 noencl \*[Lt]WDC WD2500YS-01SHB1 20.06C06\*[Gt]
|
|
.Ed
|
|
.Pp
|
|
To create a RAID 5 volume on the SCSI 0:15.0 location on the disks
|
|
0, 1, 2, and 3, with stripe size of 64Kb on the first volume ID,
|
|
using all available free space on the disks:
|
|
.Pp
|
|
.Dl $ bioctl arcmsr0 create volume 0 0-3 64 5 0:15.0
|
|
.Pp
|
|
To remove the volume 0 previously created at the SCSI 0:15.0 location:
|
|
.Pp
|
|
.Dl $ bioctl arcmsr0 remove volume 0 0:15.0
|
|
.Sh SEE ALSO
|
|
.Xr arcmsr 4 ,
|
|
.Xr bio 4 ,
|
|
.Xr cac 4 ,
|
|
.Xr ciss 4 ,
|
|
.Xr mfi 4 ,
|
|
.Xr mpt 4
|
|
.Sh HISTORY
|
|
The
|
|
.Nm
|
|
command first appeared in
|
|
.Ox 3.8 ,
|
|
it was rewritten for
|
|
.Nx 5.0 .
|
|
.Sh AUTHORS
|
|
The
|
|
.Nm
|
|
interface was written by
|
|
.An Marco Peereboom Aq Mt marco@openbsd.org
|
|
and was rewritten with multiple features by
|
|
.An Juan Romero Pardines Aq Mt xtraeme@NetBSD.org .
|