Block Storage
Block storage is a disk volume attached to a server and formatted with a filesystem. The operating system sees it as a normal disk. Block storage is used for databases, application data, and extra VPS disks.
Uses
Databases need block storage because they require direct read and write access with low latency. Docker can also use block storage for persistent volumes. Applications that write many small files, such as PHP sessions or cache, usually fit block storage better than object storage.
Block storage can be separated from the system disk. That lets you replace or grow the data volume without rebuilding the server. Volume snapshots also make rollback easier before an upgrade.
Setup flow
After the volume is attached from the provider panel, check it with lsblk. Create a filesystem with mkfs.ext4 /dev/vdb, then mount it at the target directory, for example mount /dev/vdb /var/lib/mysql. Add an entry to /etc/fstab so it stays mounted after a reboot.
Verify the mount with df -h and findmnt. Make sure you use the correct device. Formatting the wrong disk can erase system data. For databases, stop the service or take a consistent snapshot before moving data.
What to watch for
Do not look only at capacity. For a database, IOPS and latency matter more than disk size. Start with enough volume, monitor usage, and grow before it fills. If the app writes many small files, test filesystem performance before production.
A block storage snapshot is not always consistent with a database that is writing. Stop the database briefly, use freeze mode, or run a logical backup before the snapshot. Test a restore, not just the snapshot.
When growing a volume, the filesystem may need a separate resize. On Linux, resize2fs or xfs_growfs is required after the volume grows. Without that step, the extra space is not usable.
Context
Block storage is different from Object Storage. For disk redundancy, see RAID. For performance, see NVMe SSD. For whole-server rollback, see VPS Snapshot.
Choose a suitable filesystem. ext4 works for many cases, while XFS is often used for large volumes. Monitor iostat -x 1, disk space, and inode usage. Run fstrim regularly on SSDs that support TRIM. Do not wait until the disk is full, because performance and consistency can degrade.
Document the mount point, volume size, and filesystem in the runbook. Test a reboot to make sure /etc/fstab is correct. If the volume holds a database, monitor latency and IOPS, not just free space.
FAQ
Is block storage the same as object storage?
No. Block storage appears as a disk and is formatted with a filesystem. Object storage is accessed through an API and stores files as objects.
Does block storage automatically become a backup?
No. A volume snapshot can help with rollback, but it is not an offsite backup. Keep a copy of the data somewhere else.
Why did disk space not increase after resizing?
The volume may have grown, but the filesystem has not. Run resize2fs for ext4 or xfs_growfs for XFS.
Disclaimer: Hosting Wiki articles are prepared for educational and reference purposes. Hosting technology keeps evolving, so some technical details may change over time.