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

NAME

6       pvresize - Resize physical volume(s)
7

SYNOPSIS

9       pvresize position_args
10           [ option_args ]
11

DESCRIPTION

13       pvresize  resizes  a  PV.  The  PV  may already be in a VG and may have
14       active LVs allocated on it.
15

USAGE

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           [    --profile String ]
35           [    --version ]
36

OPTIONS

38       --commandprofile String
39              The command profile to use for command configuration.  See
40              lvm.conf(5) for more information about profiles.
41
42       --config String
43              Config settings for the command. These override lvm.conf set‐
44              tings.  The String arg uses the same format as lvm.conf, or may
45              use section/field syntax.  See lvm.conf(5) for more information
46              about config.
47
48       -d|--debug ...
49              Set debug level. Repeat from 1 to 6 times to increase the detail
50              of messages sent to the log file and/or syslog (if configured).
51
52       --driverloaded y|n
53              If set to no, the command will not attempt to use device-mapper.
54              For testing and debugging.
55
56       -h|--help
57              Display help text.
58
59       --lockopt String
60              Used to pass options for special cases to lvmlockd.  See lvm‐
61              lockd(8) for more information.
62
63       --longhelp
64              Display long help text.
65
66       --profile String
67              An alias for --commandprofile or --metadataprofile, depending on
68              the command.
69
70       -q|--quiet ...
71              Suppress output and log messages. Overrides --debug and --ver‐
72              bose.  Repeat once to also suppress any prompts with answer
73              'no'.
74
75       --reportformat basic|json
76              Overrides current output format for reports which is defined
77              globally by the report/output_format setting in lvm.conf.  basic
78              is the original format with columns and rows.  If there is more
79              than one report per command, each report is prefixed with the
80              report name for identification. json produces report output in
81              JSON format. See lvmreport(7) for more information.
82
83       --setphysicalvolumesize Size[m|UNIT]
84              Overrides the automatically detected size of the PV.  Use with
85              care, or prior to reducing the physical size of the device.
86
87       -t|--test
88              Run in test mode. Commands will not update metadata.  This is
89              implemented by disabling all metadata writing but nevertheless
90              returning success to the calling function. This may lead to
91              unusual error messages in multi-stage operations if a tool
92              relies on reading back metadata it believes has changed but
93              hasn't.
94
95       -v|--verbose ...
96              Set verbose level. Repeat from 1 to 4 times to increase the
97              detail of messages sent to stdout and stderr.
98
99       --version
100              Display version information.
101
102       -y|--yes
103              Do not prompt for confirmation interactively but always assume
104              the answer yes. Use with extreme caution.  (For automatic no,
105              see -qq.)
106

VARIABLES

108       PV
109              Physical Volume name, a device path under  /dev.   For  commands
110              managing physical extents, a PV positional arg generally accepts
111              a suffix indicating a range (or  multiple  ranges)  of  physical
112              extents  (PEs). When the first PE is omitted, it defaults to the
113              start of the device, and when the last PE is omitted it defaults
114              to  end.   Start and end range (inclusive): PV[:PE-PE]...  Start
115              and length range (counting from 0): PV[:PE+PE]...
116
117       String
118              See the option description for information about the string con‐
119              tent.
120
121       Size[UNIT]
122              Size  is  an  input number that accepts an optional unit.  Input
123              units are always treated as base two values, regardless of capi‐
124              talization,  e.g.  'k'  and 'K' both refer to 1024.  The default
125              input unit is specified by letter, followed by |UNIT.  UNIT rep‐
126              resents  other  possible  input units: bBsSkKmMgGtTpPeE.  b|B is
127              bytes, s|S is sectors of 512 bytes, k|K  is  kilobytes,  m|M  is
128              megabytes, g|G is gigabytes, t|T is terabytes, p|P is petabytes,
129              e|E is exabytes.  (This should not be confused with  the  output
130              control --units, where capital letters mean multiple of 1000.)
131

ENVIRONMENT VARIABLES

133       See  lvm(8)  for  information  about environment variables used by lvm.
134       For example, LVM_VG_NAME can generally be substituted for a required VG
135       parameter.
136

NOTES

138       pvresize  will refuse to shrink a PV if it has allocated extents beyond
139       the new end.
140

EXAMPLES

142       Expand a PV after enlarging the partition.
143       pvresize /dev/sda1
144
145       Shrink a PV prior to shrinking the partition (ensure that the  PV  size
146       is appropriate for the intended new partition size).
147       pvresize --setphysicalvolumesize 40G /dev/sda1
148

SEE ALSO

150       lvm(8) lvm.conf(5) lvmconfig(8)
151
152       pvchange(8)  pvck(8)  pvcreate(8)  pvdisplay(8)  pvmove(8)  pvremove(8)
153       pvresize(8) pvs(8) pvscan(8)
154
155       vgcfgbackup(8) vgcfgrestore(8) vgchange(8) vgck(8)  vgcreate(8)  vgcon‐
156       vert(8)  vgdisplay(8)  vgexport(8)  vgextend(8)  vgimport(8)  vgimport‐
157       clone(8) vgmerge(8) vgmknodes(8)  vgreduce(8)  vgremove(8)  vgrename(8)
158       vgs(8) vgscan(8) vgsplit(8)
159
160       lvcreate(8)  lvchange(8)  lvconvert(8)  lvdisplay(8)  lvextend(8) lvre‐
161       duce(8) lvremove(8) lvrename(8) lvresize(8) lvs(8) lvscan(8)
162
163       lvm-fullreport(8) lvm-lvpoll(8) lvm2-activation-generator(8) blkdeacti‐
164       vate(8) lvmdump(8)
165
166       dmeventd(8)  lvmetad(8)  lvmpolld(8) lvmlockd(8) lvmlockctl(8) clvmd(8)
167       cmirrord(8) lvmdbusd(8)
168
169       lvmsystemid(7) lvmreport(7) lvmraid(7) lvmthin(7) lvmcache(7)
170
171
172
173Red Hat, Inc.      LVM TOOLS 2.02.180(2)-RHEL7 (2018-07-20)        PVRESIZE(8)
Impressum