What’s actually slowing this PC down?
Pick the symptom - the matching free tool is one click away.
Increasing a VPS disk in your provider’s control panel changes the virtual disk capacity, not necessarily the partition, LVM volume, or filesystem inside Ubuntu. To use the new space, identify which layer still has the old size, enlarge the layers in order, and then grow the filesystem. For a direct ext4 partition that usually means growpart followed by resize2fs. With LVM, resize the partition, physical volume, logical volume, and finally the filesystem. XFS uses a different filesystem command.
Antihost offers Linux VPS plans with full root access, unlimited traffic on a 1 Gbps port and a 14-day free trial.
Take a current backup before changing storage. Filesystem growth can perform repair work, and an interruption or incorrect target can cause data loss.
As an Amazon Associate I earn from qualifying purchases.
What changes when you upgrade a VPS disk
A VPS disk has several layers, and each layer keeps its own size. A typical direct layout is:
virtual disk → partition → filesystem → mount point
#1 Best Overall
An LVM layout inserts three additional concepts:
virtual disk → partition → physical volume (PV) → volume group (VG) → logical volume (LV) → filesystem → mount point
Your provider can enlarge only the virtual disk. Ubuntu will continue reporting the old free space until every required layer is expanded. A filesystem utility cannot enlarge a partition, and a partition utility cannot enlarge a filesystem. Applying a command to the wrong device is one of the most common causes of failed or dangerous resizes.
Free tools Windows power users keep installed
One-click scans. No signup required.
Before you start: prerequisites and safety checks
Back up important data
Ubuntu recommends backing up data before filesystem resizing because the operation can include consistency checks and repair work. Ubuntu’s LVM guidance also recommends backups and notes that data loss remains possible even when LVM verifies whether an operation can be performed. Keep a backup that is independent of the VPS disk, and confirm that you know how to restore it.
Confirm that the provider-side upgrade is complete
Use the VPS provider’s control panel to increase the disk. Do not begin the guest-side procedure until the new virtual capacity is assigned. Some platforms expose the larger disk immediately; others require a reboot or a device rescan. If Ubuntu still sees the original disk size, stop at the detection stage and consult the provider’s procedure rather than modifying partitions.
Keep an administrative session available
Use a root shell or a user with sudo. If the resize is performed over SSH, keep a second session or out-of-band console available. A lost SSH connection does not necessarily mean the operation stopped, so check the result before repeating a command.
Inventory the storage layout
Run these commands before changing anything and save their output:
lsblk -o NAME,SIZE,TYPE,FSTYPE,MOUNTPOINTS
df -Th
findmnt /
lsblk shows disks, partitions, and logical volumes; df -Th shows mounted filesystems, types, and their currently usable sizes; and findmnt / identifies the device and filesystem type used for the root mount.
If the output suggests LVM, collect its complete state as well:
Rank #2
sudo pvs
sudo vgs
sudo lvs -o lv_name,vg_name,lv_size,lv_path,devices
Look for the first layer whose size is smaller than the disk or layer above it. For example, if lsblk shows a 100 GB disk but a 40 GB partition, the partition is the next layer to grow. If the partition is 100 GB but the physical volume reports 40 GB, resize the PV. If the VG has free extents but the root LV is still 40 GB, extend the LV. If all block devices are large but df still shows 40 GB, grow the filesystem.
Choose the correct workflow
| Layout or filesystem | Required sequence | Filesystem growth command |
|---|---|---|
| Direct partition with ext2, ext3, or ext4 | Grow the partition, then the filesystem | resize2fs /dev/device |
| LVM with ext2, ext3, or ext4 | Grow partition, PV, LV, then filesystem | resize2fs /dev/mapper/volume |
| LVM or direct partition with XFS | Grow the block-device layers, then grow XFS | xfs_growfs /mountpoint |
The device names in these examples are illustrations. Substitute the paths confirmed by findmnt, lsblk, and the LVM commands. Do not infer a device name from another server or from a tutorial.
Workflow A: a direct partition with ext4
1. Confirm the disk and partition numbers
A common BIOS-style device might appear as /dev/vda with root on /dev/vda1; another system may use /dev/sda2. NVMe devices include the disk “p” separator, such as /dev/nvme0n1p3. In every case, identify the disk and the numbered partition from lsblk.
2. Install or locate growpart
On Ubuntu, growpart is commonly supplied by the cloud-guest-utils package. If the command is missing, install that package using your normal Ubuntu package-management process, provided the system has repository access. Check the command before proceeding:
command -v growpart
growpart --help
3. Extend the partition
The growpart utility extends a numbered partition to fill available space, ending at the disk end or immediately before the next partition. Its syntax is the disk device followed by the partition number, not the complete partition path:
sudo growpart /dev/vda 1
For an NVMe example:
sudo growpart /dev/nvme0n1 3
Read the proposed change carefully. If another partition follows the target, growpart can use only the contiguous free space before that next partition. Do not delete or recreate partitions simply to make a command fit; stop and take a partition-layout backup if the expected free space is not adjacent.
4. Make the ext4 filesystem use the new partition space
The resize2fs program expands ext2, ext3, and ext4 filesystems, but it does not change partition size. Run it against the enlarged partition, not the whole disk:
sudo resize2fs /dev/vda1
Replace the path with the partition that contains the root filesystem. ext4 growth is normally possible while mounted, but the command still needs the correct target and a healthy filesystem. If it reports filesystem errors, follow the repair guidance and do not force the operation blindly.
Rank #3
5. Verify each layer
lsblk -o NAME,SIZE,TYPE,FSTYPE,MOUNTPOINTS
df -Th
findmnt /
The partition and filesystem should now show the intended capacity. df may show slightly less space than lsblk because filesystem metadata and reserved space are not available for ordinary files.
Workflow B: LVM with an ext4 root filesystem
LVM requires a separate operation for each layer. A common arrangement is a partition such as /dev/vda3 containing an LVM PV, a VG named ubuntu-vg, and a root LV represented by a path such as /dev/mapper/ubuntu--vg-ubuntu--lv. Use the names reported on your server.
Recommended Free Tools
1. Grow the partition that contains the PV
First confirm the PV’s backing device with pvs and lvs -o ... devices. Then extend that numbered partition:
sudo growpart /dev/vda 3
If the PV occupies the whole disk rather than a partition, there is no partition step; verify that fact before running any command.
2. Resize the physical volume
Tell LVM that the PV can use the enlarged partition:
sudo pvresize /dev/vda3
Check the result:
sudo pvs
sudo vgs
The VG should now show additional free space. If it does not, recheck that the partition really grew and that pvresize targeted the PV, not the LV.
Do these 3 things before closing this tab:
1Clear out junk files and repair common Windows errors2Fix the driver behind crashes, sound loss and screen glitches3Repair Windows errors before they cause bigger problems3. Extend the logical volume
Identify the root LV path with findmnt / and lvs. To allocate all currently free extents in the VG:
sudo lvextend -l +100%FREE /dev/mapper/ubuntu--vg-ubuntu--lv
Using +100%FREE consumes all free space in that VG. If you need to retain space for another LV, use a specific size instead, such as an explicitly calculated extent or capacity, after checking the VG’s free space. LVM can expand a mounted volume when the filesystem on it supports online growth, as Ubuntu’s server documentation notes.
Rank #4
4. Grow the ext4 filesystem on the LV
Because the filesystem sits inside the LV, run resize2fs against the LV path:
Crashes, No Sound, or Screen Glitches?
Random freezes, missing sound and display glitches usually trace back to one bad driver. Find and replace yours safely.Free scan · under a minuteWindows Errors? Fix Them Before They Spread
Repair common Windows errors and clear accumulated junk for a smoother, more stable PC - no reinstall needed.Free scan · no reinstallsudo resize2fs /dev/mapper/ubuntu--vg-ubuntu--lv
Some LVM versions offer lvextend -r to resize the filesystem as part of the LV extension. That convenience still depends on filesystem detection and support. The explicit sequence—extend the LV, identify the filesystem, then run its dedicated tool—makes the boundary between block-device and filesystem changes visible and is easier to troubleshoot.
5. Verify the LVM chain
sudo pvs
sudo vgs
sudo lvs -o lv_name,vg_name,lv_size,lv_path,devices
lsblk -o NAME,SIZE,TYPE,FSTYPE,MOUNTPOINTS
df -Th
The PV should include the enlarged partition, the VG should show the space you allocated, the LV should have its new size, and df should report the larger filesystem.
Workflow C: XFS and other filesystems
Identify the filesystem before choosing a command
The filesystem type appears in df -Th, findmnt -no SOURCE,FSTYPE /, and the FSTYPE column of lsblk. Do not run resize2fs on XFS; it is an ext-family utility.
Grow an XFS filesystem
After enlarging the direct partition or all required LVM layers, use the XFS utility with the mounted directory:
sudo xfs_growfs /
Replace / with the relevant mount point when growing another filesystem. XFS growth is designed for a mounted filesystem. Ensure the xfsprogs utilities are installed, and check the command’s output for errors before moving on.
Do not assume another filesystem behaves like ext4
Other filesystems have their own tools, support matrices, and online/offline rules. Verify the filesystem-specific procedure from the Ubuntu release documentation and the filesystem utility’s manual page. The block-device sequence—partition, PV, VG, and LV—still must be completed first when those layers exist.
Online versus offline resizing
Growing and shrinking are different operations. The procedures above are for growth after adding disk capacity. Never apply a grow procedure to make a filesystem smaller. Shrinking generally requires a filesystem-specific order and often an unmounted or offline filesystem; the partition must not be reduced before the filesystem has safely been reduced.
Best Value
For growth, ext4 and XFS commonly support online expansion under the conditions documented for the filesystem and kernel. Ubuntu specifically states that LVM can expand a mounted partition when the filesystem supports it. “Mounted” does not mean “risk-free”: backups, correct device identification, and post-operation checks remain necessary. If a filesystem tool says it cannot operate online, schedule downtime, unmount the filesystem where required, and follow that filesystem’s offline sequence instead of forcing it.
The Tool Desk
Outbyte PC Repair FREERepair Windows errors before they cause bigger problemsFix Now →Outbyte Driver Updater FREEFix the driver behind crashes, sound loss and screen glitchesFind Drivers →Using cloud-init to automate root expansion
Many cloud images use cloud-init to perform first-boot storage expansion. Its growpart module enlarges the root partition, while the resizefs module enlarges the filesystem afterward. The modules are intended to be paired: when growpart resizes the root partition, resizefs can resize the root filesystem as well.
Example cloud-init configuration
#cloud-config
growpart:
mode: auto
devices:
- /
resize_rootfs: true
The root device is represented by / in the cloud-init example. Depending on the image and cloud-init version, resize_rootfs can be enabled, disabled, or set to a non-blocking mode. Non-blocking mode lets boot continue while resizing runs, which can change when the larger capacity becomes visible to services.
Check whether automation actually ran
Do not assume a larger provider disk was handled automatically. Inspect cloud-init’s state and logs:
cloud-init status --long
sudo journalctl -u cloud-init -b
sudo journalctl -u cloud-init-local -b
Confirm that the image includes the relevant modules, that they were enabled in the cloud-init configuration, and that the root layout is one the modules can expand. If logs show that growpart ran but resizefs did not, inspect the filesystem type and module configuration before performing a manual filesystem resize.
Quick wins for a faster PC:
Repair Windows errors before they cause bigger problemsFix Now →Fix the driver behind crashes, sound loss and screen glitchesFind Drivers →Clear out junk files and repair common Windows errorsFree Scan →Why the size still looks unchanged
The guest never detected the larger virtual disk
If lsblk reports the old disk capacity, the problem is below Ubuntu’s partition and filesystem layers. Check the provider operation, required reboot, and any documented device-rescan procedure. Do not run growpart until the disk itself shows the additional sectors.
The partition did not expand
If the disk is larger but the partition is not, verify that you supplied the disk and partition number in the correct growpart form. Check for a partition after the target; growpart stops before the next partition. A non-contiguous layout may require a planned partition move or backup-and-restore strategy rather than an in-place grow.
The PV or VG still has the old size
When pvs shows the old PV size, run pvresize on the confirmed PV device after the partition has grown. When vgs shows free space but the root LV remains small, extend the intended LV. If the VG has no free space, check that you resized the correct PV and that another LV did not consume the new extents.
The block device is larger but df is not
This means the filesystem has not been grown, or the filesystem tool was aimed at a different device. Use findmnt / to map the mount point to its source. Run resize2fs only for ext-family filesystems, or xfs_growfs for XFS, against the confirmed partition or LV.
The Tool Desk
Outbyte Driver Updater FREEScan for outdated or missing drivers - takes under a minuteDriver Scan →Outbyte PC Repair FREEClear out junk files and repair common Windows errorsFree Scan →The command reports errors or the system becomes unhealthy
Stop issuing additional resize commands. Capture the exact output, review kernel messages with dmesg or journalctl -k, and compare the current layout with your saved inventory. If filesystem checks are requested, use the filesystem’s documented repair process and a backup or snapshot before attempting recovery. Repeating a command against an uncertain target can make the situation worse.
Quick Recap
A verification checklist
- The provider’s virtual disk upgrade is complete.
lsblkshows the larger disk and the intended partition size.- The filesystem source from
findmnt /matches the device you changed. - For LVM,
pvs,vgs, andlvsshow the expected PV, VG, and LV capacities. - The filesystem-specific growth command completed without an error.
df -Threports the larger mounted filesystem.- Applications can create files in the newly available space, and monitoring reflects the new capacity.
Key distinctions to remember
growpartchanges a partition boundary. It does not resize the filesystem inside that partition.pvresizechanges LVM’s view of a physical volume. It does not enlarge a logical volume or filesystem.lvextendenlarges an LV. It does not always resize the filesystem unless you deliberately use a supported filesystem-resize option.resize2fsgrows ext2, ext3, and ext4. It does not manipulate partition size and is not an XFS tool.xfs_growfsgrows XFS. Use the mounted directory and confirm all underlying block-device layers are already larger.- Cloud-init is configuration-dependent. Its growpart and resizefs modules work only when enabled and supported by the image.
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.




