Scenario:
I have an NVMe disk with an ext4 partition that was previously used as a directory in a Proxmox server. After reinstalling Proxmox, I’m unable to add the drive as a directory because the disk selection page shows the message "No disks unused." I need to retain the data on the drive since it contains backups of all the VMs and cannot be formatted.
The issue occurs because Proxmox VE's interface doesn't automatically recognize pre-used disks with existing filesystems as "unused." To safely add the drive back as a directory without losing the data, follow these steps:
Steps to Add the Existing Disk
Verify the Filesystem and Mount the Disk
SSH into your Proxmox server.
Identify your NVMe drive and its partition using:
or
Look for the partition (e.g.,
/dev/nvme0n1p1
).Check the filesystem to ensure it's still intact:
If it shows as an ext4 filesystem, you're good to proceed.
Mount the partition to a temporary directory to confirm its contents:
Ensure you see the backup files.
Create a Permanent Mount Point
Decide where you want to mount the drive. For example:
Edit
/etc/fstab
to automatically mount the partition on boot:Add an entry similar to this:
Replace
/dev/nvme0n1p1
with your actual device path.Mount the disk:
Add the Directory to Proxmox Storage
- Go to the Proxmox web interface.
- Navigate to Datacenter > Storage > Add > Directory.
- In the "Directory" field, input the mount point path (e.g.,
/mnt/nvme-backups
). - Select the desired content types (e.
g.,VZDump backup file
for backups).
Test the Setup
- Check if the backups are accessible in Proxmox.
- Ensure the directory is listed in Datacenter > Storage and shows the correct size and usage.