VGSCAN(8)
π NAME π
okay so bestie, let me introduce you to vgscan β she searches for all volume groups. that's it. that's her whole thing, and she does it beautifully. β¨
(and for the record, this is a System Manager's Manual page, section 8 β the big system-admin section. main character energy only. π)
π¦ SYNOPSIS π¦
vgscan [ option_args ]
πΈ DESCRIPTION πΈ
vgscan goes around scanning all supported LVM block devices in the system hunting for VGs (volume groups). it's giving detective queen ππ β that's literally the entire job description, no cap.
π USAGE π
here's how you'd actually call her:
vgscan
[ --ignorelockingfailure ]
[ --mknodes ]
[ --notifydbus ]
[ --refresh ]
[ --reportformat basic|json|json_std ]
[ COMMON_OPTIONS ]
and these are the common options for lvm, the shared wardrobe that basically every lvm command gets to wear:
Common options for lvm:
[ -d|--debug ... ]
[ -h|--help ]
[ -q|--quiet ... ]
[ -t|--test ]
[ -v|--verbose ... ]
[ -y|--yes ]
[ --commandprofile String ]
[ --config String ]
[ --devices PV ]
[ --devicesfile String ]
[ --driverloaded y|n ]
[ --journal String ]
[ --lockopt String ]
[ --longhelp ]
[ --nohints ]
[ --nolocking ]
[ --profile String ]
[ --version ]
β¨ OPTIONS β¨
--commandprofile Stringβ the command profile you want to use for command configuration. peeplvm.conf(5)for the full tea on profiles. π--config Stringβ config settings for the command, and these override whateverlvm.conf(5)was saying. the String arg uses the same format aslvm.conf(5), or you can go off-script with section/field syntax. more info inlvm.conf(5). π-d,--debug ...β set debug level. repeat it anywhere from 1 to 6 times to crank up the detail of the messages sent to the log file and/or syslog (if that's even configured). yes bestie, more is more.--devices PVβ restricts which devices are visible and accessible to the command. anything you don't list will just look like it's missing (ghosted, honestly π»). you can repeat this option, or hand it a comma-separated list of devices. it overrides the devices file.--devicesfile Stringβ a file listing the devices LVM should use. the file has to already exist in/etc/lvm/devices/and it's managed with thelvmdevices(8)command. this overrides thelvm.conf(5)devices/devicesfileanddevices/use_devicesfilesettings.--driverloaded y|nβ if you set it to no, the command will not attempt to use device-mapper. strictly for testing and debugging, babe.-h,--helpβ display help text. the classic. π«Ά--ignorelockingfailureβ lets a command keep going with read-only metadata operations even after locking failures. she's forgiving like that.--journal Stringβ record information in the systemd journal. this info is in addition to whatever thelvm.conflog/journalsetting already turned on.command:records information about the command.output:records the default command output.debug:records full command debugging.--lockopt Stringβ used to pass options for special cases over tolvmlockd. seelvmlockd(8)for more.--longhelpβ display long help text. the extended director's cut. β¨--mknodesβ also checks the LVM special files in/devthat are needed for active LVs, and creates any missing ones and removes any unused ones. also check out the additional--refreshoption for use in a udev environment.--nohintsβ do not use the hints file to locate devices for PVs. without hints, a command may end up reading more devices to find PVs. she'll still perform standard hint file invalidation where appropriate, don't worry.--nolockingβ disable locking. use with caution, because concurrent commands may produce incorrect results.
β οΈ fr fr, that one is not a vibe. concurrent commands + no locking = incorrect results. be careful.
--notifydbusβ send a notification to D-Bus. the command will exit with an error if LVM was not built with support for D-Bus notification, or if thenotify_dbusconfig setting is disabled. π--profile Stringβ an alias for--commandprofileor--metadataprofile, depending on the command.-q,--quiet ...β suppress output and log messages. overrides--debugand--verbose. repeat it once to also suppress any prompts with answer 'no'. π€«--refreshβ if the LV is active, reload its metadata. in an environment where udev is used to manage the/devcontent, using this option is highly recommended β because refresh also regenerates udev events for an LV based on which existing udev rules are applied to set the/devcontent and permissions. also, this operation may be useful if something has gone wrong, or if some form of manual LV sharing is being used. π₯--reportformat basic|json|json_stdβ overrides the current output format for reports, which is defined globally by thereport/output_formatsetting inlvm.conf(5).basicis the original format with columns and rows β and if there's more than one report per command, each report gets prefixed with the report name for identification.jsonproduces report output in JSON format.json_stdproduces report output in JSON format that's more compliant with the JSON standard. seelvmreport(7)for more. π-t,--testβ run in test mode. commands will not update metadata. this is implemented by disabling all metadata writing but nevertheless returning success to the calling function. heads up: 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. π-v,--verbose ...β set verbose level. repeat from 1 to 4 times to increase the detail of messages sent to stdout and stderr.--versionβ display version information. π-y,--yesβ do not prompt for confirmation interactively, but always assume the answer is yes. use with extreme caution. (for automatic no, see-qq.)
π§ VARIABLES π§
Stringβ see the option description for information about the string content.Size[UNIT]β Size is an input number that accepts an optional unit. input units are always treated as base two values, regardless of capitalization β e.g.'k'and'K'both refer to 1024. the default input unit is specified by letter, followed by|UNIT. UNIT represents the other possible input units:b|Bis bytes,s|Sis sectors of 512 bytes,k|Kis KiB,m|Mis MiB,g|Gis GiB,t|Tis TiB,p|Pis PiB,e|Eis EiB. (and no, bestie, don't confuse this with the output control--units, where capital letters mean multiples of 1000. two totally different girls. π )
π ENVIRONMENT VARIABLES π
see lvm(8) for information about environment variables used by lvm. for example, LVM_VG_NAME can generally be substituted for a required VG parameter. π
π SEE ALSO π
lvm(8),lvm.conf(5),lvmconfig(8),lvmdevices(8)pvchange(8),pvck(8),pvcreate(8),pvdisplay(8),pvmove(8),pvremove(8),pvresize(8),pvs(8),pvscan(8)vgcfgbackup(8),vgcfgrestore(8),vgchange(8),vgck(8),vgcreate(8),vgconvert(8),vgdisplay(8),vgexport(8),vgextend(8),vgimport(8),vgimportclone(8),vgimportdevices(8),vgmerge(8),vgmknodes(8),vgreduce(8),vgremove(8),vgrename(8),vgs(8),vgscan(8),vgsplit(8)lvcreate(8),lvchange(8),lvconvert(8),lvdisplay(8),lvextend(8),lvreduce(8),lvremove(8),lvrename(8),lvresize(8),lvs(8),lvscan(8)lvm-fullreport(8),lvm-lvpoll(8),blkdeactivate(8),lvmdump(8)dmeventd(8),lvmpolld(8),lvmlockd(8),lvmlockctl(8),lvmdbusd(8),fsadm(8)lvmsystemid(7),lvmreport(7),lvmcache(7),lvmraid(7),lvmthin(7),lvmvdo(7),lvmautoactivation(7)
and that's the whole page, bestie!! π«Ά this one was brought to you by Red Hat, Inc. β LVM TOOLS 2.03.44(2), dated 2026-10-27. a true icon, periodt. πβ¨π
π¦ where this page comes from
- arch rolling: lvm2 2.03.44-1 Β· GPL-2.0-only AND LGPL-2.1-only
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash on : a language model's rewrite of the original, under its terms