1VGREDUCE(8)                 System Manager's Manual                VGREDUCE(8)
2
3
4

NAME

6       vgreduce - Remove physical volume(s) from a volume group
7

SYNOPSIS

9       vgreduce option_args position_args
10           [ option_args ]
11
12        -a|--all
13        -A|--autobackup y|n
14           --commandprofile String
15           --config String
16        -d|--debug
17           --driverloaded y|n
18        -f|--force
19        -h|--help
20           --lockopt String
21           --longhelp
22           --mirrorsonly
23           --nolocking
24           --profile String
25        -q|--quiet
26           --removemissing
27           --reportformat basic|json
28        -t|--test
29        -v|--verbose
30           --version
31        -y|--yes
32

DESCRIPTION

34       vgreduce removes one or more unused PVs from a VG.
35

USAGE

37       Remove a PV from a VG.
38
39       vgreduce VG PV ...
40           [ COMMON_OPTIONS ]
41       -
42
43       Remove all unused PVs from a VG.
44
45       vgreduce -a|--all VG
46           [ COMMON_OPTIONS ]
47       -
48
49       Remove all missing PVs from a VG.
50
51       vgreduce --removemissing VG
52           [    --mirrorsonly ]
53           [ COMMON_OPTIONS ]
54       -
55
56       Common options for command:
57           [ -A|--autobackup y|n ]
58           [ -f|--force ]
59           [    --reportformat basic|json ]
60
61       Common options for lvm:
62           [ -d|--debug ]
63           [ -h|--help ]
64           [ -q|--quiet ]
65           [ -t|--test ]
66           [ -v|--verbose ]
67           [ -y|--yes ]
68           [    --commandprofile String ]
69           [    --config String ]
70           [    --driverloaded y|n ]
71           [    --lockopt String ]
72           [    --longhelp ]
73           [    --nolocking ]
74           [    --profile String ]
75           [    --version ]
76

OPTIONS

78       -a|--all
79              Removes all empty PVs if none are named on the command line.
80
81       -A|--autobackup y|n
82              Specifies if metadata should be backed up automatically after a
83              change.  Enabling this is strongly advised! See vgcfgbackup(8)
84              for more information.
85
86       --commandprofile String
87              The command profile to use for command configuration.  See
88              lvm.conf(5) for more information about profiles.
89
90       --config String
91              Config settings for the command. These override lvm.conf set‐
92              tings.  The String arg uses the same format as lvm.conf, or may
93              use section/field syntax.  See lvm.conf(5) for more information
94              about config.
95
96       -d|--debug ...
97              Set debug level. Repeat from 1 to 6 times to increase the detail
98              of messages sent to the log file and/or syslog (if configured).
99
100       --driverloaded y|n
101              If set to no, the command will not attempt to use device-mapper.
102              For testing and debugging.
103
104       -f|--force ...
105              Override various checks, confirmations and protections.  Use
106              with extreme caution.
107
108       -h|--help
109              Display help text.
110
111       --lockopt String
112              Used to pass options for special cases to lvmlockd.  See lvm‐
113              lockd(8) for more information.
114
115       --longhelp
116              Display long help text.
117
118       --mirrorsonly
119              Only remove missing PVs from mirror LVs.
120
121       --nolocking
122              Disable locking.
123
124       --profile String
125              An alias for --commandprofile or --metadataprofile, depending on
126              the command.
127
128       -q|--quiet ...
129              Suppress output and log messages. Overrides --debug and --ver‐
130              bose.  Repeat once to also suppress any prompts with answer
131              'no'.
132
133       --removemissing
134              Removes all missing PVs from the VG, if there are no LVs allo‐
135              cated on them. This resumes normal operation of the VG (new LVs
136              may again be created, changed and so on).  If this is not possi‐
137              ble because LVs are referencing the missing PVs, this option can
138              be combined with --force to have the command remove any partial
139              LVs. In this case, any LVs and dependent snapshots that were
140              partly on the missing disks are removed completely, including
141              those parts on disks that are still present.  If LVs spanned
142              several disks, including ones that are lost, salvaging some data
143              first may be possible by activating LVs in partial mode.
144
145       --reportformat basic|json
146              Overrides current output format for reports which is defined
147              globally by the report/output_format setting in lvm.conf.  basic
148              is the original format with columns and rows.  If there is more
149              than one report per command, each report is prefixed with the
150              report name for identification. json produces report output in
151              JSON format. See lvmreport(7) for more information.
152
153       -t|--test
154              Run in test mode. Commands will not update metadata.  This is
155              implemented by disabling all metadata writing but nevertheless
156              returning success to the calling function. This may lead to
157              unusual error messages in multi-stage operations if a tool
158              relies on reading back metadata it believes has changed but
159              hasn't.
160
161       -v|--verbose ...
162              Set verbose level. Repeat from 1 to 4 times to increase the
163              detail of messages sent to stdout and stderr.
164
165       --version
166              Display version information.
167
168       -y|--yes
169              Do not prompt for confirmation interactively but always assume
170              the answer yes. Use with extreme caution.  (For automatic no,
171              see -qq.)
172

VARIABLES

174       VG
175              Volume Group name.  See lvm(8) for valid names.
176
177       PV
178              Physical Volume name, a device path under  /dev.   For  commands
179              managing physical extents, a PV positional arg generally accepts
180              a suffix indicating a range (or  multiple  ranges)  of  physical
181              extents  (PEs). When the first PE is omitted, it defaults to the
182              start of the device, and when the last PE is omitted it defaults
183              to  end.   Start and end range (inclusive): PV[:PE-PE]...  Start
184              and length range (counting from 0): PV[:PE+PE]...
185
186       String
187              See the option description for information about the string con‐
188              tent.
189
190       Size[UNIT]
191              Size  is  an  input number that accepts an optional unit.  Input
192              units are always treated as base two values, regardless of capi‐
193              talization,  e.g.  'k'  and 'K' both refer to 1024.  The default
194              input unit is specified by letter, followed by |UNIT.  UNIT rep‐
195              resents  other  possible  input units: bBsSkKmMgGtTpPeE.  b|B is
196              bytes, s|S is sectors of 512 bytes, k|K  is  kilobytes,  m|M  is
197              megabytes, g|G is gigabytes, t|T is terabytes, p|P is petabytes,
198              e|E is exabytes.  (This should not be confused with  the  output
199              control --units, where capital letters mean multiple of 1000.)
200

ENVIRONMENT VARIABLES

202       See  lvm(8)  for  information  about environment variables used by lvm.
203       For example, LVM_VG_NAME can generally be substituted for a required VG
204       parameter.
205

SEE ALSO

207       lvm(8) lvm.conf(5) lvmconfig(8)
208
209       pvchange(8)  pvck(8)  pvcreate(8)  pvdisplay(8)  pvmove(8)  pvremove(8)
210       pvresize(8) pvs(8) pvscan(8)
211
212       vgcfgbackup(8) vgcfgrestore(8) vgchange(8) vgck(8)  vgcreate(8)  vgcon‐
213       vert(8)  vgdisplay(8)  vgexport(8)  vgextend(8)  vgimport(8)  vgimport‐
214       clone(8) vgmerge(8) vgmknodes(8)  vgreduce(8)  vgremove(8)  vgrename(8)
215       vgs(8) vgscan(8) vgsplit(8)
216
217       lvcreate(8)  lvchange(8)  lvconvert(8)  lvdisplay(8)  lvextend(8) lvre‐
218       duce(8) lvremove(8) lvrename(8) lvresize(8) lvs(8) lvscan(8)
219
220       lvm-fullreport(8) lvm-lvpoll(8) lvm2-activation-generator(8) blkdeacti‐
221       vate(8) lvmdump(8)
222
223       dmeventd(8)  lvmpolld(8)  lvmlockd(8)  lvmlockctl(8)  cmirrord(8) lvmd‐
224       busd(8)
225
226       lvmsystemid(7) lvmreport(7) lvmraid(7) lvmthin(7) lvmcache(7)
227
228
229
230Red Hat, Inc.          LVM TOOLS 2.03.09(2) (2020-03-26)           VGREDUCE(8)
Impressum