1*a5770eb5SAlexander Ziaee.\"- 2*a5770eb5SAlexander Ziaee.\" SPDX-License-Identifier: BSD-2-Clause 3*a5770eb5SAlexander Ziaee.\" 485e9dc7dSPawel Jakub Dawidek.\" Copyright (c) 2004-2005 Pawel Jakub Dawidek <pjd@FreeBSD.org> 53e64260dSPawel Jakub Dawidek.\" All rights reserved. 63e64260dSPawel Jakub Dawidek.\" 73e64260dSPawel Jakub Dawidek.\" Redistribution and use in source and binary forms, with or without 83e64260dSPawel Jakub Dawidek.\" modification, are permitted provided that the following conditions 93e64260dSPawel Jakub Dawidek.\" are met: 103e64260dSPawel Jakub Dawidek.\" 1. Redistributions of source code must retain the above copyright 113e64260dSPawel Jakub Dawidek.\" notice, this list of conditions and the following disclaimer. 123e64260dSPawel Jakub Dawidek.\" 2. Redistributions in binary form must reproduce the above copyright 133e64260dSPawel Jakub Dawidek.\" notice, this list of conditions and the following disclaimer in the 143e64260dSPawel Jakub Dawidek.\" documentation and/or other materials provided with the distribution. 153e64260dSPawel Jakub Dawidek.\" 163e64260dSPawel Jakub Dawidek.\" THIS SOFTWARE IS PROVIDED BY THE AUTHORS AND CONTRIBUTORS ``AS IS'' AND 173e64260dSPawel Jakub Dawidek.\" ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE 183e64260dSPawel Jakub Dawidek.\" IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE 193e64260dSPawel Jakub Dawidek.\" ARE DISCLAIMED. IN NO EVENT SHALL THE AUTHORS OR CONTRIBUTORS BE LIABLE 203e64260dSPawel Jakub Dawidek.\" FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL 213e64260dSPawel Jakub Dawidek.\" DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS 223e64260dSPawel Jakub Dawidek.\" OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) 233e64260dSPawel Jakub Dawidek.\" HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT 243e64260dSPawel Jakub Dawidek.\" LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY 253e64260dSPawel Jakub Dawidek.\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF 263e64260dSPawel Jakub Dawidek.\" SUCH DAMAGE. 273e64260dSPawel Jakub Dawidek.\" 28794f5122SMateusz Piotrowski.Dd May 9, 2023 293e64260dSPawel Jakub Dawidek.Dt GEOM 8 303e64260dSPawel Jakub Dawidek.Os 313e64260dSPawel Jakub Dawidek.Sh NAME 323e64260dSPawel Jakub Dawidek.Nm geom 33*a5770eb5SAlexander Ziaee.Nd universal control utility for GEOM classes 343e64260dSPawel Jakub Dawidek.Sh SYNOPSIS 353e64260dSPawel Jakub Dawidek.Nm 363e64260dSPawel Jakub Dawidek.Ar class 37adc8d20dSPawel Jakub Dawidek.Cm help 38adc8d20dSPawel Jakub Dawidek.Nm 39adc8d20dSPawel Jakub Dawidek.Ar class 40adc8d20dSPawel Jakub Dawidek.Cm list 4183d165c1SAlexander Motin.Op Fl a 42adc8d20dSPawel Jakub Dawidek.Op Ar name ... 43adc8d20dSPawel Jakub Dawidek.Nm 44adc8d20dSPawel Jakub Dawidek.Ar class 45adc8d20dSPawel Jakub Dawidek.Cm status 4683d165c1SAlexander Motin.Op Fl ags 47adc8d20dSPawel Jakub Dawidek.Op Ar name ... 48adc8d20dSPawel Jakub Dawidek.Nm 49adc8d20dSPawel Jakub Dawidek.Ar class 50adc8d20dSPawel Jakub Dawidek.Cm load 51adc8d20dSPawel Jakub Dawidek.Op Fl v 52adc8d20dSPawel Jakub Dawidek.Nm 53adc8d20dSPawel Jakub Dawidek.Ar class 54adc8d20dSPawel Jakub Dawidek.Cm unload 55adc8d20dSPawel Jakub Dawidek.Op Fl v 560f73f701SEdward Tomasz Napierala.Nm 570f73f701SEdward Tomasz Napierala.Fl p 580f73f701SEdward Tomasz Napierala.Ar provider-name 596a027382SEdward Tomasz Napierala.Nm 606a027382SEdward Tomasz Napierala.Fl t 613e64260dSPawel Jakub Dawidek.Sh DESCRIPTION 623e64260dSPawel Jakub DawidekThe 633e64260dSPawel Jakub Dawidek.Nm 643e64260dSPawel Jakub Dawidekutility is used to control various GEOM classes. 653e64260dSPawel Jakub DawidekA class has to be aware of 6694db10b2SEd Maste.Nm 67f6ac2391SJoel Dahlcommunication methods, but there are also some standard commands 68d608b5abSCeri Davieswhich can be used for existing 6994db10b2SEd Maste.Nm 70d608b5abSCeri Daviesunaware classes. 713e64260dSPawel Jakub DawidekHere is the list of standard commands: 72*a5770eb5SAlexander Ziaee.Bl -tag -width indent 733e64260dSPawel Jakub Dawidek.It Cm help 743e64260dSPawel Jakub DawidekList all available commands for the given class. 753e64260dSPawel Jakub Dawidek.It Cm list 761d723f1dSPawel Jakub DawidekPrint detailed information (within the given class) about all geoms 771d723f1dSPawel Jakub Dawidek(if no additional arguments were specified) or the given geoms. 783e64260dSPawel Jakub DawidekThis command is only available if the given class exists in the kernel. 7983d165c1SAlexander MotinAdditional options include: 80*a5770eb5SAlexander Ziaee.Bl -tag -width "-a" 8183d165c1SAlexander Motin.It Fl a 8283d165c1SAlexander MotinPrint information for geoms without providers. 8383d165c1SAlexander Motin.El 8485e9dc7dSPawel Jakub Dawidek.It Cm status 8585e9dc7dSPawel Jakub DawidekPrint general information (within the given class) about all geoms 8685e9dc7dSPawel Jakub Dawidek(if no additional arguments were specified) or the given geoms. 8785e9dc7dSPawel Jakub DawidekThis command is only available if the given class exists in the kernel. 88ccc0c897SPawel Jakub Dawidek.Pp 89ccc0c897SPawel Jakub DawidekAdditional options include: 90*a5770eb5SAlexander Ziaee.Bl -tag -width "-s" 9183d165c1SAlexander Motin.It Fl a 92*a5770eb5SAlexander ZiaeeWhen used with 93*a5770eb5SAlexander Ziaee.Fl g , 94*a5770eb5SAlexander Ziaeeprint status for geoms without providers. 9583d165c1SAlexander Motin.It Fl g 9683d165c1SAlexander MotinReport statuses for geoms instead of providers. 97ccc0c897SPawel Jakub Dawidek.It Fl s 98ccc0c897SPawel Jakub DawidekProduce script-friendly output. 99ccc0c897SPawel Jakub Dawidek.El 1003e64260dSPawel Jakub Dawidek.It Cm load 1013e64260dSPawel Jakub DawidekLoad the kernel module that implements the given class. 1020e252c9aSRuslan ErmilovThis command is only available if the class does not yet exist in the kernel and 1033e64260dSPawel Jakub Dawidekthe file 1040e252c9aSRuslan Ermilov.Pa geom_ Ns Ao Ar class Ac Ns Pa .ko 105c2025a76SJoel Dahlcan be found in one of the directories specified in 1063e64260dSPawel Jakub Dawidek.Va kern.module_path 1073e64260dSPawel Jakub Dawideksysctl. 1083e64260dSPawel Jakub Dawidek.It Cm unload 1093e64260dSPawel Jakub DawidekUnload the kernel module which implements the given class. 1103e64260dSPawel Jakub DawidekThis command is only available if the given class is loaded as a 1113e64260dSPawel Jakub Dawidekkernel module. 1123e64260dSPawel Jakub Dawidek.El 1133e64260dSPawel Jakub Dawidek.Pp 1140f73f701SEdward Tomasz NapieralaAdditional options include: 115*a5770eb5SAlexander Ziaee.Bl -tag -width indent 1160f73f701SEdward Tomasz Napierala.It Fl p Ar provider-name 1170f73f701SEdward Tomasz NapieralaPrint detailed information about the geom which provides 1180f73f701SEdward Tomasz Napierala.Ar provider-name . 1196a027382SEdward Tomasz Napierala.It Fl t 1206a027382SEdward Tomasz NapieralaDisplay geoms hierarchy as a tree. 1210f73f701SEdward Tomasz Napierala.El 1220f73f701SEdward Tomasz Napierala.Pp 1233e64260dSPawel Jakub DawidekClass-specific commands are implemented as shared libraries which 1243e64260dSPawel Jakub Dawidekare stored in 1253e64260dSPawel Jakub Dawidek.Pa /lib/geom/ 1263e64260dSPawel Jakub Dawidekdirectory and are loaded via 1273e64260dSPawel Jakub Dawidek.Xr dlopen 3 1283e64260dSPawel Jakub Dawidekfunction when the class name is known. 1293e64260dSPawel Jakub DawidekWhen a class-specific shared library exists, a direct utility should also be 1303e64260dSPawel Jakub Dawidekavailable under the name of 1310e252c9aSRuslan Ermilov.Nm g Ns Ar class . 1323e64260dSPawel Jakub Dawidek.Pp 133794f5122SMateusz PiotrowskiCurrently, classes aware of 134794f5122SMateusz Piotrowski.Nm 135794f5122SMateusz Piotrowskiare: 1360e252c9aSRuslan Ermilov.Pp 1373e64260dSPawel Jakub Dawidek.Bl -bullet -offset indent -compact 1383e64260dSPawel Jakub Dawidek.It 139081632cfSPawel Jakub DawidekCACHE 140081632cfSPawel Jakub Dawidek.It 1413e64260dSPawel Jakub DawidekCONCAT 1423e64260dSPawel Jakub Dawidek.It 143343c20a8SPawel Jakub DawidekELI 144343c20a8SPawel Jakub Dawidek.It 145081632cfSPawel Jakub DawidekJOURNAL 146081632cfSPawel Jakub Dawidek.It 147b3530b8eSPawel Jakub DawidekLABEL 148b3530b8eSPawel Jakub Dawidek.It 149b3530b8eSPawel Jakub DawidekMIRROR 150b3530b8eSPawel Jakub Dawidek.It 15128887567SMaxim KonovalovMOUNTVER 15228887567SMaxim Konovalov.It 153081632cfSPawel Jakub DawidekMULTIPATH 154081632cfSPawel Jakub Dawidek.It 1553e64260dSPawel Jakub DawidekNOP 1563e64260dSPawel Jakub Dawidek.It 157081632cfSPawel Jakub DawidekPART 158081632cfSPawel Jakub Dawidek.It 15983d165c1SAlexander MotinRAID 16083d165c1SAlexander Motin.It 161b3530b8eSPawel Jakub DawidekRAID3 162b3530b8eSPawel Jakub Dawidek.It 16328887567SMaxim KonovalovSCHED 16428887567SMaxim Konovalov.It 165f7118698SPawel Jakub DawidekSHSEC 166f7118698SPawel Jakub Dawidek.It 1673e64260dSPawel Jakub DawidekSTRIPE 168f854db0bSPawel Jakub Dawidek.It 169c7996ddfSKirk McKusickUNION 170c7996ddfSKirk McKusick.It 171d181a912SEd MasteVINUM (deprecated) 172d181a912SEd Maste.It 173f854db0bSPawel Jakub DawidekVIRSTOR 1743e64260dSPawel Jakub Dawidek.El 1753bad06e9SPawel Jakub Dawidek.Sh ENVIRONMENT 1763bad06e9SPawel Jakub DawidekThe following environment variables affect the execution of 1773bad06e9SPawel Jakub Dawidek.Nm : 178*a5770eb5SAlexander Ziaee.Bl -tag -width "GEOM_LIBRARY_PATH" 1793bad06e9SPawel Jakub Dawidek.It Ev GEOM_LIBRARY_PATH 1803bad06e9SPawel Jakub DawidekSpecifies the path where shared libraries are stored instead of 1813bad06e9SPawel Jakub Dawidek.Pa /lib/geom/ . 1829d193848SUlf LilleengenMultiple paths can be specified with a colon-separated list of paths. 1833bad06e9SPawel Jakub Dawidek.El 1846087df9eSRuslan Ermilov.Sh EXIT STATUS 1856087df9eSRuslan ErmilovExit status is 0 on success, and 1 if the command fails. 1863e64260dSPawel Jakub Dawidek.Sh EXAMPLES 1873e64260dSPawel Jakub DawidekThe following example shows how to set up a stripe on three disks for automatic 1883e64260dSPawel Jakub Dawidekconfiguration: 1893e64260dSPawel Jakub Dawidek.Bd -literal -offset indent 1903e64260dSPawel Jakub Dawidekgeom stripe label -v -s 65536 data /dev/da0 /dev/da1 /dev/da2 191794f5122SMateusz Piotrowski.Ed 192794f5122SMateusz Piotrowski.Pp 1933e64260dSPawel Jakub Dawidekor: 194794f5122SMateusz Piotrowski.Bd -literal -offset indent 1953e64260dSPawel Jakub Dawidekgstripe label -v -s 65536 data /dev/da0 /dev/da1 /dev/da2 1963e64260dSPawel Jakub Dawidek.Ed 1973e64260dSPawel Jakub Dawidek.Pp 1983e64260dSPawel Jakub DawidekPrint the list of all providers from the DISK class: 1993e64260dSPawel Jakub Dawidek.Bd -literal -offset indent 2003e64260dSPawel Jakub Dawidekgeom disk list 2013e64260dSPawel Jakub Dawidek.Ed 2023e64260dSPawel Jakub Dawidek.Pp 2033e64260dSPawel Jakub DawidekUnload a kernel module which implements the MD class: 2043e64260dSPawel Jakub Dawidek.Bd -literal -offset indent 2053e64260dSPawel Jakub Dawidekgeom md unload 2063e64260dSPawel Jakub Dawidek.Ed 2073e64260dSPawel Jakub Dawidek.Sh SEE ALSO 208a7c13cccSEdward Tomasz Napierala.Xr libgeom 3 , 2093e64260dSPawel Jakub Dawidek.Xr geom 4 , 210cf7710e1SEdward Tomasz Napierala.Xr gcache 8 , 2113e64260dSPawel Jakub Dawidek.Xr gconcat 8 , 212343c20a8SPawel Jakub Dawidek.Xr geli 8 , 213081632cfSPawel Jakub Dawidek.Xr gjournal 8 , 214b03d3309SPawel Jakub Dawidek.Xr glabel 8 , 2150fe2ba03SPawel Jakub Dawidek.Xr gmirror 8 , 216b3f9d8c8SEdward Tomasz Napierala.Xr gmountver 8 , 217081632cfSPawel Jakub Dawidek.Xr gmultipath 8 , 2183e64260dSPawel Jakub Dawidek.Xr gnop 8 , 219081632cfSPawel Jakub Dawidek.Xr gpart 8 , 220925fa96bSPawel Jakub Dawidek.Xr graid3 8 , 2214a06539fSPawel Jakub Dawidek.Xr gshsec 8 , 222f854db0bSPawel Jakub Dawidek.Xr gstripe 8 , 223c7996ddfSKirk McKusick.Xr gunion 8 , 224d181a912SEd Maste.Xr gvinum 8 , 225f854db0bSPawel Jakub Dawidek.Xr gvirstor 8 2263e64260dSPawel Jakub Dawidek.Sh HISTORY 2273e64260dSPawel Jakub DawidekThe 2283e64260dSPawel Jakub Dawidek.Nm 2293e64260dSPawel Jakub Dawidekutility appeared in 2303e64260dSPawel Jakub Dawidek.Fx 5.3 . 2313e64260dSPawel Jakub Dawidek.Sh AUTHORS 232bd0891ceSBaptiste Daroussin.An Pawel Jakub Dawidek Aq Mt pjd@FreeBSD.org 233