Special offer. See more information about Outbyte and uninstall instructions. Please review EULA and Privacy policy.

Some links on this page are affiliate links: if you buy through them we may earn a commission, at no extra cost to you.

To create a new LVM volume group (VG), initialize a verified, unused disk partition as a physical volume (PV), then create the group:

sudo pvcreate /dev/sdb1
sudo vgcreate data-vg /dev/sdb1
sudo vgs

/dev/sdb1 and data-vg are examples, not values to copy blindly. Identify the target device first: selecting a disk or partition that holds needed data can make that data inaccessible.

What a volume group does—and what it does not

LVM organizes storage in layers:

disk or partition → physical volume (PV) → volume group (VG)
                  → logical volume (LV) → filesystem → mount point
  • A physical volume is a block device initialized for LVM, such as a partition or dedicated disk.
  • A volume group pools one or more PVs so that space can be allocated to logical volumes.
  • A logical volume is a virtual block device created from space in a VG.

A VG is not a filesystem or a directory you can mount. After making the VG, create an LV, put a filesystem on that LV, and mount it to use the space as a directory. Ubuntu documents this PV-to-VG-to-LV workflow and the resulting device paths at Manage logical volumes.

Special offer. See more information about Outbyte and uninstall instructions. Please review EULA and Privacy policy.

Check the Ubuntu release before changing storage

Ubuntu 16.04 standard security maintenance ended in April 2021, and Ubuntu 18.04 standard security maintenance ended in May 2023. Canonical lists extended security maintenance coverage through May 2026 for 16.04 and May 2028 for 18.04 under applicable Ubuntu Pro coverage; eligibility and coverage depend on the release, architecture, subscription, and support stream. See Canonical’s release cycle and ESM information. These LVM commands remain relevant for administering existing systems on those releases, but a new installation should normally use a currently supported Ubuntu release.

#1 Best Overall
Sandisk 2TB Extreme Portable SSD, Up to 1050MB/s, USB-C, USB 3.2 Gen 2, IP65 Water and Dust Resistance, Updated Firmware, External Solid State Drive, SDSSDE61-2T00-G25
  • Get NVMe solid state performance with up to 1050MB/s read and 1000MB/s write speeds in a portable, high-capacity drive(1) (Based on internal testing; performance may be lower depending on host device & other factors. 1MB=1,000,000 bytes.)
  • Up to 3-meter drop protection and IP65 water and dust resistance mean this tough drive can take a beating(3) (Previously rated for 2-meter drop protection and IP55 rating. Now qualified for the higher, stated specs.)
  • Use the handy carabiner loop to secure it to your belt loop or backpack for extra peace of mind.
  • Help keep private content private with the included password protection featuring 256‐bit AES hardware encryption.(3)
  • Easily manage files and automatically free up space with the SanDisk Memory Zone app.(5). Non-Operating Temperature -20°C to 85°C

Before you run LVM commands

Install the LVM utilities if needed

Most Ubuntu Server installations provide LVM tools when needed. On a minimal system where the commands are missing, install the lvm2 package:

sudo apt update
sudo apt install lvm2

You also need root or sudo access, a backup of any data that matters, and a target disk or partition you have confirmed is unused. Do not initialize a mounted filesystem, an operating-system device, active swap, a RAID member, or a PV already in use. If the target is part of an existing storage stack or contains data to preserve, stop and plan a migration instead.

Identify the device instead of guessing its name

Inspect block devices and their filesystems and mount points:

Special offer. See more information about Outbyte and uninstall instructions. Please review EULA and Privacy policy.
lsblk -o NAME,SIZE,TYPE,FSTYPE,MOUNTPOINTS
sudo fdisk -l
sudo blkid

For example:

NAME   SIZE TYPE FSTYPE MOUNTPOINTS
sda     80G disk
├─sda1  79G part ext4   /
└─sda2   1G part swap   [SWAP]
sdb    200G disk

Here, /dev/sdb might be the intended empty disk, but the listing alone does not prove that it is safe to use. Verify the size, mount point, filesystem, and the physical or virtual disk inventory. Device names can vary between machines and may change with hardware or virtual-machine configuration.

Stop if the device identity or contents are uncertain. A mistaken partitioning or pvcreate operation can destroy access to data. For an extra read-only signature check, use sudo wipefs -n /dev/sdb1; the -n option lists signatures without erasing them.

Rank #2
Sandisk 1TB Portable SSD, Up to 800MB/s Read Speeds, Black (Old Model)
  • Solid state performance with up to 800MB/s read speeds in a portable drive. (Based on internal testing; performance may be lower depending on host device, interface, usage conditions and other factors. 1MB=1,000,000 bytes.)
  • Back up your content and memories on a storage solution that fits seamlessly into your mobile lifestyle.
  • Take it with you on your adventures—up to two-meter drop protection means this durable drive can take a beating. (Based on internal testing.)
  • Secure it to your belt loop or backpack for extra peace of mind thanks to the tough rubber hook.
  • From Sandisk, a brand professional photographers trust to take on assignments.

Choose a partition or a whole disk

For most administrators, a partition such as /dev/sdb1 is the clearest choice. It lets you reserve part of the disk or keep a recognizable partition layout. Create a GPT partition table if appropriate, make a partition covering the intended space, mark it as Linux LVM, and then initialize that partition. Ubuntu’s LVM documentation describes creating a partition and marking it for LVM before running pvcreate; the exact partitioning steps depend on the tool and partition-table format.

A dedicated, confirmed-empty disk can also be used directly as a PV, for example sudo pvcreate /dev/sdb. Treat this as a deliberate choice, not a shortcut: preparing a whole disk may require removing partition-table information and destroy data on it. The Ubuntu 18.04 pvcreate manual documents this risk.

Special offer. See more information about Outbyte and uninstall instructions. Please review EULA and Privacy policy.

Create a new VG from one partition

Once the partition is created and verified as the intended unused device, initialize it as a PV and create a new VG. Replace both example values with your chosen device and group name.

  1. Initialize the partition:
    sudo pvcreate /dev/sdb1
  2. Create the new group:
    sudo vgcreate data-vg /dev/sdb1
  3. Verify the PV and VG:
    sudo pvs
    sudo vgs
    sudo vgdisplay data-vg

pvs should show the partition and the VG that owns it. vgs should show the group’s PV count and free space. vgdisplay shows more detail. Ubuntu’s storage guide uses the same explicit pvcreate then vgcreate sequence and recommends these inspection commands.

Create a VG from multiple PVs

To pool multiple verified partitions into one new VG, initialize them and name them together when creating the group:

Rank #3
SSK Portable SSD 500GB External Solid State Hard Drive USB C Up to 1050MB/s
  • Capacity Display Variance: 500GB external ssd often appears as around 465GB on Windows. MacOS can show full 500 GB capacity. This is binary calculation difference and doesn’t affect SSD hard drive actual physical storage
  • 1050 MB/s Speed: Instantly access to your files with blazing-fast 10Gbps external SSD read up to 1050MB/s and write up to 1000MB/s. LED Light indicates USB SSD instant activity
  • Data Security: Solid state drives S.M.A.R.T. health diagnostics​ and adaptive TRIM optimizing data block management ensures consistent write speeds and extends the longevity of the portable SSD
  • USB-C & USB-A Cable: Both cables featuring rapid USB 3.2 Gen2, this USB SSD effortlessly bridges devices, enabling seamless cross-platform file transfers and backup between computers, smartphones, tablets and iPhone
  • Always Fast: No slowdowns for large file transfers. With SLC caching (25% of current available capacity allocated as high-speed cache), this external SSD delivers steady 10Gbps for transfers within the cache capacity
sudo pvcreate /dev/sdb1 /dev/sdc1
sudo vgcreate data-vg /dev/sdb1 /dev/sdc1
sudo pvs
sudo vgs

The vgcreate command accepts a VG name followed by one or more PV paths; see the Ubuntu vgcreate manual. Pooling capacity is not the same as redundancy. A VG does not automatically mirror data or protect against a disk failure. If an LV has extents on a failed PV, that LV may become unavailable or corrupted. Use an appropriate RAID or mirroring design, replication, and backups when fault tolerance is required.

Special offer. See more information about Outbyte and uninstall instructions. Please review EULA and Privacy policy.

Add a PV to an existing VG

If the group already exists, do not use vgcreate again. Inspect the current layout, initialize the new partition, then add it with vgextend:

sudo vgs
sudo pvs
sudo pvcreate /dev/sdd1
sudo vgextend data-vg /dev/sdd1
sudo pvs
sudo vgs
sudo vgdisplay data-vg

Here, data-vg must be the existing group name. The Ubuntu 18.04 pvcreate manual distinguishes creating a new group with vgcreate from adding a PV to an existing one with vgextend.

Create a logical volume and filesystem if you need mounted storage

Creating a VG leaves its space in the pool; it does not allocate it to an LV. To make a 100 GB LV in data-vg, run:

sudo lvcreate --name data-lv --size 100G data-vg
sudo lvs
lsblk

The new block device is available as /dev/data-vg/data-lv (also represented under /dev/mapper/). Ubuntu’s LVM guide documents the same lvcreate syntax and device-path conventions.

What’s actually slowing this PC down?

Pick the symptom - the matching free tool is one click away.

Special offer. See more information about Outbyte and uninstall instructions. Please review EULA and Privacy policy.
Rank #4
Sale
Seagate 2TB Portable Hard Drive | USB 3.0 (STGX2000400)
  • Easily store and access 2TB to content on the go with the Seagate Portable Drive, a USB external hard drive
  • Designed to work with Windows or Mac computers, this external hard drive makes backup a snap just drag and drop
  • To get set up, connect the portable hard drive to a computer for automatic recognition no software required
  • This USB drive provides plug and play simplicity with the included 18 inch USB 3.0 cable
  • The available storage capacity may vary.

If the LV is new and contains no data to preserve, create a filesystem on the LV—not on the VG or PV:

sudo mkfs.ext4 /dev/data-vg/data-lv

This formats the LV. Do not run it on a device containing needed data. After formatting, create a mount point and mount the LV there; mounting and persistent /etc/fstab configuration are separate steps.

Verify the final storage layout

Use these commands to check each layer:

sudo pvs
sudo vgs
sudo lvs
lsblk -f
sudo vgdisplay data-vg
  • pvs identifies PV devices and their owning VGs.
  • vgs reports VG capacity, PV and LV counts, and unallocated free space.
  • lvs lists logical volumes and their sizes.
  • lsblk -f shows the device hierarchy, filesystem types, and mount points.
  • vgdisplay provides detailed information about the named group.

A VG can have free space while lvs lists no logical volumes; that means storage has been pooled but not yet allocated to an LV.

Independent reader supportYour contribution helps us test, update, and keep practical guides available for everyone.Support on Ko-Fi

Troubleshoot common errors safely

The volume group name already exists

Check sudo vgs and sudo vgdisplay. If the existing group is the one you intend to use, add the PV with vgextend. Otherwise, choose a different name. Do not remove the existing group as a routine fix: removing a VG can destroy its logical volumes and data.

Special offer. See more information about Outbyte and uninstall instructions. Please review EULA and Privacy policy.

The device has a filesystem, signature, or existing LVM label

Inspect before changing anything:

sudo wipefs -n /dev/sdb1
sudo blkid /dev/sdb1
findmnt /dev/sdb1

A reported filesystem, RAID signature, or LVM membership is a reason to stop and determine what owns the device. Do not use erase commands, pvremove, or repeated force options as generic fixes. The Ubuntu 18.04 pvcreate manual explains that force options override safety checks, including checks against reusing a PV already assigned to a VG.

Best Value
Sale
Samsung T7 Portable SSD 1TB Titan Gray, USB 3.2 Gen 2, Up to 1,050MB/s
  • MADE FOR THE MAKERS: Create; Explore; Store; The T7 Portable SSD delivers fast speeds and durable features to back up any endeavor; Build your video editing empire, file your photographs or back up your blogs all in an instant
  • SHARE IDEAS IN A FLASH: Don’t waste a second waiting and spend more time doing; The T7 is embedded with PCIe NVMe technology that brings fast read and write speeds up to 1,050/1,000 MB/s¹, making it almost twice as fast as the T5
  • ALWAYS MAKE THE SAVE: Compact design with massive capacity; With capacities up to 4TB, save exactly what you need to your drive – from large working files to game data and everything in between
  • ADAPTS TO EVERY NEED: Whether using a PC or mobile phone, count on the T7 for extensive compatibility²; It’s a true team player when it comes to heavy-duty application usage or file-saving
  • HI RESOLUTION VIDEO RECORDING: Record Ultra High Resolution (4K 60fs) videos directly onto the T7 Portable SSD with your favorite camera or mobile devices; Supports iPhone 15 Pro Res 4K at 60fps video and more³

The target is mounted or in use

Use findmnt and the system’s storage inventory to establish what is using it. Only unmount a filesystem after confirming that it is safe to do so; for a verified standalone mount, the command is sudo umount /dev/sdb1. If the device belongs to the operating system, swap, RAID, or an active LVM stack, do not proceed with this new-PV workflow.

A virtual disk or partition was enlarged

Expanding an existing PV is different from adding a new PV. After enlarging the underlying partition or disk and confirming the PV device reflects the new capacity, the relevant operation may be:

sudo pvresize /dev/sdb1
sudo vgs

Do not run pvcreate and vgextend for this case: those commands prepare and add a separate PV, rather than grow an existing one.

Special offer. See more information about Outbyte and uninstall instructions. Please review EULA and Privacy policy.

A command reports that a PV is already assigned to another group

Inspect with sudo pvs and sudo vgs to find its current owner. Do not force initialization or remove the PV label until you have confirmed that no logical volume or data depends on it.

Quick Recap

Bestseller No. 2
Sandisk 1TB Portable SSD, Up to 800MB/s Read Speeds, Black (Old Model)
Sandisk 1TB Portable SSD, Up to 800MB/s Read Speeds, Black (Old Model)
From Sandisk, a brand professional photographers trust to take on assignments.
$165.70
SaleBestseller No. 4
Seagate 2TB Portable Hard Drive | USB 3.0 (STGX2000400)
Seagate 2TB Portable Hard Drive | USB 3.0 (STGX2000400)
This USB drive provides plug and play simplicity with the included 18 inch USB 3.0 cable; The available storage capacity may vary.
$129.99

Product prices and availability are accurate as of the date/time indicated and are subject to change. Any price and availability information displayed on Amazon at the time of purchase will apply.