1.\" $NetBSD: ccdconfig.8,v 1.21 2002/10/01 13:40:26 wiz Exp $ 2.\" 3.\" Copyright (c) 1996, 1997 The NetBSD Foundation, Inc. 4.\" All rights reserved. 5.\" 6.\" This code is derived from software contributed to The NetBSD Foundation 7.\" by Jason R. Thorpe. 8.\" 9.\" Redistribution and use in source and binary forms, with or without 10.\" modification, are permitted provided that the following conditions 11.\" are met: 12.\" 1. Redistributions of source code must retain the above copyright 13.\" notice, this list of conditions and the following disclaimer. 14.\" 2. Redistributions in binary form must reproduce the above copyright 15.\" notice, this list of conditions and the following disclaimer in the 16.\" documentation and/or other materials provided with the distribution. 17.\" 3. All advertising materials mentioning features or use of this software 18.\" must display the following acknowledgement: 19.\" This product includes software developed by the NetBSD 20.\" Foundation, Inc. and its contributors. 21.\" 4. Neither the name of The NetBSD Foundation nor the names of its 22.\" contributors may be used to endorse or promote products derived 23.\" from this software without specific prior written permission. 24.\" 25.\" THIS SOFTWARE IS PROVIDED BY THE NETBSD FOUNDATION, INC. AND CONTRIBUTORS 26.\" ``AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED 27.\" TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR 28.\" PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE FOUNDATION OR CONTRIBUTORS 29.\" BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR 30.\" CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF 31.\" SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS 32.\" INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN 33.\" CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) 34.\" ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE 35.\" POSSIBILITY OF SUCH DAMAGE. 36.\" 37.Dd July 17, 1995 38.Dt CCDCONFIG 8 39.Os 40.Sh NAME 41.Nm ccdconfig 42.Nd configuration utility for the concatenated disk driver 43.Sh SYNOPSIS 44.Nm 45.Op Fl cv 46.Ar ccd 47.Ar ileave 48.Op Ar flags 49.Ar dev 50.Op Ar ... 51.Nm "" 52.Fl C 53.Op Fl v 54.Op Fl f Ar config_file 55.Nm "" 56.Fl u 57.Op Fl v 58.Ar ccd 59.Op Ar ... 60.Nm "" 61.Fl U 62.Op Fl v 63.Op Fl f Ar config_file 64.Nm "" 65.Fl g 66.Op Fl M Ar core 67.Op Fl N Ar system 68.Oo 69.Ar ccd Oo ... 70.Oc 71.Oc 72.Sh DESCRIPTION 73.Nm 74is used to dynamically configure and unconfigure concatenated disk 75devices, or ccds. 76For more information about the ccd, see 77.Xr ccd 4 . 78.Pp 79The options are as follows: 80.Bl -tag -width indent 81.It Fl c 82Configure a ccd. 83This is the default behavior of 84.Nm "" . 85.It Fl C 86Configure all ccd devices listed in the ccd configuration file. 87.It Fl f Ar config_file 88When configuring or unconfiguring all devices, read the file 89.Pa config_file 90instead of the default 91.Pa /etc/ccd.conf . 92.It Fl g 93Dump the current ccd configuration in a format suitable 94for use as the ccd configuration file. 95If no arguments are specified, every configured ccd is dumped. 96Otherwise, the configuration of each listed ccd is dumped. 97.It Fl M Ar core 98Extract values associated with the name list from 99.Pa core 100instead of the default 101.Pa /dev/mem . 102.It Fl N Ar system 103Extract the name list from 104.Pa system 105instead of the default 106.Pa /netbsd . 107.It Fl u 108Unconfigure a ccd. 109.It Fl U 110Unconfigure all ccd devices listed the ccd configuration file. 111.It Fl v 112Causes 113.Nm 114to be verbose. 115.El 116.Pp 117A ccd is described on the command line and in the ccd configuration 118file by the name of the ccd, the interleave factor, 119the ccd configuration flags, and a list of one or more devices. 120The flags may be represented as a decimal number, a hexadecimal number, 121a comma-separated list of strings, or the word 122.Dq none . 123The flags are as follows: 124.Bd -unfilled -offset indent 125.Bl -column "CCDF_UNIFORM " "0x02 " "Interleave should be dmmax" 126.Em "Symbolic Numeric Comment" 127.It CCDF_UNIFORM 0x02 Use uniform interleave 128.El 129.Ed 130.Ss /etc/ccd.conf 131The file 132.Pa /etc/ccd.conf 133is used to configure 134.Nm 135if 136.Fl C 137or 138.Fl U 139is used. 140Each line of the configuration file contains arguments as per the 141.Fl c 142argument: 143.Ar ccd 144.Ar ileave 145.Op Ar flags 146.Ar dev 147.Op Ar ... 148.Pp 149A 150.Sq # 151is a comment, and everything to end of line is ignored. 152A 153.Sq \e 154at the end of a line indicates that the next line should be concatenated 155with the current. 156A 157.Sq \e 158preceding any character (other than the end of line) prevents that 159character's special meaning from taking effect. 160.Pp 161See 162.Sx EXAMPLES 163for an example of 164.Pa /etc/ccd.conf . 165.Sh FILES 166/etc/ccd.conf - default ccd configuration file. 167.Sh EXAMPLES 168The following command, executed from the command line, would configure ccd0 169with 4 components (/dev/sd2e, /dev/sd3e, /dev/sd4e, /dev/sd5e), and an 170interleave factor of 32 blocks. 171.Bd -unfilled -offset indent 172# ccdconfig ccd0 32 0 /dev/sd2e /dev/sd3e /dev/sd4e /dev/sd5e 173.Ed 174.Pp 175An example 176.Pa /etc/ccd.conf : 177.Bd -unfilled -offset indent 178# 179# /etc/ccd.conf 180# Configuration file for concatenated disk devices 181# 182.Pp 183# ccd ileave flags component devices 184ccd0 16 none /dev/sd2e /dev/sd3e 185.Ed 186.Sh SEE ALSO 187.Xr ccd 4 , 188.Xr ccd.conf 5 , 189.Xr rc 8 190.Sh HISTORY 191The 192.Nm 193command first appeared in 194.Nx 1.1 . 195