• Skip to primary navigation
  • Skip to main content
  • Skip to primary sidebar
  • Skip to footer navigation

The Geek Diary

  • OS
    • Linux
    • CentOS/RHEL
    • VCS
  • Interview Questions
  • Database
    • MariaDB
  • DevOps
    • Docker
    • Shell Scripting
  • Big Data
    • Hadoop
    • Cloudera
    • Hortonworks HDP

vgs: command not found

by Deepika

vgs is a command-line utility that displays information about Logical Volume Manager (LVM) volume groups. LVM is a system that allows users to manage logical volumes, which are virtual storage devices created by combining multiple physical storage devices. Volume groups are collections of physical volumes that have been combined into a single logical volume for easier management.

With vgs, you can obtain a summary of information about all the volume groups on the system, including their size, number of physical volumes, and free space. You can also use vgs to obtain more detailed information about a specific volume group, such as the size and number of its logical volumes, the physical volumes that make up the group, and the status of each volume.

The output of vgs includes the following information:

  • VG Name: The name of the volume group.
  • VG UUID: The universally unique identifier (UUID) of the volume group.
  • PV Count: The number of physical volumes in the volume group.
  • LV Count: The number of logical volumes in the volume group.
  • SN Attr: The status of the volume group. For example, “w” indicates that the volume group is writable, while “r” indicates that it is read-only.
  • V Size: The size of the volume group.
  • V Free: The amount of free space in the volume group.

Some of the common use cases for vgs include:

  • Checking the status of volume groups: You can use vgs to check whether a volume group is active or inactive, and to see how much free space is available in the group.
  • Viewing detailed information about a volume group: You can use vgs to view the size and status of each logical volume in a volume group, as well as the physical volumes that make up the group.
  • Troubleshooting LVM issues: vgs can be used to diagnose LVM issues, such as when a logical volume is full or when a physical volume is failing.

If you encounter the below error while running the command vgs:

vgs: command not found

you may try installing the below package as per your choice of distribution:

Distribution Command
Debian apt-get install lvm2
Ubuntu apt-get install lvm2
Alpine apk add lvm2
Arch Linux pacman -S lvm2
Kali Linux apt-get install lvm2
CentOS yum install lvm2
Fedora dnf install lvm2
Raspbian apt-get install lvm2

vgs Command Examples

1. Display information about volume groups:

# vgs

2. Display all volume groups:

# vgs -a

3. Change default display to show more details:

# vgs -v

4. Display only specific fields:

# vgs -o field_name_1,field_name_2

5. Append field to default display:

# vgs -o +field_name

6. Suppress heading line:

# vgs --noheadings

7. Use separator to separate fields:

# vgs --separator =

Summary

vgs is a powerful tool that can be used to manage and troubleshoot LVM volume groups. It is part of the lvm2 package, which is available on most Linux distributions. You can find more information on vgs and other LVM commands in the lvm2 man pages or online documentation.

Filed Under: Linux

Some more articles you might also be interested in …

  1. flatpak-builder: command not found
  2. “git effort” Command Examples
  3. mc Command Examples
  4. dirs: Displays or manipulates the directory stack
  5. colorls: A Ruby gem that beautifies the terminal’s ls command, with color and font-awesome icons
  6. How To Disable MD5-based HMAC Algorithm’s for SSH
  7. kill Command Examples in Linux
  8. pacman4console Command Examples in Linux
  9. namcap Command Examples in Linux
  10. last: command not found

You May Also Like

Primary Sidebar

Recent Posts

  • Vanilla OS 2 Released: A New Era for Linux Enthusiasts
  • mk Command Examples
  • mixxx Command Examples
  • mix Command Examples

© 2025 · The Geek Diary

  • Archives
  • Contact Us
  • Copyright