1PVRESIZE(8) System Manager's Manual PVRESIZE(8)
2
3
4
6 pvresize - Resize physical volume(s)
7
9 pvresize position_args
10 [ option_args ]
11
13 pvresize resizes a PV. The PV may already be in a VG and may have ac‐
14 tive LVs allocated on it.
15
17 pvresize PV ...
18 [ --setphysicalvolumesize Size[m|UNIT] ]
19 [ --reportformat basic|json ]
20 [ COMMON_OPTIONS ]
21
22 Common options for lvm:
23 [ -d|--debug ]
24 [ -h|--help ]
25 [ -q|--quiet ]
26 [ -t|--test ]
27 [ -v|--verbose ]
28 [ -y|--yes ]
29 [ --commandprofile String ]
30 [ --config String ]
31 [ --driverloaded y|n ]
32 [ --lockopt String ]
33 [ --longhelp ]
34 [ --nolocking ]
35 [ --profile String ]
36 [ --version ]
37
39 --commandprofile String
40 The command profile to use for command configuration. See
41 lvm.conf(5) for more information about profiles.
42
43 --config String
44 Config settings for the command. These override lvm.conf set‐
45 tings. The String arg uses the same format as lvm.conf, or may
46 use section/field syntax. See lvm.conf(5) for more information
47 about config.
48
49 -d|--debug ...
50 Set debug level. Repeat from 1 to 6 times to increase the detail
51 of messages sent to the log file and/or syslog (if configured).
52
53 --driverloaded y|n
54 If set to no, the command will not attempt to use device-mapper.
55 For testing and debugging.
56
57 -h|--help
58 Display help text.
59
60 --lockopt String
61 Used to pass options for special cases to lvmlockd. See lvm‐
62 lockd(8) for more information.
63
64 --longhelp
65 Display long help text.
66
67 --nolocking
68 Disable locking.
69
70 --profile String
71 An alias for --commandprofile or --metadataprofile, depending on
72 the command.
73
74 -q|--quiet ...
75 Suppress output and log messages. Overrides --debug and --ver‐
76 bose. Repeat once to also suppress any prompts with answer
77 'no'.
78
79 --reportformat basic|json
80 Overrides current output format for reports which is defined
81 globally by the report/output_format setting in lvm.conf. basic
82 is the original format with columns and rows. If there is more
83 than one report per command, each report is prefixed with the
84 report name for identification. json produces report output in
85 JSON format. See lvmreport(7) for more information.
86
87 --setphysicalvolumesize Size[m|UNIT]
88 Overrides the automatically detected size of the PV. Use with
89 care, or prior to reducing the physical size of the device.
90
91 -t|--test
92 Run in test mode. Commands will not update metadata. This is
93 implemented by disabling all metadata writing but nevertheless
94 returning success to the calling function. This may lead to un‐
95 usual error messages in multi-stage operations if a tool relies
96 on reading back metadata it believes has changed but hasn't.
97
98 -v|--verbose ...
99 Set verbose level. Repeat from 1 to 4 times to increase the de‐
100 tail of messages sent to stdout and stderr.
101
102 --version
103 Display version information.
104
105 -y|--yes
106 Do not prompt for confirmation interactively but always assume
107 the answer yes. Use with extreme caution. (For automatic no,
108 see -qq.)
109
111 PV
112 Physical Volume name, a device path under /dev. For commands
113 managing physical extents, a PV positional arg generally accepts
114 a suffix indicating a range (or multiple ranges) of physical ex‐
115 tents (PEs). When the first PE is omitted, it defaults to the
116 start of the device, and when the last PE is omitted it defaults
117 to end. Start and end range (inclusive): PV[:PE-PE]... Start
118 and length range (counting from 0): PV[:PE+PE]...
119
120 String
121 See the option description for information about the string con‐
122 tent.
123
124 Size[UNIT]
125 Size is an input number that accepts an optional unit. Input
126 units are always treated as base two values, regardless of capi‐
127 talization, e.g. 'k' and 'K' both refer to 1024. The default
128 input unit is specified by letter, followed by |UNIT. UNIT rep‐
129 resents other possible input units: bBsSkKmMgGtTpPeE. b|B is
130 bytes, s|S is sectors of 512 bytes, k|K is KiB, m|M is MiB, g|G
131 is GiB, t|T is TiB, p|P is PiB, e|E is EiB. (This should not be
132 confused with the output control --units, where capital letters
133 mean multiple of 1000.)
134
136 See lvm(8) for information about environment variables used by lvm.
137 For example, LVM_VG_NAME can generally be substituted for a required VG
138 parameter.
139
141 pvresize will refuse to shrink a PV if it has allocated extents beyond
142 the new end.
143
145 Expand a PV after enlarging the partition.
146 pvresize /dev/sda1
147
148 Shrink a PV prior to shrinking the partition (ensure that the PV size
149 is appropriate for the intended new partition size).
150 pvresize --setphysicalvolumesize 40G /dev/sda1
151
153 lvm(8) lvm.conf(5) lvmconfig(8)
154
155 pvchange(8) pvck(8) pvcreate(8) pvdisplay(8) pvmove(8) pvremove(8)
156 pvresize(8) pvs(8) pvscan(8)
157
158 vgcfgbackup(8) vgcfgrestore(8) vgchange(8) vgck(8) vgcreate(8) vgcon‐
159 vert(8) vgdisplay(8) vgexport(8) vgextend(8) vgimport(8) vgimport‐
160 clone(8) vgmerge(8) vgmknodes(8) vgreduce(8) vgremove(8) vgrename(8)
161 vgs(8) vgscan(8) vgsplit(8)
162
163 lvcreate(8) lvchange(8) lvconvert(8) lvdisplay(8) lvextend(8) lvre‐
164 duce(8) lvremove(8) lvrename(8) lvresize(8) lvs(8) lvscan(8)
165
166 lvm-fullreport(8) lvm-lvpoll(8) lvm2-activation-generator(8) blkdeacti‐
167 vate(8) lvmdump(8)
168
169 dmeventd(8) lvmpolld(8) lvmlockd(8) lvmlockctl(8) cmirrord(8) lvmd‐
170 busd(8)
171
172 lvmsystemid(7) lvmreport(7) lvmraid(7) lvmthin(7) lvmcache(7)
173
174
175
176Red Hat, Inc. LVM TOOLS 2.03.11(2) (2021-01-08) PVRESIZE(8)