2011-04-26 02:09:29 +04:00
|
|
|
.\" $NetBSD: bioctl.8,v 1.17 2011/04/25 22:09:29 wiz Exp $
|
2007-05-01 21:18:52 +04:00
|
|
|
.\" $OpenBSD: bioctl.8,v 1.43 2007/03/20 06:12:11 jmc Exp $
|
|
|
|
.\"
|
2008-01-03 02:45:06 +03:00
|
|
|
.\" Copyright (c) 2007, 2008 Juan Romero Pardines
|
2007-05-01 21:18:52 +04:00
|
|
|
.\" 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.
|
|
|
|
.\"
|
2008-03-16 13:01:32 +03:00
|
|
|
.Dd March 16, 2008
|
2007-05-01 21:18:52 +04:00
|
|
|
.Dt BIOCTL 8
|
|
|
|
.Os
|
|
|
|
.Sh NAME
|
|
|
|
.Nm bioctl
|
|
|
|
.Nd RAID management interface
|
|
|
|
.Sh SYNOPSIS
|
|
|
|
.Nm bioctl
|
|
|
|
.Ar device
|
2008-01-03 02:45:06 +03:00
|
|
|
.Ar command
|
|
|
|
.Op Ar arg Op ...
|
2007-05-01 21:18:52 +04:00
|
|
|
.Sh DESCRIPTION
|
|
|
|
RAID device drivers which support management functionality can
|
|
|
|
register their services with the
|
|
|
|
.Xr bio 4
|
|
|
|
driver.
|
|
|
|
.Nm bioctl
|
2008-03-16 14:07:23 +03:00
|
|
|
then can be used to manage the RAID controller's properties.
|
2008-01-03 02:45:06 +03:00
|
|
|
.Sh COMMANDS
|
|
|
|
The following commands are supported:
|
|
|
|
.Bl -tag -width XXstrategyXXnameXX
|
|
|
|
.It Ic show Op Ar disks | volumes
|
2008-03-16 14:07:23 +03:00
|
|
|
Without any argument by default
|
|
|
|
.Nm
|
|
|
|
will show information about all volumes and the logical disks used
|
|
|
|
on them.
|
|
|
|
If
|
2008-01-03 02:45:06 +03:00
|
|
|
.Ar disks
|
2008-03-16 14:07:23 +03:00
|
|
|
is specified, only information about physical disks will be shown.
|
2008-01-03 02:45:06 +03:00
|
|
|
If
|
|
|
|
.Ar volumes
|
2008-03-16 14:07:23 +03:00
|
|
|
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
|
2008-01-03 02:45:06 +03:00
|
|
|
.Ar disable ,
|
2008-03-16 14:07:23 +03:00
|
|
|
.Ar enable ,
|
|
|
|
.Ar silence ,
|
2008-01-03 02:45:06 +03:00
|
|
|
or
|
|
|
|
.Ar test
|
2008-03-16 14:07:23 +03:00
|
|
|
arguments may be specified to enable, disable, silence, or test
|
|
|
|
the RAID card's alarm.
|
2008-03-03 19:10:48 +03:00
|
|
|
.It Ic blink Ar start channel:target.lun | stop channel:target.lun
|
2007-05-01 21:18:52 +04:00
|
|
|
Instruct the device at
|
2008-01-03 02:45:06 +03:00
|
|
|
.Ar channel:target.lun
|
|
|
|
to start or cease blinking, if there's
|
2007-05-01 21:18:52 +04:00
|
|
|
.Xr ses 4
|
|
|
|
support in the enclosure.
|
2008-03-03 19:10:48 +03:00
|
|
|
.It Ic hotspare Ar add channel:target.lun | remove channel:target.lun
|
2008-01-03 02:45:06 +03:00
|
|
|
Create or remove a hot-spare drive at location
|
|
|
|
.Ar channel:target.lun .
|
2008-03-03 19:10:48 +03:00
|
|
|
.It Ic passthru Ar add DISKID channel:target.lun | remove Ar channel:target.lun
|
2008-01-03 02:45:06 +03:00
|
|
|
Create or remove a
|
|
|
|
.Ar pass-through
|
2008-03-16 14:07:23 +03:00
|
|
|
device.
|
|
|
|
The
|
2008-01-03 02:45:06 +03:00
|
|
|
.Ar DISKID
|
|
|
|
argument specifies the disk that will be used for the new device, and
|
2008-03-16 14:07:23 +03:00
|
|
|
it will be created at the location
|
|
|
|
.Ar channel:target.lun .
|
2008-01-03 02:45:06 +03:00
|
|
|
.Em NOTE :
|
2008-03-16 14:07:23 +03:00
|
|
|
Removing a pass-through device that has a mounted filesystem will
|
|
|
|
lead to undefined behaviour.
|
2008-03-03 19:10:48 +03:00
|
|
|
.It Ic check Ar start VOLID | stop VOLID
|
2008-01-03 02:45:06 +03:00
|
|
|
Start or stop consistency volume check in the volume with index
|
|
|
|
.Ar VOLID .
|
|
|
|
.Em NOTE :
|
2008-03-16 14:07:23 +03:00
|
|
|
Not many RAID controllers support this feature.
|
2008-01-03 02:45:06 +03:00
|
|
|
.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
|
2008-03-16 14:07:23 +03:00
|
|
|
argument will specify the first and last disk, i.e.:
|
2008-01-03 02:45:06 +03:00
|
|
|
.Em 0-3
|
2008-03-16 14:07:23 +03:00
|
|
|
will use the disks 0, 1, 2, and 3.
|
|
|
|
The
|
2008-01-03 02:45:06 +03:00
|
|
|
.Ar SIZE
|
2008-03-16 14:07:23 +03:00
|
|
|
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
|
2008-01-03 02:45:06 +03:00
|
|
|
.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 .
|
2008-03-16 14:07:23 +03:00
|
|
|
.Em NOTE :
|
|
|
|
Removing a RAID volume that has a mounted filesystem will lead to
|
2008-01-03 02:45:06 +03:00
|
|
|
undefined behaviour.
|
2007-05-01 21:18:52 +04:00
|
|
|
.El
|
|
|
|
.Sh EXAMPLES
|
2008-03-16 14:07:23 +03:00
|
|
|
The following command, executed from the command line, shows the
|
|
|
|
status of the volumes and its logical disks on the RAID controller:
|
2007-09-09 20:13:19 +04:00
|
|
|
.Bd -literal
|
2008-03-03 22:11:45 +03:00
|
|
|
$ bioctl arcmsr0 show
|
2008-01-03 02:45:06 +03:00
|
|
|
Volume Status Size Device/Label RAID Level Stripe
|
|
|
|
=================================================================
|
|
|
|
0 Building 468G sd0 ARC-1210-VOL#00 RAID 6 128KB 0% done
|
2008-02-02 06:21:47 +03:00
|
|
|
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]
|
2007-05-01 21:18:52 +04:00
|
|
|
.Ed
|
2008-02-02 06:21:47 +03:00
|
|
|
.Pp
|
2008-03-16 14:07:23 +03:00
|
|
|
To create a RAID 5 volume on the SCSI 0:15.0 location on the disks
|
2011-04-26 02:09:29 +04:00
|
|
|
0, 1, 2, and 3, with stripe size of 64Kb on the first volume ID,
|
2008-03-16 14:07:23 +03:00
|
|
|
using all available free space on the disks:
|
2008-02-02 06:21:47 +03:00
|
|
|
.Pp
|
2008-03-03 19:10:48 +03:00
|
|
|
.Dl $ bioctl arcmsr0 create volume 0 0-3 64 5 0:15.0
|
2008-02-02 06:21:47 +03:00
|
|
|
.Pp
|
2008-03-03 19:10:48 +03:00
|
|
|
To remove the volume 0 previously created at the SCSI 0:15.0 location:
|
2008-02-02 06:21:47 +03:00
|
|
|
.Pp
|
2008-03-03 19:10:48 +03:00
|
|
|
.Dl $ bioctl arcmsr0 remove volume 0 0:15.0
|
2007-05-01 21:18:52 +04:00
|
|
|
.Sh SEE ALSO
|
2007-12-05 15:29:55 +03:00
|
|
|
.Xr arcmsr 4 ,
|
2007-05-01 21:18:52 +04:00
|
|
|
.Xr bio 4 ,
|
2008-03-16 13:01:32 +03:00
|
|
|
.Xr cac 4 ,
|
2008-05-26 00:09:55 +04:00
|
|
|
.Xr ciss 4 ,
|
2007-09-09 20:13:19 +04:00
|
|
|
.Xr mfi 4
|
2007-05-01 21:18:52 +04:00
|
|
|
.Sh HISTORY
|
|
|
|
The
|
|
|
|
.Nm
|
|
|
|
command first appeared in
|
2008-01-03 02:45:06 +03:00
|
|
|
.Ox 3.8 ,
|
|
|
|
it was rewritten for
|
2008-01-11 20:11:42 +03:00
|
|
|
.Nx 5.0 .
|
2007-05-01 21:18:52 +04:00
|
|
|
.Sh AUTHORS
|
|
|
|
The
|
|
|
|
.Nm
|
|
|
|
interface was written by
|
2008-03-16 14:07:23 +03:00
|
|
|
.An Marco Peereboom Aq marco@openbsd.org
|
2008-01-03 02:45:06 +03:00
|
|
|
and was rewritten with multiple features by
|
2008-03-16 14:07:23 +03:00
|
|
|
.An Juan Romero Pardines Aq xtraeme@NetBSD.org .
|