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

NAME

6       lvscan — List all logical volumes in all volume groups
7

SYNOPSIS

9       lvscan
10           [ option_args ]
11

DESCRIPTION

13       lvscan  scans  all VGs or all supported LVM block devices in the system
14       for LVs. The output consists of one line for each LV indicating whether
15       or  not  it is active, a snapshot or origin, the size of the device and
16       its allocation policy. Use lvs(8) or lvdisplay(8) to obtain  more  com‐
17       prehensive information about LVs.
18

USAGE

20       lvscan
21           [ -a|--all ]
22           [ -b|--blockdevice ]
23           [    --ignorelockingfailure ]
24           [    --readonly ]
25           [    --reportformat basic|json|json_std ]
26           [ COMMON_OPTIONS ]
27
28       Common options for lvm:
29           [ -d|--debug ]
30           [ -h|--help ]
31           [ -q|--quiet ]
32           [ -t|--test ]
33           [ -v|--verbose ]
34           [ -y|--yes ]
35           [    --commandprofile String ]
36           [    --config String ]
37           [    --devices PV ]
38           [    --devicesfile String ]
39           [    --driverloaded y|n ]
40           [    --journal String ]
41           [    --lockopt String ]
42           [    --longhelp ]
43           [    --nohints ]
44           [    --nolocking ]
45           [    --profile String ]
46           [    --version ]
47

OPTIONS

49       -a|--all
50              Show  information  about  internal LVs.  These are components of
51              normal LVs, such as mirrors, which are not independently  acces‐
52              sible, e.g. not mountable.
53
54       -b|--blockdevice
55              No longer used.
56
57       --commandprofile String
58              The  command  profile  to  use  for  command configuration.  See
59              lvm.conf(5) for more information about profiles.
60
61       --config String
62              Config settings for the command. These override lvm.conf(5) set‐
63              tings.   The  String arg uses the same format as lvm.conf(5), or
64              may use section/field syntax.  See lvm.conf(5) for more informa‐
65              tion about config.
66
67       -d|--debug ...
68              Set debug level. Repeat from 1 to 6 times to increase the detail
69              of messages sent to the log file and/or syslog (if configured).
70
71       --devices PV
72              Restricts the devices that are visible  and  accessible  to  the
73              command.  Devices not listed will appear to be missing. This op‐
74              tion can be repeated, or accepts a comma separated list  of  de‐
75              vices. This overrides the devices file.
76
77       --devicesfile String
78              A file listing devices that LVM should use.  The file must exist
79              in /etc/lvm/devices/ and is managed with the lvmdevices(8)  com‐
80              mand.   This  overrides  the lvm.conf(5) devices/devicesfile and
81              devices/use_devicesfile settings.
82
83       --driverloaded y|n
84              If set to no, the command will not attempt to use device-mapper.
85              For testing and debugging.
86
87       -h|--help
88              Display help text.
89
90       --ignorelockingfailure
91              Allows  a command to continue with read-only metadata operations
92              after locking failures.
93
94       --journal String
95              Record information in the systemd journal.  This information  is
96              in  addition  to information enabled by the lvm.conf log/journal
97              setting.  command: record information about the  command.   out‐
98              put: record the default command output.  debug: record full com‐
99              mand debugging.
100
101       --lockopt String
102              Used to pass options for special cases to  lvmlockd.   See  lvm‐
103              lockd(8) for more information.
104
105       --longhelp
106              Display long help text.
107
108       --nohints
109              Do  not  use the hints file to locate devices for PVs. A command
110              may read more devices to find PVs when hints are not  used.  The
111              command will still perform standard hint file invalidation where
112              appropriate.
113
114       --nolocking
115              Disable locking. Use with caution, concurrent commands may  pro‐
116              duce incorrect results.
117
118       --profile String
119              An alias for --commandprofile or --metadataprofile, depending on
120              the command.
121
122       -q|--quiet ...
123              Suppress output and log messages. Overrides --debug  and  --ver‐
124              bose.   Repeat  once  to  also  suppress any prompts with answer
125              'no'.
126
127       --readonly
128              Run the command in a special read-only mode which will read  on-
129              disk  metadata  without  needing  to take any locks. This can be
130              used to peek inside metadata used by  a  virtual  machine  image
131              while the virtual machine is running. No attempt will be made to
132              communicate with the device-mapper kernel driver, so this option
133              is unable to report whether or not LVs are actually in use.
134
135       --reportformat basic|json|json_std
136              Overrides  current  output  format  for reports which is defined
137              globally by the  report/output_format  setting  in  lvm.conf(5).
138              basic is the original format with columns and rows.  If there is
139              more than one report per command, each report is  prefixed  with
140              the  report name for identification. json produces report output
141              in JSON format. json_std produces report output in  JSON  format
142              which  is  more  compliant with JSON standard.  See lvmreport(7)
143              for more information.
144
145       -t|--test
146              Run in test mode. Commands will not update  metadata.   This  is
147              implemented  by  disabling all metadata writing but nevertheless
148              returning success to the calling function. This may lead to  un‐
149              usual  error messages in multi-stage operations if a tool relies
150              on reading back metadata it believes has changed but hasn't.
151
152       -v|--verbose ...
153              Set verbose level. Repeat from 1 to 4 times to increase the  de‐
154              tail of messages sent to stdout and stderr.
155
156       --version
157              Display version information.
158
159       -y|--yes
160              Do  not  prompt for confirmation interactively but always assume
161              the answer yes. Use with extreme caution.   (For  automatic  no,
162              see -qq.)
163

VARIABLES

165       String See the option description for information about the string con‐
166              tent.
167
168       Size[UNIT]
169              Size is an input number that accepts an  optional  unit.   Input
170              units are always treated as base two values, regardless of capi‐
171              talization, e.g. 'k' and 'K' both refer to  1024.   The  default
172              input unit is specified by letter, followed by |UNIT.  UNIT rep‐
173              resents other possible input units: b|B is bytes, s|S is sectors
174              of  512  bytes,  k|K is KiB, m|M is MiB, g|G is GiB, t|T is TiB,
175              p|P is PiB, e|E is EiB.  (This should not be confused  with  the
176              output  control  --units, where capital letters mean multiple of
177              1000.)
178

ENVIRONMENT VARIABLES

180       See lvm(8) for information about environment  variables  used  by  lvm.
181       For example, LVM_VG_NAME can generally be substituted for a required VG
182       parameter.
183

SEE ALSO

185       lvm(8), lvm.conf(5), lvmconfig(8), lvmdevices(8),
186
187       pvchange(8), pvck(8), pvcreate(8), pvdisplay(8), pvmove(8),
188       pvremove(8), pvresize(8), pvs(8), pvscan(8),
189
190       vgcfgbackup(8), vgcfgrestore(8), vgchange(8), vgck(8), vgcreate(8),
191       vgconvert(8), vgdisplay(8), vgexport(8), vgextend(8), vgimport(8),
192       vgimportclone(8), vgimportdevices(8), vgmerge(8), vgmknodes(8),
193       vgreduce(8), vgremove(8), vgrename(8), vgs(8), vgscan(8), vgsplit(8),
194
195       lvcreate(8), lvchange(8), lvconvert(8), lvdisplay(8), lvextend(8),
196       lvreduce(8), lvremove(8), lvrename(8), lvresize(8), lvs(8), lvscan(8),
197
198       lvm-fullreport(8), lvm-lvpoll(8), blkdeactivate(8), lvmdump(8),
199
200       dmeventd(8), lvmpolld(8), lvmlockd(8), lvmlockctl(8), cmirrord(8),
201       lvmdbusd(8), fsadm(8),
202
203       lvmsystemid(7), lvmreport(7), lvmcache(7), lvmraid(7), lvmthin(7),
204       lvmvdo(7), lvmautoactivation(7)
205
206
207
208
209Red Hat, Inc.          LVM TOOLS 2.03.22(2) (2023-08-02)             LVSCAN(8)
Impressum