]> CyberLeo.Net >> Repos - FreeBSD/FreeBSD.git/blob - sbin/geom/core/geom.8
Add manual page for geom(8) utility.
[FreeBSD/FreeBSD.git] / sbin / geom / core / geom.8
1 .\" Copyright (c) 2004 Pawel Jakub Dawidek <pjd@FreeBSD.org>
2 .\" All rights reserved.
3 .\"
4 .\" Redistribution and use in source and binary forms, with or without
5 .\" modification, are permitted provided that the following conditions
6 .\" are met:
7 .\" 1. Redistributions of source code must retain the above copyright
8 .\"    notice, this list of conditions and the following disclaimer.
9 .\" 2. Redistributions in binary form must reproduce the above copyright
10 .\"    notice, this list of conditions and the following disclaimer in the
11 .\"    documentation and/or other materials provided with the distribution.
12 .\"
13 .\" THIS SOFTWARE IS PROVIDED BY THE AUTHORS AND CONTRIBUTORS ``AS IS'' AND
14 .\" ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
15 .\" IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
16 .\" ARE DISCLAIMED.  IN NO EVENT SHALL THE AUTHORS OR CONTRIBUTORS BE LIABLE
17 .\" FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
18 .\" DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
19 .\" OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
20 .\" HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
21 .\" LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
22 .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
23 .\" SUCH DAMAGE.
24 .\"
25 .\" $FreeBSD$
26 .\"
27 .Dd May 21, 2004
28 .Dt GEOM 8
29 .Os
30 .Sh NAME
31 .Nm geom
32 .Nd "universal control utility for GEOM classes"
33 .Sh SYNOPSIS
34 .Nm
35 .Ar class
36 .Ar command
37 .Op Ar options
38 .Sh DESCRIPTION
39 The
40 .Nm
41 utility is used to control various GEOM classes.
42 A class has to be aware of
43 .Xr geom 8
44 comunication methods, but there are also some standard commands
45 which can be used for existing, not
46 .Xr geom 8
47 aware classes.
48 Here is the list of standard commands:
49 .Bl -tag -width ".Cm unload"
50 .It Cm help
51 List all available commands for the given class.
52 .It Cm list
53 Print detailed information (within the given class) about all providers
54 (if no additional arguments were specified) or the given providers.
55 This command is only available if the given class exists in the kernel.
56 .It Cm load
57 Load the kernel module that implements the given class.
58 This command is only available if the class doesn't yet exist in the kernel and
59 the file
60 .Pa geom_<class>.ko
61 can be found in one of the directories specifed in
62 .Va kern.module_path
63 sysctl.
64 .It Cm unload
65 Unload the kernel module which implements the given class.
66 This command is only available if the given class is loaded as a
67 kernel module.
68 .El
69 .Pp
70 Class-specific commands are implemented as shared libraries which
71 are stored in
72 .Pa /lib/geom/
73 directory and are loaded via
74 .Xr dlopen 3
75 function when the class name is known.
76 When a class-specific shared library exists, a direct utility should also be
77 available under the name of
78 .Nm g<class> .
79 .Pp
80 Currently available classes which are aware of
81 .Xr geom 8 :
82 .Bl -bullet -offset indent -compact
83 .It
84 CONCAT
85 .It
86 NOP
87 .It
88 STRIPE
89 .El
90 .Sh EXAMPLES
91 The following example shows how to set up a stripe on three disks for automatic
92 configuration:
93 .Bd -literal -offset indent
94 geom stripe label -v -s 65536 data /dev/da0 /dev/da1 /dev/da2
95 or:
96 gstripe label -v -s 65536 data /dev/da0 /dev/da1 /dev/da2
97 .Ed
98 .Pp
99 Print the list of all providers from the DISK class:
100 .Bd -literal -offset indent
101 geom disk list
102 .Ed
103 .Pp
104 Unload a kernel module which implements the MD class:
105 .Bd -literal -offset indent
106 geom md unload
107 .Ed
108 .Sh DIAGNOSTICS
109 Exit status is 0 on success, and 1 if the command fails.
110 .Sh SEE ALSO
111 .Xr geom 4 ,
112 .Xr gconcat 8 ,
113 .Xr gnop 8 ,
114 .Xr gstripe 8
115 .Sh HISTORY
116 The
117 .Nm
118 utility appeared in
119 .Fx 5.3 .
120 .Sh AUTHORS
121 .An Pawel Jakub Dawidek Aq pjd@FreeBSD.org