LVM-ARGS(7)

πŸ’– LVM-ARGS πŸ’–

okay so bestie, welcome to the LVM command arguments reference πŸŽ€ this is a page from the Miscellaneous Information Manual (that's section 7, iykyk) and it's basically the master list of every single argument LVM commands understand, plus exactly which commands will actually listen to each one. huge page energy. grab a snack. πŸ“


✨ NAME ✨

lvm-args β€” LVM command arguments reference


🌸 DESCRIPTION 🌸

This page is the full, comprehensive, no-skips list of all LVM command arguments, and it shows you which commands accept each argument. that's it, that's the page, and it's lowkey iconic for it. πŸ’…


πŸ‘‘ ARGUMENTS πŸ‘‘

every entry below tells you what the argument does and then which commands use it. no cap, we're going through all of them. 🌈
  • --abort β€” Used by: lvpoll, pvmove
  • -a, --activate y|n|ay β€” Used by: lvchange, lvcreate, pvscan, vgchange
  • --activationmode partial|degraded|complete β€” decides whether an LV is even allowed to activate when some of its PVs are missing, like if a device died on you 😭. complete is the strictest of the strict β€” only LVs with zero missing PVs may activate. degraded lets RAID LVs with missing PVs activate (and no, that does not include the "mirror" type β€” look at "raid1" instead, bestie). partial lets any LV with missing PVs activate, and honestly it should only be used for recovery or repair, so like 🚨 emergency use only 🚨. for the default, go see lvm.conf(5) activation_mode. more info lives in lvmraid(7). Used by: lvchange, vgchange
  • -A, --activevolumegroups β€” only select active VGs. a VG counts as active if at least one of its LVs is active. slay. Used by: vgdisplay
  • --adddev PV β€” add a device to the devices file. Used by: lvmdevices
  • --addid String β€” hunt down the device with the given device_id and add it to the devices file. Used by: lvmdevices
  • --addpvid String β€” hunt down a device by its PVID and add that device to the devices file. Used by: lvmdevices
  • --addtag Tag β€” adds a tag to a PV, VG or LV. you can repeat this option to add multiple tags in one go. see lvm(8) for the whole deal about tags. ✨ Used by: lvchange, lvcreate, pvchange, vgchange, vgcreate
  • --aligned β€” use this with --separator to align the output columns. aesthetic ✨ Used by: devtypes, fullreport, lvdisplay, lvs, pvdisplay, pvs, vgdisplay, vgs
  • -a, --all β€” Used by: fullreport, lvdisplay, lvs, lvscan, pvchange, pvdisplay, pvs, vgdisplay, vgexport, vgimport, vgimportdevices, vgreduce, vgs
  • --alloc contiguous|cling|cling_by_tags|normal|anywhere|inherit β€” sets the allocation policy for when a command needs to grab Physical Extents (PEs) out of the VG. every VG and LV has an allocation policy, and you can change it with vgchange/lvchange or override it right there on the command line. here's the tea:
    • normal applies the common-sense rules, like not putting parallel stripes on the same PV (rude of you honestly).
    • inherit just applies the VG policy to the LV.
    • contiguous requires new PEs to sit right next to existing PEs.
    • cling places new PEs on the same PV as existing PEs in the same stripe of the LV.
    • if there are enough PEs for an allocation but normal refuses to use them, anywhere will use them anyway β€” even if it tanks performance, e.g. by stacking two stripes on the same PV. πŸ’€
    • optional positional PV args on the command line can also limit which PVs the command is allowed to use for allocation. see lvm(8) for more about allocation. Used by: lvchange, lvconvert, lvcreate, lvextend, lvresize, pvmove, vgchange, vgcreate, vgsplit
  • -x, --allocatable y|n β€” turn allocation of physical extents on or off for this PV. simple as. Used by: pvchange
  • -A, --allpvs β€” Used by: pvs, pvscan
  • --atomic β€” makes a pvmove operation atomic: either all affected LVs get moved to the destination PV, or none of them do if the operation gets aborted. all or nothing, periodt. Used by: pvmove
  • --atversion String β€” give an LVM version in x.y.z format, where x is the major version, y is the minor version and z is the patchlevel (for example 2.2.106). when configuration is displayed, only the configuration settings recognized at that LVM version get considered. this is how you show a config that a specific LVM version actually understands, one that doesn't contain any shiny newer settings that would make LVM send you a warning message while checking the config. πŸ•°οΈ Used by: config, dumpconfig, lvmconfig
  • --auto β€” this one is used when automatically importing devices for the root VG. the auto import is meant to happen once, on first boot, to create the initial system.devices file for the root VG. when this option is used, the vgimportdevices --rootvg command does nothing if system.devices exists, or if the file auto-import-rootvg does not exist (both of those live in the /etc/lvm/devices/ directory). Used by: vgimportdevices
  • --autoactivation String β€” say whether autoactivation is being used from an event. this lets the command apply settings specific to event activation, like device scanning optimizations using pvs_online files created by event-based pvscans. Used by: pvscan, vgchange
  • -A, --autobackup y|n β€” says whether metadata should get backed up automatically after a change. please enable this, it is strongly advised!! 🫢 see vgcfgbackup(8) for more info. Used by: lvchange, lvcreate, lvextend, lvpoll, lvreduce, lvremove, lvrename, lvresize, pvchange, pvmove, pvresize, vgchange, vgcreate, vgextend, vgmerge, vgreduce, vgrename, vgsplit
  • -b, --background β€” if the operation needs polling, this option makes the command return before the operation finishes, and the polling happens in the background. go do your thing, we'll catch up. πŸ¦‹ Used by: lvconvert, pvmove
  • -n, --basevgname String β€” by default the snapshot VG gets renamed to the original name plus a numeric suffix, so you don't get duplicate names (e.g. test_vg would become test_vg1). this option overrides the base VG name used for all VG renames. if a VG already exists with the name you asked for, a numeric suffix gets added (like the previous example) to keep it unique. Used by: vgimportclone
  • --binary β€” use binary values "0" or "1" instead of descriptive literal values, for columns that have exactly two valid values to report. (this doesn't count the "unknown" value, which means the value couldn't be determined at all. 😭) Used by: devtypes, fullreport, lvdisplay, lvs, pvdisplay, pvs, vgdisplay, vgs
  • --bootloaderareasize Size[m|UNIT] β€” reserve space for the bootloader between the LVM metadata area and the first PE. the bootloader area is reserved so bootloaders can embed their own data or metadata; LVM itself will not use it. the bootloader area begins where the first PE would otherwise have been. the first PE gets moved out by the size of the bootloader area, and then moved out further if needed to match the data alignment. the start of the bootloader area is always aligned β€” see also --dataalignment and --dataalignmentoffset. the bootloader area may end up larger than you requested because of that alignment, but it's never less than the requested size. to see the bootloader area start and size of an existing PV, run pvs -o +pv_ba_start,pv_ba_size. πŸ“ Used by: pvcreate, vgconvert
  • --cache β€” Used by: pvscan
  • -H, --cache β€” says the command is handling a cache LV or cache pool. see --type cache and --type cache-pool. see lvmcache(7) for more about LVM caching. Used by: lvconvert, lvcreate
  • --cachedevice PV β€” the name of a device to use for a cache. Used by: lvconvert, lvcreate
  • --cachemetadataformat auto|1|2 β€” specifies the cache metadata format used by the cache target. Used by: lvconvert, lvcreate
  • --cachemode writethrough|writeback|passthrough β€” specifies when writes to a cache LV should be considered complete:
    • writeback considers a write complete as soon as it's stored in the cache pool.
    • writethrough only considers a write complete once it's been stored in both the cache pool and on the origin LV. it may be slower for writes, but it's more resilient if something should happen to a device associated with the cache pool LV. πŸ›Ÿ
    • with passthrough, all reads are served from the origin LV (all reads miss the cache) and all writes are forwarded to the origin LV; plus, write hits cause cache block invalidates. see lvmcache(7) for more information. Used by: lvchange, lvconvert, lvcreate
  • --cachepolicy String β€” specifies the cache policy for a cache LV. see lvmcache(7) for more information. Used by: lvchange, lvconvert, lvcreate
  • --cachepool LV β€” the name of a cache pool. Used by: lvconvert, lvcreate
  • --cachesettings String β€” specifies tunable kernel options for dm-cache or dm-writecache LVs. use the form option=value or option1=value option2=value, or just repeat --cachesettings once for each option you're setting. these settings override the default kernel behaviors, which are usually perfectly adequate. to remove cachesettings and go back to the default kernel behaviors, use --cachesettings 'default' for dm-cache, or an empty string --cachesettings '' for dm-writecache. see lvmcache(7) for more information. Used by: lvchange, lvconvert, lvcreate
  • --cachesize Size[m|UNIT] β€” the size of cache to use. Used by: lvconvert, lvcreate
  • --cachevol LV β€” the name of a cache volume. Used by: lvconvert, lvcreate
  • --check β€” checks the content of the devices file. reports incorrect device names or PVIDs for entries. πŸ” Used by: lvmdevices
  • --checkcomplete β€” check whether all the devices used by a VG or LV are present, and print "complete" or "incomplete" for each listed VG or LV. this option is used as part of event-based autoactivation, so pvscan will do nothing if this option is set and event_activation=0 in the config settings. noted! Used by: pvscan

okay that's the first chunk bestie, and there is so much more coming β€” don't go anywhere πŸ’œ

  • -c, --chunksize Size[k|UNIT] β€” how big the chunks are in a snapshot, a cache pool, or a thin pool, bestie. For snapshots the value has to be a power of 2 between 4 KiB and 512 KiB, and the default value is 4. For a cache pool the value has to be between 32 KiB and 1 GiB and the default value is 64. For a thin pool the value has to be between 64 KiB and 1 GiB, and the default value starts with 64 and scales up to fit the pool metadata size within 128 MiB, if the pool metadata size is not specified β€” also the value must be a multiple of 64 KiB. Go read lvmthin(7) and lvmcache(7) for more, iykyk. πŸ‘‘
    • Used by: lvconvert, lvcreate
  • -c, --clustered y|n β€” okay so this one was specific to clvm and it's now replaced by the --shared option with lvmlockd(8). Old news, iconic history tho. πŸ’€
    • Used by: vgcreate
  • -c, --colon β€” gives you colon separated output so your scripts and programs can parse it way easier. it's giving machine-readable πŸ’…
    • Used by: lvdisplay, pvdisplay, vgdisplay
  • -C, --columns β€” displays the output in columns. neat, tidy, organized. πŸŽ€
    • Used by: lvdisplay, pvdisplay, vgdisplay
  • --commandprofile String β€” the command profile you want to use for command configuration. lvm.conf(5) has all the lore about profiles, fr fr.
    • Used by: config, devtypes, dumpconfig, formats, fullreport, help, lastlog, lvchange, lvconvert, lvcreate, lvdisplay, lvextend, lvmchange, lvmconfig, lvmdevices, lvmdiskscan, lvmsadc, lvmsar, lvpoll, lvreduce, lvremove, lvrename, lvresize, lvs, lvscan, pvchange, pvck, pvcreate, pvdata, pvdisplay, pvmove, pvremove, pvresize, pvs, pvscan, segtypes, systemid, tags, version, vgcfgbackup, vgcfgrestore, vgchange, vgck, vgconvert, vgcreate, vgdisplay, vgexport, vgextend, vgimport, vgimportclone, vgimportdevices, vgmerge, vgmknodes, vgreduce, vgremove, vgrename, vgs, vgscan, vgsplit
  • --compression y|n β€” controls whether compression is enabled or disabled for a VDO volume. lvmvdo(7) is where the VDO usage lore lives. πŸ”₯
    • Used by: lvchange, lvconvert, lvcreate
  • --config String β€” config settings for the command, and yes they override the lvm.conf(5) settings, no cap. The String arg uses the same format as lvm.conf(5), or you can use the section/field syntax. lvm.conf(5) explains config in full. ✨
    • Used by: config, devtypes, dumpconfig, formats, fullreport, help, lastlog, lvchange, lvconvert, lvcreate, lvdisplay, lvextend, lvmchange, lvmconfig, lvmdevices, lvmdiskscan, lvmsadc, lvmsar, lvpoll, lvreduce, lvremove, lvrename, lvresize, lvs, lvscan, pvchange, pvck, pvcreate, pvdata, pvdisplay, pvmove, pvremove, pvresize, pvs, pvscan, segtypes, systemid, tags, version, vgcfgbackup, vgcfgrestore, vgchange, vgck, vgconvert, vgcreate, vgdisplay, vgexport, vgextend, vgimport, vgimportclone, vgimportdevices, vgmerge, vgmknodes, vgreduce, vgremove, vgrename, vgs, vgscan, vgsplit
  • --configreport log|vg|lv|pv|pvseg|seg β€” go look at lvmreport(7), bestie. that's the whole vibe. πŸ¦‹
    • Used by: fullreport, lvdisplay, lvs, pvdisplay, pvs, vgdisplay, vgs
  • -C, --contiguous y|n β€” sets or resets the contiguous allocation policy for LVs. Default is no contiguous allocation, based on a next free principle. And heads up: it is only possible to change a non-contiguous allocation policy to contiguous if all of the allocated physical extents in the LV are already contiguous. like, the prerequisites are real. 😭
    • Used by: lvchange, lvcreate
  • --dataalignment Size[k|UNIT] β€” aligns the start of a PV data area with a multiple of this number. Wanna see where the first Physical Extent (PE) of an existing PV is? run pvs -o +pe_start. Also, it may be shifted by an alignment offset, see --dataalignmentoffset. And pls also specify an appropriate PE size when creating a VG. 🌸
    • Used by: pvcreate, vgcreate, vgextend
  • --dataalignmentoffset Size[k|UNIT] β€” shifts the start of the PV data area by this additional offset. just a lil nudge. 🫢
    • Used by: pvcreate, vgcreate, vgextend
  • -d, --debug β€” sets the debug level. Repeat it from 1 to 6 times to increase the detail of messages sent to the log file and/or syslog (if configured). the way that more -ds = more yapping πŸ’€
    • Used by: config, devtypes, dumpconfig, formats, fullreport, help, lastlog, lvchange, lvconvert, lvcreate, lvdisplay, lvextend, lvmchange, lvmconfig, lvmdevices, lvmdiskscan, lvmsadc, lvmsar, lvpoll, lvreduce, lvremove, lvrename, lvresize, lvs, lvscan, pvchange, pvck, pvcreate, pvdata, pvdisplay, pvmove, pvremove, pvresize, pvs, pvscan, segtypes, systemid, tags, version, vgcfgbackup, vgcfgrestore, vgchange, vgck, vgconvert, vgcreate, vgdisplay, vgexport, vgextend, vgimport, vgimportclone, vgimportdevices, vgmerge, vgmknodes, vgreduce, vgremove, vgrename, vgs, vgscan, vgsplit
  • --deduplication y|n β€” controls whether deduplication is enabled or disabled for a VDO volume. lvmvdo(7) has the VDO usage details. πŸ™ˆ
    • Used by: lvchange, lvconvert, lvcreate
  • --deldev String β€” removes a device from the devices file. When used alone, --deldev specifies a device name. When used with --deviceidtype, --deldev specifies a device id. two moods, one flag. πŸ’…
    • Used by: lvmdevices
  • --delid String β€” removes the device with the specified device ID from the devices file. bye bestie πŸ‘‹
    • Used by: lvmdevices
  • --delnotfound β€” removes devices file entries with no matching device. cleaning up the ghosted ones, periodt. 🧹
    • Used by: lvmdevices
  • --delpvid String β€” removes a device with the PVID from the devices file. πŸ’œ
    • Used by: lvmdevices
  • --deltag Tag β€” deletes a tag from a PV, VG or LV. You can repeat this option to delete multiple tags at once. lvm(8) has the tag lore.
    • Used by: lvchange, pvchange, vgchange
  • --detachprofile β€” detaches a metadata profile from a VG or LV. lvm.conf(5) has the profile lore. πŸŽ€
    • Used by: lvchange, vgchange
  • --deviceidtype String β€” the type of device ID to use for the device. If the specified type is available for the device, then it will override the default type that lvm would use. main character energy, it takes priority. πŸ‘‘
    • Used by: lvmdevices
  • --devices PV β€” restricts the devices that are visible and accessible to the command. Devices not listed will appear to be missing. This option can be repeated, or accepts a comma-separated list of devices. And this overrides the devices file, jsyk.
    • Used by: config, devtypes, dumpconfig, formats, fullreport, help, lastlog, lvchange, lvconvert, lvcreate, lvdisplay, lvextend, lvmchange, lvmconfig, lvmdevices, lvmdiskscan, lvmsadc, lvmsar, lvpoll, lvreduce, lvremove, lvrename, lvresize, lvs, lvscan, pvchange, pvck, pvcreate, pvdata, pvdisplay, pvmove, pvremove, pvresize, pvs, pvscan, segtypes, systemid, tags, version, vgcfgbackup, vgcfgrestore, vgchange, vgck, vgconvert, vgcreate, vgdisplay, vgexport, vgextend, vgimport, vgimportclone, vgimportdevices, vgmerge, vgmknodes, vgreduce, vgremove, vgrename, vgs, vgscan, vgsplit
  • --devicesfile String β€” a file listing devices that LVM should use. The file must exist in /etc/lvm/devices/ and is managed with the lvmdevices(8) command. This overrides the lvm.conf(5) devices/devicesfile and devices/use_devicesfile settings. ✨
    • Used by: config, devtypes, dumpconfig, formats, fullreport, help, lastlog, lvchange, lvconvert, lvcreate, lvdisplay, lvextend, lvmchange, lvmconfig, lvmdevices, lvmdiskscan, lvmsadc, lvmsar, lvpoll, lvreduce, lvremove, lvrename, lvresize, lvs, lvscan, pvchange, pvck, pvcreate, pvdata, pvdisplay, pvmove, pvremove, pvresize, pvs, pvscan, segtypes, systemid, tags, version, vgcfgbackup, vgcfgrestore, vgchange, vgck, vgconvert, vgcreate, vgdisplay, vgexport, vgextend, vgimport, vgimportclone, vgimportdevices, vgmerge, vgmknodes, vgreduce, vgremove, vgrename, vgs, vgscan, vgsplit
  • --discards passdown|nopassdown|ignore β€” specifies how the device-mapper thin pool layer in the kernel should handle discards. ignore causes the thin pool to ignore discards. nopassdown causes the thin pool to process discards itself to allow reuse of unneeded extents in the thin pool. passdown causes the thin pool to process discards itself (like nopassdown) and pass the discards to the underlying device. lvmthin(7) has more, bestie. 🌈
    • Used by: lvchange, lvconvert, lvcreate
  • --driverloaded y|n β€” if set to no, the command will not attempt to use device-mapper. For testing and debugging, not for real life. πŸ™ˆ
    • Used by: config, devtypes, dumpconfig, formats, fullreport, help, lastlog, lvchange, lvconvert, lvcreate, lvdisplay, lvextend, lvmchange, lvmconfig, lvmdevices, lvmdiskscan, lvmsadc, lvmsar, lvpoll, lvreduce, lvremove, lvrename, lvresize, lvs, lvscan, pvchange, pvck, pvcreate, pvdata, pvdisplay, pvmove, pvremove, pvresize, pvs, pvscan, segtypes, systemid, tags, version, vgcfgbackup, vgcfgrestore, vgchange, vgck, vgconvert, vgcreate, vgdisplay, vgexport, vgextend, vgimport, vgimportclone, vgimportdevices, vgmerge, vgmknodes, vgreduce, vgremove, vgrename, vgs, vgscan, vgsplit
  • --dump headers|metadata|metadata_all|metadata_search β€” dumps headers and metadata from a PV for debugging and repair. Option values include: headers to print and check LVM headers, metadata to print or save the current text metadata, metadata_all to list or save all versions of metadata, metadata_search to list or save all versions of metadata, searching standard locations in case of damaged headers, metadata_area to save an entire text metadata area to a file. lowkey detective work πŸ”
    • Used by: pvck
  • --edit String β€” edits or removes a setting in an LVM config file. The setting is specified as Section/Field=Value. To remove a setting, use Section/Field=-. Repeat this option to edit multiple settings. chef's kiss πŸ’…
    • Used by: dumpconfig, lvmconfig
  • --errorwhenfull y|n β€” ok so this is the thin pool ✨panic button✨ setting for when data space runs dry. Say yes: device-mapper pulls the plug immediately, returning an error the second a thin pool is full and an I/O request is out here needing space. Say no: device-mapper queues those I/O requests for a lil while so the thin pool has a chance to be extended, and only returns errors if there's still no space after the timeout runs out. (Also peep the dm_thin_pool kernel module option no_space_timeout.) Head to lvmthin(7) for the whole story.
    • Used by: lvchange, lvconvert, lvcreate
  • -e, --exported β€” only show you the PVs that belong to exported VGs. That's it bestie.
    • Used by: pvscan
  • -l, --extents Number[PERCENT] β€”
    • Used by: lvcreate, lvextend, lvreduce, lvresize
  • -f, --file String β€”
    • Used by: config, dumpconfig, lvmconfig, pvck, vgcfgbackup, vgcfgrestore
  • --force β€” forces a metadata restore even when thin pool LVs are in the mix. 🚨 Use with extreme caution. Most changes to thin metadata literally cannot be reverted. You may lose data if you restore metadata that doesn't match the thin pool kernel metadata precisely. Not a vibe, it's a warning.
    • Used by: vgcfgrestore
  • -f, --force β€” overrides a whole bunch of checks, confirmations and protections. 🚨 Use with extreme caution, fr fr.
    • Used by: lvchange, lvconvert, lvextend, lvmdevices, lvreduce, lvremove, lvresize, pvchange, pvcreate, pvremove, vgchange, vgconvert, vgcreate, vgextend, vgimport, vgreduce, vgremove, vgrename
  • --foreign β€” reports/displays foreign VGs that would otherwise get skipped. Peep lvmsystemid(7) for the tea on foreign VGs. πŸ‘‘
    • Used by: fullreport, lvdisplay, lvs, pvdisplay, pvs, vgcfgbackup, vgdisplay, vgimportdevices, vgs
  • --fs String β€” this one's your remote control for file system resizing when you're resizing an LV πŸ’…
    • checksize: check the fs size and reduce the LV if the fs isn't using the reduced space (fs reduce is not needed.) But if the reduced space is being used by the fs, then don't resize the fs or LV at all, and return an error. (Heads up: checksize only applies when reducing, and does absolutely nothing for extend.)
    • resize: resize the fs by calling the fs-specific resize command. This may also include mounting, unmounting, or running fsck. See --fsmode to control mounting behavior, and --nofsck to disable fsck.
    • resize_fsadm: use the old method of calling fsadm to handle the fs (deprecated.) ⚠️ Warning: this option does not prevent lvreduce from destroying file systems that are unmounted (or mounted if prompts are skipped.)
    • ignore: resize the LV without checking for or handling a file system. ⚠️ Warning: using ignore when reducing the LV size may destroy the file system. 😭
Note: if you're resizing an LV with no file system and the new LV size matches the existing size, the command returns a non-zero status code (failure). BUT if a file system resize is also requested along with the LV resize, and the sizes already match, the command returns a zero status code (success). Why? Because the external commands called to resize the file system return success even when the new and old file system sizes are identical. LVM follows the command status code behavior in this scenario. Make it make sense, we don't make the rules 🀷
  • Used by: lvextend, lvreduce, lvresize
  • --fsmode String β€” controls file system mounting behavior for fs resize πŸŽ€
    • manage: mount or unmount the fs as needed to resize the fs, and try to restore the original mount state at the end.
    • nochange: do not mount or unmount the fs. If mounting or unmounting is required to resize the fs, then don't resize the fs or the LV and fail the command.
    • offline: unmount the fs if it's mounted, and resize the fs while it's unmounted. If mounting is required to resize the fs, then don't resize the fs or the LV and fail the command.
    • Used by: lvextend, lvreduce, lvresize
  • -f, --full β€”
    • Used by: lvmsar
  • --handlemissingpvs β€” lets a polling operation keep going even when PVs are missing, e.g. for repairs after faulty devices. Keep it pushing πŸ’ͺ
    • Used by: lvpoll
  • --headings none|abbrev|full|0|1|2 β€” picks what kind of headings show up in report output.
    • none or 0: no headings at all.
    • abbrev or 1: column name abbreviations.
    • full or 2: full column names.
    • Used by: fullreport, lvdisplay, lvs, pvdisplay, pvs, vgdisplay, vgs
  • -h, --help β€” displays help text. The og bestie move 🫢
    • Used by: config, devtypes, dumpconfig, formats, fullreport, help, lastlog, lvchange, lvconvert, lvcreate, lvdisplay, lvextend, lvmchange, lvmconfig, lvmdevices, lvmdiskscan, lvmsadc, lvmsar, lvpoll, lvreduce, lvremove, lvrename, lvresize, lvs, lvscan, pvchange, pvck, pvcreate, pvdata, pvdisplay, pvmove, pvremove, pvresize, pvs, pvscan, segtypes, systemid, tags, version, vgcfgbackup, vgcfgrestore, vgchange, vgck, vgconvert, vgcreate, vgdisplay, vgexport, vgextend, vgimport, vgimportclone, vgimportdevices, vgmerge, vgmknodes, vgreduce, vgremove, vgrename, vgs, vgscan, vgsplit
  • -H, --history β€” includes historical LVs in the output ✨ (this has no effect unless LVs were removed while lvm.conf(5) metadata/record_lvs_history was enabled.)
    • Used by: lvdisplay, lvs
  • -K, --ignoreactivationskip β€” ignores the "activation skip" LV flag during activation, so LVs that have the flag set can still be activated. Iconic.
    • Used by: lvchange, lvcreate, vgchange
  • --ignoreadvanced β€” keeps advanced configuration settings out of the output.
    • Used by: config, dumpconfig, lvmconfig
  • --ignorelocal β€” ignores the local section. The local section should be defined in the lvmlocal.conf file, and it should contain config settings specific to the local host that should not get copied to other hosts.
    • Used by: config, dumpconfig, lvmconfig
  • --ignorelockingfailure β€” lets a command keep going with read-only metadata operations after locking failures.
    • Used by: fullreport, lvchange, lvdisplay, lvs, lvscan, pvdisplay, pvs, pvscan, vgcfgbackup, vgchange, vgdisplay, vgmknodes, vgs, vgscan
  • --ignoremonitoring β€” do not interact with dmeventd unless --monitor is specified. Do not use this if dmeventd is already monitoring a device. ⚠️
    • Used by: lvchange, lvcreate, vgchange
  • --ignoreunsupported β€” keeps unsupported configuration settings out of the output. These settings are either for debugging and development purposes only, or their support isn't complete yet and they're not meant to be used in production. The current and diff types include unsupported settings in their output by default; all the other types ignore unsupported settings.
    • Used by: config, dumpconfig, lvmconfig
  • -i, --import β€” imports exported VGs. Otherwise VGs that have been exported won't be changed (nor will their associated PVs).
    • Used by: vgimportclone
  • --importdevices β€” adds devices to the devices file.
    • Used by: vgimportclone
  • --input String β€” reads configuration from the specified input file.
    • Used by: dumpconfig, lvmconfig
  • --integritysettings String β€” specifies tunable kernel options for dm-integrity. Check lvmraid(7) for more. πŸ”₯
    • Used by: lvchange, lvconvert, lvcreate
  • -i, --interval [+]Number β€” reports progress at regular intervals. With a + prefix, the first check is delayed by the given number of seconds, which lets background operations start before polling begins. So polite of it.
    • Used by: lvconvert, lvpoll, pvmove
  • --journal String β€” records information in the systemd journal πŸ““. This information is in addition to information enabled by the lvm.conf log/journal setting.
    • command: record information about the command.
    • output: record the default command output.
    • debug: record full command debugging.
    • Used by: config, devtypes, dumpconfig, formats, fullreport, help, lastlog, lvchange, lvconvert, lvcreate, lvdisplay, lvextend, lvmchange, lvmconfig, lvmdevices, lvmdiskscan, lvmsadc, lvmsar, lvpoll, lvreduce, lvremove, lvrename, lvresize, lvs, lvscan, pvchange, pvck, pvcreate, pvdata, pvdisplay, pvmove, pvremove, pvresize, pvs, pvscan, segtypes, systemid, tags, version, vgcfgbackup, vgcfgrestore, vgchange, vgck, vgconvert, vgcreate, vgdisplay, vgexport, vgextend, vgimport, vgimportclone, vgimportdevices, vgmerge, vgmknodes, vgreduce, vgremove, vgrename, vgs, vgscan, vgsplit
  • --labelsector Number β€” by default the PV gets labelled with an LVM2 identifier in its second sector (sector 1). This option lets you use a different sector near the start of the disk (between 0 and 3 inclusive β€” see LABEL_SCAN_SECTORS in the source). Use with care. πŸ™ˆ
    • Used by: pvck, pvcreate, vgconvert, vgcreate, vgextend
  • -l, --list β€”
    • Used by: config, dumpconfig, lvmconfig, vgcfgrestore, vgmerge
  • --listids PV β€” prints a list of device IDs available for the device.
    • Used by: lvmdevices
  • --listlvs β€” prints a list of LVs that use the device.
    • Used by: pvscan
  • --listvg β€” prints the VG that uses the device.
    • Used by: pvscan
  • --lockopt String β€” used to pass options for special cases to lvmlockd. See lvmlockd(8) for more.
    • Used by: config, devtypes, dumpconfig, formats, fullreport, help, lastlog, lvchange, lvconvert, lvcreate, lvdisplay, lvextend, lvmchange, lvmconfig, lvmdevices, lvmdiskscan, lvmsadc, lvmsar, lvpoll, lvreduce, lvremove, lvrename, lvresize, lvs, lvscan, pvchange, pvck, pvcreate, pvdata, pvdisplay, pvmove, pvremove, pvresize, pvs, pvscan, segtypes, systemid, tags, version, vgcfgbackup, vgcfgrestore, vgchange, vgck, vgconvert, vgcreate, vgdisplay, vgexport, vgextend, vgimport, vgimportclone, vgimportdevices, vgmerge, vgmknodes, vgreduce, vgremove, vgrename, vgs, vgscan, vgsplit
  • --lockstart β€” starts the lockspace of a shared VG in lvmlockd πŸ”. lvmlockd locks become available for the VG, allowing LVM to use the VG. See lvmlockd(8) for more.
    • Used by: vgchange
  • --lockstop β€” bestie this one stops the lockspace of a shared VG inside lvmlockd. πŸ’€ After that, the lvmlockd locks are just... gone for that VG, so LVM can't use the VG at all. Peep lvmlockd(8) for the full tea. πŸ«–
    • Used by: vgchange
  • --locktype none β€” that's it, that's the option, none is the vibe πŸ’…
    • Used by: vgchange, vgcreate
  • -l|--logicalvolume Number β€” sets the max number of LVs you're allowed to have in a VG. ✨
    • Used by: vgchange
  • --logonly β€” suppresses the command report and shows you only the log report, nothing else, no extra noise, we're being minimal πŸŽ€
    • Used by: fullreport, lvdisplay, lvs, pvdisplay, pvs, vgdisplay, vgs
  • --longhelp β€” drop the long help text 🌈 like the whole essay, not just the summary bestie
    • Used by: config, devtypes, dumpconfig, formats, fullreport, help, lastlog, lvchange, lvconvert, lvcreate, lvdisplay, lvextend, lvmchange, lvmconfig, lvmdevices, lvmdiskscan, lvmsadc, lvmsar, lvpoll, lvreduce, lvremove, lvrename, lvresize, lvs, lvscan, pvchange, pvck, pvcreate, pvdata, pvdisplay, pvmove, pvremove, pvresize, pvs, pvscan, segtypes, systemid, tags, version, vgcfgbackup, vgcfgrestore, vgchange, vgck, vgconvert, vgcreate, vgdisplay, vgexport, vgextend, vgimport, vgimportclone, vgimportdevices, vgmerge, vgmknodes, vgreduce, vgremove, vgrename, vgs, vgscan, vgsplit
  • -l|--lvmpartition β€” only reports PVs, that's the whole job 🫢
    • Used by: lvmdiskscan
  • -j|--major Number β€” takes a Number, iconic, no notes πŸ’œ
    • Used by: lvchange, lvcreate, pvscan
  • --majoritypvs β€” changes the VG system ID only if the majority of PVs in the VG are actually present (that's one more than half, math besties πŸ“).
    • Used by: vgchange
  • -m|--maps β€” the maps era πŸ—ΊοΈ
    • Used by: lvdisplay, pvdisplay
  • -l|--maxlogicalvolumes Number β€” sets the max number of LVs allowed in a VG.
    • Used by: vgcreate, vgsplit
  • -p|--maxphysicalvolumes Number β€” caps the max number of PVs that can belong to the VG. Set it to 0 and the limitation is poof β€” gone, no limit, unlimited, main character energy πŸ‘‘. And if you're working with a whole lot of PVs, go look at --pvmetadatacopies and --vgmetadatacopies too, they help with performance fr fr.
    • Used by: vgchange, vgcreate, vgsplit
  • --[raid]maxrecoveryrate Size[k|UNIT] β€” sets the maximum recovery rate for a RAID LV. The rate value is an amount of data per second for each device in the array. Set the rate to 0 and it's unbounded 😳. lvmraid(7) has the lore.
    • Used by: lvchange, lvcreate
  • --merge β€” literally just an alias for --mergethin, --mergemirrors, or --mergesnapshot, and it picks which one based on the type of LV. It's giving "one option to rule them all" πŸ’…
    • Used by: lvconvert
  • --mergedconfig β€” ok so when you run the command with --config and/or --commandprofile (or you're using the LVM_COMMAND_PROFILE environment variable), --profile, or --metadataprofile, this merges all the contents of the "config cascade" before displaying it. Without merging? You only see the config sitting at the front of the cascade, that's it. lvm.conf(5) explains config if you need the deep dive. ✨
    • Used by: config, dumpconfig, lvmconfig
  • --mergemirrors β€” merges LV images that got split off from a raid1 LV. Go read --splitmirrors with --trackchanges, they're a duo 🫢
    • Used by: lvconvert
  • --mergesnapshot β€” merges a COW snapshot LV into its origin. Here's the whole situation bestie: when you merge a snapshot, if both the origin and the snapshot LVs are not open, the merge starts immediately. Otherwise? The merge kicks off the first time either the origin or the snapshot LV are activated and both are closed. And if you're merging a snapshot into an origin that cannot be closed β€” say, a root filesystem β€” that whole thing gets deferred until the next time the origin volume is activated. 😭 When merging starts, the resulting LV gets the origin's name, minor number and UUID. While the merge is in progress, reads or writes to the origin appear as being directed to the snapshot being merged. When the merge finishes, the merged snapshot is removed, bye πŸ’€. You can specify multiple snapshots on the command line, or use an @tag to specify multiple snapshots be merged to their respective origin. πŸ‘‘
    • Used by: lvconvert
  • --mergethin β€” merges a thin LV into its origin LV. The origin thin LV takes on the content of the thin snapshot, and then the thin snapshot LV gets removed. lvmthin(7) for more. πŸ¦‹
    • Used by: lvconvert
  • --metadataignore y|n β€” sets the metadataignore property of a PV. Say yes and the metadata areas on that PV get ignored β€” lvm won't store metadata in the metadata areas of the PV. Say no and lvm will store metadata on the PV.
    • Used by: pvchange, pvcreate, vgextend
  • --metadataprofile String β€” the metadata profile to use for command configuration. lvm.conf(5) has more about profiles. πŸŽ€
    • Used by: config, dumpconfig, lvchange, lvconvert, lvcreate, lvmconfig, vgchange, vgcreate
  • --metadatasize Size[m|UNIT] β€” the approximate amount of space used for each VG metadata area. Ngl the size may get rounded. πŸ€·β€β™€οΈ
    • Used by: pvcreate, vgconvert, vgcreate, vgextend
  • -M|--metadatatype lvm2 β€” specifies the type of on-disk metadata to use. lvm2 (or just 2) is the current, standard format, the moment ✨. lvm1 (or just 1) is no longer used, it's giving retired.
    • Used by: pvcreate, vgcfgrestore, vgconvert, vgcreate, vgextend, vgsplit
  • --minor Number β€” it takes the Number, cute, mysterious πŸ’œ
    • Used by: lvchange, lvcreate, pvscan
  • --[raid]minrecoveryrate Size[k|UNIT] β€” sets the minimum recovery rate for a RAID LV. The rate value is an amount of data per second for each device in the array. Rate 0 means it'll be unbounded. lvmraid(7), as always, has the info. 🌸
    • Used by: lvchange, lvcreate
  • --mirrorlog core|disk β€” picks the type of mirror log for LVs with the "mirror" type (and nope, it does not apply to the "raid1" type). 🚫 disk is a persistent log and it needs a small amount of storage space, usually on a separate device from the data being mirrored. core is not persistent β€” the log lives only in memory. In that case the mirror must be synchronized (copying LV data from the first device to the others) every single time the LV is activated, e.g. after reboot. 😭 mirrored is a persistent log that is itself mirrored, but should be avoided. Instead, use the raid1 type for log redundancy, periodt. πŸ’…
    • Used by: lvconvert, lvcreate
  • -m|--mirrors Number β€” the mirror count, that's the whole thing πŸͺž
    • Used by: lvconvert, lvcreate, lvextend
  • --mirrorsonly β€” only removes missing PVs from mirror LVs. Only those. Nothing else.
    • Used by: vgreduce
  • --mknodes β€” also checks the LVM special files in /dev that are needed for active LVs, and creates any missing ones and removes unused ones. πŸ› οΈ Also check out the additional --refresh option for use in a udev environment.
    • Used by: vgscan
  • --monitor y|n β€” start (yes) or stop (no) monitoring an LV with dmeventd. dmeventd watches kernel events for an LV and does automated maintenance for the LV in response to specific events, like it's literally the LV's manager. See dmeventd(8) for more. πŸ‘€
    • Used by: lvchange, lvcreate, vgchange
  • -n|--name String β€” you guessed it, it's the name πŸŽ€
    • Used by: lvconvert, lvcreate, pvmove, vgsplit
  • --nameprefixes β€” adds an "LVM2_" prefix plus the field name to the output. Super useful with --noheadings to produce a list of field=value pairs that can be used to set environment variables (for example, in udev rules). ✨
    • Used by: devtypes, fullreport, lvdisplay, lvs, pvdisplay, pvs, vgdisplay, vgs
  • -n|--nofsck β€” do not perform fsck when resizing the file system with --resizefs. Don't do it bestie πŸ™ˆ
    • Used by: lvextend, lvreduce, lvresize
  • --noheadings β€” suppresses the headings line that's normally the first line of output. Iconic if you're grepping the output. πŸ”
    • Used by: devtypes, fullreport, lvdisplay, lvs, pvdisplay, pvs, vgdisplay, vgs
  • --nohints β€” do not use the hints file to locate devices for PVs. Heads up: a command may read more devices to find PVs when hints aren't used. The command will still perform standard hint file invalidation where appropriate though, so it's not fully off the grid. 🧚
    • Used by: config, devtypes, dumpconfig, formats, fullreport, help, lastlog, lvchange, lvconvert, lvcreate, lvdisplay, lvextend, lvmchange, lvmconfig, lvmdevices, lvmdiskscan, lvmsadc, lvmsar, lvpoll, lvreduce, lvremove, lvrename, lvresize, lvs, lvscan, pvchange, pvck, pvcreate, pvdata, pvdisplay, pvmove, pvremove, pvresize, pvs, pvscan, segtypes, systemid, tags, version, vgcfgbackup, vgcfgrestore, vgchange, vgck, vgconvert, vgcreate, vgdisplay, vgexport, vgextend, vgimport, vgimportclone, vgimportdevices, vgmerge, vgmknodes, vgreduce, vgremove, vgrename, vgs, vgscan, vgsplit
  • --nohistory β€” do not record history of LVs being removed. Important: this has no effect unless the configuration setting metadata/record_lvs_history is enabled. πŸ’€
    • Used by: lvremove
  • --nolocking β€” disables locking. ⚠️ Use with caution, for real: concurrent commands may produce incorrect results. Do not play with this one.
    • Used by: config, devtypes, dumpconfig, formats, fullreport, help, lastlog, lvchange, lvconvert, lvcreate, lvdisplay, lvextend, lvmchange, lvmconfig, lvmdevices, lvmdiskscan, lvmsadc, lvmsar, lvpoll, lvreduce, lvremove, lvrename, lvresize, lvs, lvscan, pvchange, pvck, pvcreate, pvdata, pvdisplay, pvmove, pvremove, pvresize, pvs, pvscan, segtypes, systemid, tags, version, vgcfgbackup, vgcfgrestore, vgchange, vgck, vgconvert, vgcreate, vgdisplay, vgexport, vgextend, vgimport, vgimportclone, vgimportdevices, vgmerge, vgmknodes, vgreduce, vgremove, vgrename, vgs, vgscan, vgsplit
  • --norestorefile β€” in conjunction with --uuid, this allows a UUID to be specified without also requiring that a backup of the metadata be provided. 🫢
    • Used by: pvcreate
  • --nosuffix β€” suppresses the suffix on output sizes πŸ“. Use it with --units (except h and H) if you're processing the output, iykyk.
    • Used by: devtypes, fullreport, lvdisplay, lvs, pvdisplay, pvs, vgdisplay, vgs
  • --nosync β€” bestie, this one tells the creation of mirror, raid1, raid4, raid5 and raid10 to skip the initial synchronization. For mirror, raid1 and raid10, anything you write afterwards still gets mirrored, but the original contents are NOT copied over. For raid4 and raid5, no parity blocks get written at all, though data written later will cause parity blocks to be stored. Super useful for dodging a potentially long and resource-intensive initial sync of an empty mirror/raid1/raid4/raid5 and raid10 LV. ✨ But heads up: this option is not valid for raid6, because raid6 relies on proper parity (P and Q Syndromes) being created during initial synchronization so it can reconstruct proper user data when devices fail. And raid0 and raid0_meta don't provide any data copies or parity support anyway, so they don't support initial synchronization at all. Used by: lvcreate, lvextend, lvresize
  • --notifydbus β€” send a notification to D-Bus πŸ’Œ. The command will exit with an error if LVM wasn't built with support for D-Bus notification, or if the notify_dbus config setting is disabled. Used by: vgscan
  • --noudevsync β€” disables udev synchronization 😴. The process will not wait for notification from udev, and it'll just keep going irrespective of any possible udev processing happening in the background. Only use this if udev is not running or has rules that ignore the devices LVM creates, fr fr. Used by: lvchange, lvconvert, lvcreate, lvextend, lvreduce, lvremove, lvrename, lvresize, pvmove, pvscan, vgchange, vgremove
  • -n|--novolumegroup β€” only show PVs that don't belong to any VG. Lone wolves only 🐺 Used by: pvscan
  • -o|--options String β€” a comma-separated, ordered list of fields to display in columns πŸ“Š. The String arg syntax is: [+|-|#]Field1[,Field2 ...] β€” the prefix + will append the specified fields to the default fields, - will remove the specified fields from the default fields, and # will compact specified fields (removing them when empty for all rows). Use -o help to view the list of all available fields. Use separate lists of fields to add, remove or compact by repeating the -o option: -o+field1,field2 -o-field3,field4 -o#field5. These lists are evaluated from left to right. Use field name lv_all to view all LV fields, vg_all all VG fields, pv_all all PV fields, seg_all all LV segment fields, and pvseg_all all PV segment fields. See the lvm.conf(5) report section for more config options. See lvmreport(7) for more information about reporting. Used by: devtypes, fullreport, lvdisplay, lvs, pvdisplay, pvs, vgdisplay, vgs
  • --originname LV β€” specifies the name to use for the external origin LV when converting an LV to a thin LV πŸ¦‹. The LV being converted becomes a read-only external origin with this name. Used by: lvconvert
  • --output String β€” write lvm configuration to the specified output file πŸ“. Used with --input to read configuration from one file, optionally apply edits, and write the configuration to another file. Used by: dumpconfig, lvmconfig
  • -P|--partial β€” commands will do their best to activate LVs with missing PV extents 🩹. Missing extents may be replaced with error or zero segments according to the missing_stripe_filler setting. Metadata may not be changed with this option. Used by: lvchange, vgchange
  • -p|--permission rw|r β€” set access permission to read only r or read and write rw πŸ”. Used by: lvchange, lvcreate
  • --persist String β€” Persistent Reservation operation 🎟️. start: register local key and acquire reservation. stop: unregister local key, releasing reservation. remove: preempt and abort another key. clear: remove reservation and keys. check: check if started. autostart: start if the VG autostart flag is set. lvmlocal.conf pr_key or host_id must be configured to use PR. For local VGs, Write Exclusive (WE) is used, and for shared VGs Write Exclusive, all registrants (WEAR) is used. Use --setpersist to automate and/or require PR. Used by: vgchange, vgcreate, vgexport, vgimport
  • -M|--persistent y|n β€” when yes, makes the specified minor number persistent πŸ’Ύ. Used by: lvchange, lvcreate
  • -s|--physicalextentsize Size[m|UNIT] Used by: vgchange, vgcreate
  • --poll y|n β€” when yes, start the background transformation of an LV πŸ”„. An incomplete transformation, e.g. pvmove or lvconvert interrupted by reboot or crash, can be restarted from the last checkpoint with --poll y. When no, background transformation of an LV will not occur, and the transformation will not complete. It may not be appropriate to immediately poll an LV after activation, in which case --poll n can be used to defer polling until a later --poll y command. Used by: lvchange, vgchange
  • --polloperation pvmove|convert|merge|merge_thin β€” the command to perform from lvmpolld. Used by: lvpoll
  • --pooldatavdo y|n β€” use VDO type volume for pool data volume. Used by: lvconvert, lvcreate
  • --poolmetadata LV β€” the name of an LV to use for storing pool metadata πŸ“¦. Used by: lvconvert
  • --poolmetadatasize Size[m|UNIT] Used by: lvconvert, lvcreate, lvextend, lvresize
  • --poolmetadataspare y|n β€” enable or disable the automatic creation and management of a spare pool metadata LV in the VG 🌈. A spare metadata LV is reserved space that can be used when repairing a pool. Used by: lvconvert, lvcreate, vgmerge, vgsplit
  • --profile String β€” an alias for --commandprofile or --metadataprofile, depending on the command πŸ‘‘. Used by: config, devtypes, dumpconfig, formats, fullreport, help, lastlog, lvchange, lvconvert, lvcreate, lvdisplay, lvextend, lvmchange, lvmconfig, lvmdevices, lvmdiskscan, lvmsadc, lvmsar, lvpoll, lvreduce, lvremove, lvrename, lvresize, lvs, lvscan, pvchange, pvck, pvcreate, pvdata, pvdisplay, pvmove, pvremove, pvresize, pvs, pvscan, segtypes, systemid, tags, version, vgcfgbackup, vgcfgrestore, vgchange, vgck, vgconvert, vgcreate, vgdisplay, vgexport, vgextend, vgimport, vgimportclone, vgimportdevices, vgmerge, vgmknodes, vgreduce, vgremove, vgrename, vgs, vgscan, vgsplit
  • --pvmetadatacopies 0|1|2 β€” the number of metadata areas to set aside on a PV for storing VG metadata πŸ—‚οΈ. When 2, one copy of the VG metadata is stored at the front of the PV and a second copy is stored at the end. When 1, one copy of the VG metadata is stored at the front of the PV. When 0, no copies of the VG metadata are stored on the given PV. This may be useful in VGs containing many PVs (this places limitations on the ability to use vgsplit later.) Used by: pvck, pvcreate, vgchange, vgconvert, vgcreate, vgextend
  • -q|--quiet β€” suppress output and log messages 🀫. Overrides --debug and --verbose. Repeat once to also suppress any prompts with answer 'no'. Used by: config, devtypes, dumpconfig, formats, fullreport, help, lastlog, lvchange, lvconvert, lvcreate, lvdisplay, lvextend, lvmchange, lvmconfig, lvmdevices, lvmdiskscan, lvmsadc, lvmsar, lvpoll, lvreduce, lvremove, lvrename, lvresize, lvs, lvscan, pvchange, pvck, pvcreate, pvdata, pvdisplay, pvmove, pvremove, pvresize, pvs, pvscan, segtypes, systemid, tags, version, vgcfgbackup, vgcfgrestore, vgchange, vgck, vgconvert, vgcreate, vgdisplay, vgexport, vgextend, vgimport, vgimportclone, vgimportdevices, vgmerge, vgmknodes, vgreduce, vgremove, vgrename, vgs, vgscan, vgsplit
  • --raidintegrity y|n β€” enable or disable data integrity checksums for raid images βœ…. Used by: lvconvert, lvcreate
  • --raidintegrityblocksize Number β€” the block size to use for dm-integrity on raid images 🧱. The integrity block size should usually match the device logical block size, or the file system block size. It may be less than the file system block size, but not less than the device logical block size. Possible values: 512, 1024, 2048, 4096. Used by: lvconvert, lvcreate
  • --raidintegritymode String β€” use a journal (default) or bitmap for keeping integrity checksums consistent in case of a crash πŸ›Ÿ. The bitmap areas are recalculated after a crash, so corruption in those areas would not be detected. A journal does not have this problem. The journal mode doubles writes to storage, but can improve performance for scattered writes packed into a single journal write. bitmap mode can in theory achieve full write throughput of the device, but would not benefit from the potential scattered write optimization. Used by: lvconvert, lvcreate
  • -r|--readahead auto|none|Number β€” sets read ahead sector count of an LV πŸ‘€. auto is the default which allows the kernel to choose a suitable value automatically. none is equivalent to zero. Used by: lvchange, lvconvert, lvcreate
  • --readonly β€” prevent the command from making changes, including activation and metadata updates 🚫. (See --permission r for read only LVs.) Used by: fullreport, lvchange, lvdisplay, lvmdiskscan, lvs, lvscan, pvdisplay, pvs, vgcfgbackup, vgchange, vgdisplay, vgs
  • --rebuild PV β€” selects a PV to rebuild in a raid LV πŸ”§. Multiple PVs can be rebuilt by repeating this option. Use this option in place of --resync or --syncaction repair when the PVs with corrupted data are known, and their data should be reconstructed rather than reconstructing default (rotating) data. See lvmraid(7) for more information. Used by: lvchange
  • --refresh Used by: lvchange, lvmdevices, vgchange, vgmknodes, vgscan
  • -R|--regionsize Size[m|UNIT] β€” size of each raid or mirror synchronization region πŸ“. lvm.conf(5) activation/raid_region_size can be used to configure a default. Used by: lvconvert, lvcreate
  • --removekey String β€” a persistent reservation key to remove πŸ”‘. Used by: vgchange
  • --removemissing β€” bestie this is the ✨cleanup queen✨. It removes all the missing PVs from the VG, but only if there are no LVs allocated on them. Do that and your VG is back to normal operation again (you can create new LVs, change stuff, all of it 🫢). But if LVs are referencing those missing PVs and it can't do that? Then you can pair this with --force and the command will remove any partial LVs. Heads up though πŸ’€ β€” in that case, any LVs and dependent snapshots that were partly on the missing disks get removed completely, including the parts sitting on disks that are still present. If LVs spanned several disks, including some that are lost, you might be able to salvage some data first by activating LVs in partial mode. πŸ‘‘

Used by: vgreduce

  • --repair β€” (that's literally all the detail this one gets, no cap.)

Used by: lvconvert, pvck

  • --repairtype pv_header|metadata|label_header β€” repairs headers and metadata on a PV. Go read the command description for the deets. 🩹

Used by: pvck

  • --replace PV β€” swaps a specific PV in a raid LV out for another PV. The new PV you wanna use can optionally be popped in right after the LV. You can replace multiple PVs by just repeating this option as many times as you want. See lvmraid(7) for more. πŸ”

Used by: lvconvert

  • --reportformat basic|json|json_std β€” overrides the current output format for reports, which is normally defined globally by the report/output_format setting in lvm.conf(5). basic is the OG format with columns and rows β€” if there's more than one report per command, each report gets prefixed with the report name so you can tell them apart. json gives you report output in JSON format. json_std also gives you JSON but more compliant with the JSON standard (it's giving very proper πŸ’…). See lvmreport(7) for more.

Used by: devtypes, fullreport, lastlog, lvchange, lvcreate, lvdisplay, lvextend, lvreduce, lvremove, lvrename, lvresize, lvs, lvscan, pvchange, pvcreate, pvdisplay, pvmove, pvremove, pvresize, pvs, pvscan, vgcfgbackup, vgchange, vgck, vgconvert, vgcreate, vgdisplay, vgexport, vgextend, vgimport, vgimportdevices, vgmknodes, vgreduce, vgremove, vgrename, vgs, vgscan

  • -x|--resizeable y|n β€” turns the ability to add or remove PVs to/from a VG on (y) or off (n) β€” that's the vgextend/vgreduce life. 🎚️

Used by: vgchange

  • -r|--resizefs β€” resizes the fs using the fs-specific resize command (see: resize2fs(8), xfs_growfs(8), btrfs(8)). This may include mounting, unmounting, or running fsck. Peep --fsmode to control mounting behavior, and --nofsck to disable fsck. See --fs for more options (fun fact: --resizefs is equivalent to --fs resize). πŸ“

Used by: lvextend, lvreduce, lvresize

  • --restorefile String β€” works together with --uuid: it reads the file (one produced by vgcfgbackup), extracts the location and size of the data on the PV, and makes sure the metadata the program produces is consistent with the contents of that file β€” i.e. the physical extents will be in the same place and won't get overwritten by new metadata. It's a whole mechanism for upgrading the metadata format or adding/removing metadata areas.
⚠️ Use with care. Like, care care.

Used by: pvcreate

  • --restoremissing β€” adds a PV back into a VG after the PV went missing and then came back, like from a transient failure. The PV does not get reinitialized. πŸ¦‹

Used by: vgextend

  • --resync β€” kicks off mirror synchronization. Sync generally happens automatically, but this option forces it to run. Also see --rebuild if you want to synchronize a specific PV. During synchronization, data is read from the primary mirror device and copied to the others. Warning bestie 😭 β€” this can take a considerable amount of time, and during it the LV is without a complete redundant copy of the data. See lvmraid(7) for more.

Used by: lvchange

  • --rootvg β€” imports devices used for the root VG. 🌱

Used by: vgimportdevices

  • --rows β€” outputs columns as rows. Rotate that whole vibe 90Β°. πŸ”„

Used by: devtypes, fullreport, lvdisplay, lvs, pvdisplay, pvs, vgdisplay, vgs

  • --segments β€” (no description given, it just does its thing.)

Used by: lvdisplay, lvs, pvdisplay, pvs

  • -S|--select String β€” selects objects for processing and reporting based on criteria you specify. The criteria syntax is described by --select help and in lvmreport(7). For reporting commands, one row is displayed for each object matching the criteria. See --options help for the selectable object fields. Rows can be displayed with an extra "selected" field (-o selected) showing 1 if the row matches the selection and 0 if it doesn't. For non-reporting commands that process LVM entities, the selection is used to pick which items get processed. 🎯

Used by: devtypes, fullreport, lastlog, lvchange, lvdisplay, lvremove, lvs, pvchange, pvdisplay, pvs, vgchange, vgdisplay, vgexport, vgimport, vgimportdevices, vgremove, vgs

  • --separator String β€” the string used to separate each column. Super useful if you're grepping the output. πŸ”

Used by: devtypes, fullreport, lvdisplay, lvs, pvdisplay, pvs, vgdisplay, vgs

  • -k|--setactivationskip y|n β€” persistently sets (y) or clears (n) the "activation skip" flag on an LV. An LV with this flag set won't be activated unless the --ignoreactivationskip option is used by the activation command. Fun fact: this flag is set by default on new thin snapshot LVs. It is not applied to deactivation. The current value of the flag shows up in the lvs lv_attr bits. 🚩

Used by: lvchange, lvconvert, lvcreate

  • --setautoactivation y|n β€” sets the autoactivation property on a VG or LV. Display the property with vgs or lvs "-o autoactivation". When the autoactivation property is disabled, the VG or LV will not be activated by a command doing autoactivation (vgchange, lvchange, or pvscan using -aay). If autoactivation is disabled on a VG, no LVs will be autoactivated in that VG, and the LV autoactivation property has no effect. If autoactivation is enabled on a VG, autoactivation can still be disabled for individual LVs. ⚑

Used by: lvchange, lvcreate, vgchange, vgcreate

  • --setlockargs String β€” adds or removes lock_args settings for a shared VG. The lock_args determine lock manager behavior for the VG. These settings are only allowed for lock_type sanlock.
    • persist: use persistent reservations for lock recovery. lvmlockd will preempt-abort the persistent reservation of a failed lock owner so that the lock can be acquired.
    • notimeout: use locks that do not time out when the owner fails. In this case, a lock owned by a failed host can only be acquired using the persist feature.
    • nopersist: do not use the persist feature.
    • timeout: do not use the notimeout feature.
    • nowatchdog: do not connect to wdmd/watchdog when starting the VG lockspace. Requires notimeout. Without timeout-based recovery, the watchdog is not needed.
    • watchdog: when starting a VG lockspace, sanlock/wdmd connect the lockspace to /dev/watchdog. If VG lockspace renewals fail (e.g. due to a storage outage, or a sanlock daemon failure), then the watchdog resets the host if locks are held in the VG.

The default behavior with no settings configured is: nopersist, timeout, watchdog. πŸ”

Used by: vgchange, vgcreate

  • --setpersist String β€” (no description here, sorry bestie, that's all the page gives us.)

Used by: vgchange, vgcreate

  • --setphysicalvolumesize Size[m|UNIT] β€” overrides the automatically detected size of the PV.
⚠️ Use with care, or before you go reducing the physical size of the device. Fr fr.

Used by: pvcreate, pvresize

  • --settings String β€” specifies command specific settings in "Key = Value" form. Combine multiple settings inside quotes, or just repeat the settings option for each one. 🧾

Used by: pvck

  • --shared β€” (no description, just vibes.)

Used by: fullreport, lvdisplay, lvs, pvdisplay, pvs, vgcreate, vgdisplay, vgs

  • -s|--short β€” (no description, keep it brief ✨).

Used by: pvdisplay, pvscan, vgdisplay

  • --showdeprecated β€” includes deprecated configuration settings in the output. These settings get deprecated after a certain version. If a concrete version is specified with --atversion, deprecated settings are automatically included if the specified version is lower than the version in which the settings were deprecated. The current and diff types include deprecated settings in their output by default; all the other types ignore deprecated settings. πŸ‘΅

Used by: config, dumpconfig, lvmconfig

  • --showunsupported β€” includes unsupported configuration settings in the output. These settings are either only used for debugging or development purposes, or their support isn't complete yet and they're not meant to be used in production.
⚠️ Not for production, periodt.

The current and diff types include unsupported settings in their output by default; all the other types ignore unsupported settings. 🚧

Used by: config, dumpconfig, lvmconfig

  • --sinceversion String β€” specify an LVM version in x.y.z format, where x is the major version, y is the minor version and z is the patchlevel (e.g. 2.2.106). This option is currently applicable only with --typeconfig new to display all configuration settings introduced since the given version. πŸ“†

Used by: config, dumpconfig, lvmconfig

  • -L|--size Size[m|UNIT] β€” (no description, but you already know it's about the size πŸ’…).

Used by: lvcreate, lvextend, lvreduce, lvresize

  • -s|--snapshot β€” (no description given.)

Used by: lvconvert, lvcreate

  • -O|--sort String β€” a comma-separated ordered list of columns to sort by. It replaces the default selection. Put a - in front of any column for a reverse sort on that column. ↕️

Used by: devtypes, fullreport, lvdisplay, lvs, pvdisplay, pvs, vgdisplay, vgs

  • --splitcache β€” separates a cache pool from a cache LV, and keeps the unused cache pool LV. Before the separation happens, the cache is flushed. Also see --uncache. βœ‚οΈ

Used by: lvconvert

  • --splitmirrors Number β€” splits the specified number of images from a raid1 or mirror LV and uses them to create a new LV. If --trackchanges is also specified, changes to the raid1 LV are tracked while the split LV stays detached. If --name is specified, then the images are permanently split from the original LV and changes are not tracked. πŸͺž

Used by: lvconvert


  • --splitsnapshot β€” bestie this one disconnects a COW snapshot from the origin LV it's been clinging to. The LV that gets split off carries all the chunks that differ from the origin LV PLUS the metadata describing them, so it's fully self-sufficient πŸ¦‹. Once it's free you can wipe it and then yeet it into the void with lvremove. So satisfying.
    • Used by: lvconvert
  • --startpoll β€” kicks off polling on an LV so a conversion keeps processing. Basically the "keep going bestie" button πŸ’….
    • Used by: lvconvert
  • -s, --stdin
    • Used by: lvmsar
  • --stripes Number β€” sets how many stripes a striped LV has, aka how many PVs (devices) it's spread across. Data that looks sequential in the LV gets scattered across multiple devices in units of the stripe size (peep --stripesize for that 🌈). Careful though: this does not touch space that's already allocated β€” only newly allocated space can be striped. No retroactive glow-ups, sorry.
    • Used by: lvconvert
  • -i, --stripes Number β€” same energy, striped LV, this is the number of PVs (devices) it's spread across, data that appears sequential in the LV gets spread across multiple devices in units of the stripe size (see --stripesize). Key difference: this does not change existing allocated space, it only applies to space the command is allocating right now. When you're creating a RAID 4/5/6 LV, this number does not include the extra devices needed for parity, okurrr. The biggest number depends on the RAID type β€” raid0: 64, raid10: 32, raid4/5: 63, raid6: 62 β€” and when you don't specify one, the default also depends on the RAID type: raid0: 2, raid10: 2, raid4/5: 3, raid6: 5. If you wanna stripe a new raid LV across all PVs by default, go read lvm.conf(5) allocation/raid_stripe_all_devices ✨.
    • Used by: lvcreate, lvextend, lvresize
  • -I, --stripesize Size[k|UNIT] β€” the amount of data written to one device before it moves on to the next one in a striped LV. Tiny striker, big vibes.
    • Used by: lvconvert, lvcreate, lvextend, lvresize
  • --swapmetadata β€” pulls the metadata LV out of a pool and swaps in another LV you specify πŸŽ€. The extracted LV is preserved and gets the name of the LV that replaced it. Use for repair only β€” this is not a casual lil cosmetic thing. Once the metadata LV is swapped out of the pool, it can be activated directly and used with thin provisioning tools: cache_dump(8), cache_repair(8), cache_restore(8), thin_dump(8), thin_repair(8), thin_restore(8). Look at that lineup πŸ”₯.
    • Used by: lvconvert
  • --[raid]syncaction check|repair β€” starts up different types of RAID synchronization. This makes the RAID LV read every data and parity block in the array and check for discrepancies (mismatches between mirrors or wrong parity values). check will count the discrepancies but not correct them. repair will actually correct them. Heads up bestie: these synchronization actions are transient β€” they have to be restarted after a system failure/reboot or after a config change to the RaidLV 😭. Go see lvs(8) for reporting the discrepancies found or repaired.
    • Used by: lvchange
  • --sysinit β€” tells everyone that vgchange/lvchange is being invoked from early system initialisation scripts (like rc.sysinit or an initrd), before writable filesystems are even available πŸ™ˆ. Because of that, some functionality has to be disabled, and this option is basically a shortcut that selects an appropriate set of options for you. Right now it's equivalent to using --ignorelockingfailure, --ignoremonitoring, --poll n, and setting the env var LVM_SUPPRESS_LOCKING_FAILURE_MESSAGES. Also vgchange/lvchange skip autoactivation and defer to pvscan autoactivation.
    • Used by: lvchange, vgchange
  • --systemid String
    • Used by: vgchange, vgcreate
  • -t, --test β€” run in test mode, meaning commands will not update metadata. How does it pull that off? It disables every metadata write but still returns success to the calling function. Warning though β€” this may lead to unusual error messages in multi-stage operations if a tool relies on reading back metadata it believes has changed but hasn't πŸ’€. Play with the vibes, not your real data.
    • Used by: config, devtypes, dumpconfig, formats, fullreport, help, lastlog, lvchange, lvconvert, lvcreate, lvdisplay, lvextend, lvmchange, lvmconfig, lvmdevices, lvmdiskscan, lvmsadc, lvmsar, lvpoll, lvreduce, lvremove, lvrename, lvresize, lvs, lvscan, pvchange, pvck, pvcreate, pvdata, pvdisplay, pvmove, pvremove, pvresize, pvs, pvscan, segtypes, systemid, tags, version, vgcfgbackup, vgcfgrestore, vgchange, vgck, vgconvert, vgcreate, vgdisplay, vgexport, vgextend, vgimport, vgimportclone, vgimportdevices, vgmerge, vgmknodes, vgreduce, vgremove, vgrename, vgs, vgscan, vgsplit
  • -T, --thin β€” says the command is handling a thin LV or a thin pool. Check --type thin, --type thin-pool, and --virtualsize too. And go read lvmthin(7) for the whole scoop on LVM thin provisioning 🌸.
    • Used by: lvconvert, lvcreate
  • --thinpool LV β€” the name of a thin pool LV. That's it, that's the whole thing πŸ’–.
    • Used by: lvconvert, lvcreate
  • --trackchanges β€” can be used with --splitmirrors on a raid1 LV. This makes changes to the original raid1 LV get tracked while the split images stay detached πŸ‘€. It's a temporary state that lets the read-only detached image be merged efficiently back into the raid1 LV later β€” only the regions with changed data get resynchronized during the merge, so it's giving efficiency. While a raid1 LV is tracking changes, the only operations allowed on it are merging the split image (see --mergemirrors) or permanently splitting the image (see --splitmirrors with --name). That's it, no side quests.
    • Used by: lvconvert
  • --type linear|striped|snapshot|raid|mirror|thin|thin-pool|vdo|vdo-pool|cache|cache-pool|writecache
--type linear|striped|snapshot|raid|mirror|thin|thin-pool|vdo|vdo-pool|
cache|cache-pool|writecache

The LV type, also known as the "segment type" or "segtype" ✨. Go look at the usage descriptions for the specific ways to use each of these types. For more info about redundancy and performance (raid<N>, mirror, striped, linear) see lvmraid(7). For thin provisioning (thin, thin-pool) see lvmthin(7). For performance caching (cache, cache-pool) see lvmcache(7). For copy-on-write snapshots (snapshot) see the usage definitions. For VDO (vdo) see lvmvdo(7). Several commands just… omit an explicit type option, because the type gets inferred from other options or shortcuts (e.g. --stripes, --mirrors, --snapshot, --virtualsize, --thin, --cache, --vdo) πŸ™ˆ. Use inferred types with care, because it can lead to unexpected results. Fr fr.

  • Used by: lvconvert, lvcreate, lvextend, lvresize
  • --typeconfig current|default|diff|full|list|missing|new|profilable|profilable-command|profilable-metadata
--typeconfig current|default|diff|full|list|missing|new|profilable|
profilable-command|profilable-metadata
  • current β€” prints the config settings that would be applied to an LVM command (assuming the command doesn't override them on the command line). This includes: settings that have been modified in lvm config files, settings that get their default values from config files, and default settings that have been uncommented in config files.
  • default β€” prints all settings with their default values. Changes made in lvm config files are not reflected in the output. Some settings get their default values internally, and those get printed as comments. Other settings get their default values from config files, and those are not printed as comments.
  • diff β€” prints only the config settings that have been modified from their default values in config files (i.e. the difference between current and default).
  • full β€” prints every setting uncommented and set to the current value, i.e. how it would be used by an LVM command. This includes settings modified in config files, settings that usually get defaults internally, and settings that get defaults from config files.
  • list β€” prints all config names without values.
  • missing β€” prints settings that are missing from the lvm config files. A missing setting that usually gets its default from config files is printed uncommented and set to the internal default. Settings that get their default internally and are not set in config files are printed commented with the internal default.
  • new β€” prints config settings that have been added since the lvm version specified by --sinceversion. They're printed with their default values.
  • profilable β€” prints settings with their default values that can be set from a profile.
  • profilable-command β€” prints settings with their default values that can be set from a command profile.
  • profilable-metadata β€” prints settings with their default values that can be set from a metadata profile.
  • Also see lvm.conf(5).
  • Used by: config, dumpconfig, lvmconfig
  • --udevoutput β€” command output gets modified so it can be imported by a udev rule. Custom-fit for udev, iconic behavior πŸ‘‘.
    • Used by: pvscan
  • --unbuffered β€” produce output immediately, without sorting or aligning the columns properly. Chaotic? Yes. Instant? Also yes πŸ’….
    • Used by: devtypes, fullreport, lvdisplay, lvs, pvdisplay, pvs, vgdisplay, vgs
  • --uncache β€” separates a cache pool from a cache LV, and deletes the now-unused cache pool LV 🧚. Before the separation happens, the cache is flushed (thank u). Also peep --splitcache.
    • Used by: lvconvert
  • --unconfigured β€” internal option used for generating the config file during build. Not for you, bestie, it's for the build process πŸ™ˆ.
    • Used by: config, dumpconfig, lvmconfig
  • --units [Number]r|R|h|H|b|B|s|S|k|K|m|M|g|G|t|T|p|P|e|E β€” all sizes get output in these units: human-(r)eadable with a '<' rounding indicator, (h)uman-readable, (b)ytes, (s)ectors, (k)ilobytes, (m)egabytes, (g)igabytes, (t)erabytes, (p)etabytes, (e)xabytes 🌈. Capitalise the letter to use multiples of 1000 (S.I.) instead of 1024. And yes you can specify custom units, e.g. --units 3M. Obsessed.
    • Used by: fullreport, lvdisplay, lvs, pvdisplay, pvs, vgdisplay, vgs
  • --unquoted β€” when you use this with --nameprefixes, the output values in the field=value pairs are not quoted. Raw and unfiltered, we love to see it.
    • Used by: devtypes, fullreport, lvdisplay, lvs, pvdisplay, pvs, vgdisplay, vgs
  • --update β€” updates the content of the devices file πŸŽ€.
    • Used by: lvmdevices
  • --updatemetadata β€” bestie, this one is your metadata glow-up πŸ’… It updates the VG metadata to fix problems. So like, if the VG metadata got updated while a PV was missing, and then that PV comes back acting brand new with an old version of the metadata, this option (or literally any other command that writes metadata, no cap) will update the metadata on that previously-missing PV. If a PV got removed from a VG while it was missing and then it reappears? This option clears the outdated metadata off it. And if the metadata text is damaged on one PV, this option will replace that damaged metadata text. For more severe damage β€” like, headers-level damage β€” go see pvck(8) instead. 🩹
    • Used by: vgck
  • --usepolicies β€” does the thing according to the policy set up in lvm.conf(5) or a profile. Read the room, follow the rules ✨
    • Used by: lvconvert, lvextend
  • -u|--uuid β€” no description here, it just vibes with these commands πŸ‘‘
    • Used by: pvchange, pvscan, vgchange
  • -u|--uuid String β€” gives you the ability to specify a UUID for the device πŸŽ€ Without this option, a random UUID just spawns in. You need this before restoring a backup of LVM metadata onto a replacement device, fr β€” see vgcfgrestore(8). Which means use of --restorefile is compulsory unless --norestorefile is used. All PVs must have unique UUIDs, periodt, and LVM will straight up block certain operations if it sees multiple devices rocking the same UUID. More deets in vgimportclone(8). πŸ¦‹
    • Used by: pvcreate
  • --validate β€” checks the current configuration you're using, then exits with the appropriate return code. Iconic. The validation only happens for the configuration at the front of the "config cascade" β€” to validate the whole merged configuration tree you also gotta use --mergedconfig. And heads up: the validation happens even if lvm.conf(5) config/checks is disabled. She does not skip leg day πŸ’ͺ
    • Used by: config, dumpconfig, lvmconfig
  • --valuesonly β€” when it's printing config settings, it prints only the values, no keys. Just the good part, hold the garnish πŸ“
    • Used by: config, dumpconfig, lvmconfig
  • --vdo β€” says the command is handling a VDO LV. See --type vdo. See lvmvdo(7) for more about VDO usage. 🌈
    • Used by: lvcreate
  • --vdopool LV β€” the name of a VDO pool LV. lvmvdo(7) has the full lore about VDO usage. πŸ’œ
    • Used by: lvconvert, lvcreate
  • --vdosettings String β€” specifies tunable VDO options for VDO LVs. Use the form 'option=value' or 'option1=value option2=value', or just repeat --vdosettings for each option you're setting. These settings override the default VDO behaviors. Wanna remove your vdosettings and revert to the default VDO behaviors? Use --vdosettings 'default'. See lvmvdo(7) for more info. 🧚
    • Used by: lvchange, lvconvert, lvcreate
  • -v|--verbose β€” sets verbose level. Repeat it from 1 to 4 times to increase the detail of messages sent to stdout and stderr. Turning the volume up on the truth πŸ”₯
    • Used by: config, devtypes, dumpconfig, formats, fullreport, help, lastlog, lvchange, lvconvert, lvcreate, lvdisplay, lvextend, lvmchange, lvmconfig, lvmdevices, lvmdiskscan, lvmsadc, lvmsar, lvpoll, lvreduce, lvremove, lvrename, lvresize, lvs, lvscan, pvchange, pvck, pvcreate, pvdata, pvdisplay, pvmove, pvremove, pvresize, pvs, pvscan, segtypes, systemid, tags, version, vgcfgbackup, vgcfgrestore, vgchange, vgck, vgconvert, vgcreate, vgdisplay, vgexport, vgextend, vgimport, vgimportclone, vgimportdevices, vgmerge, vgmknodes, vgreduce, vgremove, vgrename, vgs, vgscan, vgsplit
  • --version β€” displays version information. Boring but essential, like water πŸ’§
    • Used by: config, devtypes, dumpconfig, formats, fullreport, help, lastlog, lvchange, lvconvert, lvcreate, lvdisplay, lvextend, lvmchange, lvmconfig, lvmdevices, lvmdiskscan, lvmsadc, lvmsar, lvpoll, lvreduce, lvremove, lvrename, lvresize, lvs, lvscan, pvchange, pvck, pvcreate, pvdata, pvdisplay, pvmove, pvremove, pvresize, pvs, pvscan, segtypes, systemid, tags, version, vgcfgbackup, vgcfgrestore, vgchange, vgck, vgconvert, vgcreate, vgdisplay, vgexport, vgextend, vgimport, vgimportclone, vgimportdevices, vgmerge, vgmknodes, vgreduce, vgremove, vgrename, vgs, vgscan, vgsplit
  • --vgmetadatacopies all|unmanaged|Number β€” how many copies of the VG metadata get kept. VG metadata lives in VG metadata areas on PVs in the VG, i.e. reserved space at the start and/or end of the PVs. Keeping a copy of the VG metadata on every PV can tank performance in VGs with a huge number of PVs, so watch out 😭 When this number is set to a non-zero value, LVM will automatically pick PVs to store metadata on, using the metadataignore flags on PVs to hit the specified number. The number can also be replaced with special string values: unmanaged makes LVM not automatically manage the PV metadataignore flags; all makes LVM first clear the metadataignore flags on all PVs, and then become unmanaged. πŸ‘‘
    • Used by: vgchange, vgcreate, vgsplit
  • --vgonline β€” the first command to see a complete VG will report it uniquely ✨ Other commands that see the complete VG will report it differently.
    • Used by: pvscan
  • -V|--virtualsize Size[m|UNIT] β€” the virtual size of a new thin LV. See lvmthin(7) for more about LVM thin provisioning. Using virtual size (-V) and actual size (-L) together creates a sparse LV. lvm.conf(5) global/sparse_segtype_default decides the default segment type used to create a sparse LV. Anything written to a sparse LV will be returned when reading from it β€” so iconic. Reading from other areas of the LV will return blocks of zeros. When using a snapshot to create a sparse LV, a hidden virtual device is created using the zero target, and the LV has the suffix _vorigin. Snapshots are less efficient than thin provisioning when creating large sparse LVs (GiB). πŸ¦‹
    • Used by: lvconvert, lvcreate
  • -W|--wipesignatures y|n β€” controls detection and subsequent wiping of signatures on new LVs. There's a prompt for each signature detected to confirm its wiping (unless --yes is used to override confirmations). When not specified, signatures are wiped whenever zeroing is done (see --zero). This behaviour can be configured with lvm.conf(5) allocation/wipe_signatures_when_zeroing_new_lvs. If blkid wiping is used (lvm.conf(5) allocation/use_blkid_wiping) and LVM is compiled with blkid wiping support, then the blkid(8) library is used to detect the signatures (use blkid -k to list the signatures that are recognized). Otherwise, native LVM code is used to detect signatures (only MD RAID, swap and LUKS signatures are detected in this case). The LV is not wiped if the read only flag is set. 🚫
    • Used by: lvconvert, lvcreate
  • --withcomments β€” displays a full comment for each configuration node. For deprecated settings, it also displays comments about deprecation. Receipts for everything 🧾
    • Used by: config, dumpconfig, lvmconfig
  • --withgeneralpreamble β€” includes the general config file preamble. πŸŽ€
    • Used by: config, dumpconfig, lvmconfig
  • --withlocalpreamble β€” includes the local config file preamble. πŸ’œ
    • Used by: config, dumpconfig, lvmconfig
  • --withspaces β€” where appropriate, adds more spaces in the output for better readability. Breathing room, we love to see it 🌸
    • Used by: config, dumpconfig, lvmconfig
  • --withsummary β€” displays a one line comment for each configuration node. Short and sweet, fr fr.
    • Used by: config, dumpconfig, lvmconfig
  • --withversions β€” also displays a comment containing the version of introduction for each configuration node. If the setting is deprecated, it also displays the version since which it is deprecated. The lore, documented πŸ“œ
    • Used by: config, dumpconfig, lvmconfig
  • --[raid]writebehind Number β€” the maximum number of outstanding writes allowed to devices in a RAID1 LV that is marked write-mostly. Once this value is exceeded, writes become synchronous (i.e. all writes to the constituent devices must complete before the array signals the write has completed). Setting the value to zero clears the preference and lets the system pick the value arbitrarily. πŸŒ€
    • Used by: lvchange
  • --[raid]writemostly PV[:t|n|y] β€” marks a device in a RAID1 LV as write-mostly. All reads to these drives will be avoided unless absolutely necessary, which keeps the number of I/Os to the drive to a minimum. The default behavior is to set the write-mostly attribute for the specified PV. You can also remove the write-mostly flag by adding the suffix :n at the end of the PV name, or toggle the value with the suffix :t. Repeat this option to change the attribute on multiple PVs. πŸ”
    • Used by: lvchange
  • -y|--yes β€” does not prompt for confirmation interactively, but always assumes the answer is yes. Use with extreme caution. ⚠️ (For automatic no, see -qq.)
    • Used by: config, devtypes, dumpconfig, formats, fullreport, help, lastlog, lvchange, lvconvert, lvcreate, lvdisplay, lvextend, lvmchange, lvmconfig, lvmdevices, lvmdiskscan, lvmsadc, lvmsar, lvpoll, lvreduce, lvremove, lvrename, lvresize, lvs, lvscan, pvchange, pvck, pvcreate, pvdata, pvdisplay, pvmove, pvremove, pvresize, pvs, pvscan, segtypes, systemid, tags, version, vgcfgbackup, vgcfgrestore, vgchange, vgck, vgconvert, vgcreate, vgdisplay, vgexport, vgextend, vgimport, vgimportclone, vgimportdevices, vgmerge, vgmknodes, vgreduce, vgremove, vgrename, vgs, vgscan, vgsplit
  • -Z|--zero y|n β€” yeah this one is just vibing here, no explanation given πŸ€·β€β™€οΈ
    • Used by: lvchange, lvconvert, lvcreate, pvcreate, vgcreate, vgextend

🌟 SEE ALSO 🌟


and that's a wrap on LVM-ARGS(7), bestie!! πŸŽ‰ you made it all the way through, and honestly? slay. this page is from LVM TOOLS 2.03.44(2), dated 2026-10-27, brought to you by Red Hat, Inc. β€” go forth and lvm responsibly, mwah πŸ’–πŸ‘‘βœ¨

πŸ“¦ where this page comes from