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

The Geek Diary

  • OS
    • Linux
    • CentOS/RHEL
    • Solaris
    • Oracle Linux
    • VCS
  • Interview Questions
  • Database
    • oracle
    • oracle 12c
    • ASM
    • mysql
    • MariaDB
  • DevOps
    • Docker
    • Shell Scripting
  • Big Data
    • Hadoop
    • Cloudera
    • Hortonworks HDP

pvdisplay Command Examples in Linux

by admin

You can use the pvdisplay command to display a list of physical volumes you’ve created if you’d like to see your progress along the way:

# pvdisplay /dev/sdb1
  “/dev/sdb1” is a new physical volume of “2.01 GiB”
  --- NEW Physical volume ---
  PV Name               /dev/sdb1
  VG Name
  PV Size               2.01 GiB
  Allocatable           NO
  PE Size               0
  Total PE              0
  Free PE               0
  Allocated PE          0
  PV UUID               0FIuq2-LBod-IOWt-8VeN-tglm-Q2ik-rGU2w7

The pvdisplay command shows that /dev/sdb1 is now tagged as a PV. Notice, however, that in the output, the VG Name is blank. The PV does not yet belong to a volume group.

The pvdisplay command shows information about the different properties of the physical volume:

  • PV Name: The name of the physical volume.
  • VG Name: The name of the volume group, if any, that is already using this physical volume.
  • PV Size: The size of the physical volume.
  • Allocatable: Indicator of whether this physical volume is usable or not.
  • PE Size: The size of the physical extents. Physical extents are the building blocks of physical volumes, as blocks are the building blocks on a computer hard drive.
  • Total PE: The total number of physical extents that is available.
  • Free PE: The number of physical extents that is still unused.
  • Allocated PE: The number of physical extents that is already in use.
  • PV UUID: A random generated unique ID for the physical volume.

pvdisplay Command Examples

1. To display the physical volume information:

# pvdisplay 

2. To only display the size of the physical volumes:

# pvdisplay -s
# pvdisplay --short 

3. To generate colon separated output:

# pvdisplay -c
# pvdisplay --colon 

4. To display the mapping of physical extents to logical volumes:

# pvdisplay -m
# pvdisplay --maps 

5. To Display output in columns, the equivalent of pvs:

# pvcreate -C
# pvcreate --columns 

6. To display the output in specified units:

# pvdisplay --units hHbBsSkKmMgGtTpPeE 

7. To display the information for a particular PV:

# pvdisplay /dev/sda2 

Filed Under: Linux

Some more articles you might also be interested in …

  1. How to configure iSCSI Initiator (client) in CentOS / RHEL 6
  2. How to Install NTP Service and Client in CentOS/RHEL 8
  3. pwck Command Examples in Linux
  4. ps: command not found
  5. OpenLDAP Server and Client Utilities list
  6. snap Command Examples in Linux
  7. CentOS / RHEL 7 : sysctl kernel parameter doesn’t take effect after reboot
  8. kpackagetool5 Command Examples in Linux
  9. How to Configure Early-kdump Support Feature in CentOS/RHEL 8
  10. findmnt Command Examples in Linux

You May Also Like

Primary Sidebar

Recent Posts

  • powertop Command Examples in Linux
  • powertop: command not found
  • powerstat: command not found
  • powerstat Command Examples in Linux

© 2023 · The Geek Diary

  • Archives
  • Contact Us
  • Copyright