[SOLVED] Import disks from old Proxmox VE installation

Adrian W.

New Member
Dec 7, 2022
5
0
1
Hi,

recently, one of my hosts died since the drive went corrupt.
I installed Proxmox to a new Drive and was able to restore the VM configurations and else use a backup I had luckily done a month before the drive went corrupt.
All of my VMs are now back up and running, but I had to manually mount the drives to get them back up and running.
Now, I want them to also be available at boot so that I don't have to manually mount them or do a manual cron job (since somehow this never works.

My Idea was to do it like Proxmox does it since this seems to be the cleanest way to me. However, I was not able to find where and when Proxmox mounts the Drives.
My Drives are only "Directory" drives, so nothing special. Does somebody know where Proxmox Originally stores the Data? is it stored in some sort of a Database? Is there an option to access or add an entry to this database?

Mit freundlichen Grüßen
Adrian
 
Last edited:
Proxmox VE uses systemd-mount to mount directory storage. Mounts are specified by unit configuration files at /etc/systemd/system/mnt-pve-<storage name>.mount

Here is an example:

Code:
# cat /etc/systemd/system/mnt-pve-diri.mount
[Install]
WantedBy=multi-user.target

[Mount]
Options=defaults
Type=ext4
What=/dev/disk/by-uuid/cdd71163-d911-47b9-985c-c6dcdcfd9bec
Where=/mnt/pve/diri

[Unit]
Description=Mount storage 'diri' under /mnt/pve
 
Hi Fillip,

thank you for the Fast answer.

I seem to already have tried to do it this way, but somehow it didn't work (I just restarted my Server a few days ago and today I saw that drive SSD2 wasn't mounted).

My entry was like this:

Code:
root@ss3:/etc/systemd/system# cat mnt-pve-SSD2.mount
[Install]
WantedBy=multi-user.target

[Mount]
Options=defaults
Type=ext4
What=/dev/disk/by-uuid/de90990f-XXX-1234-XXX-XXXXXXXXXXXX
Where=/mnt/pve/SSD2

[Unit]
Description=Mount storage 'SSD2' under /mnt/pve

of course, I checked that the UUID is the correct one, but seems like it didn't mount. (I replaced most of the UUID wth 'X' and '1234' in this post, in the original config the uuid doesn't look like that of course)

Regards,
Adrian
 
Did you enable the mount?
Code:
systemctl enable mnt-pve-SSD2.mount
 
Hi,

I feel a bit embarrassed to admit it, but I guess I didn't... let me check if it will work after activating and rebooting this one drive.
Thank you!

Regards / Mit freundlichen Grüßen
Adrian
 
Hello,

(T_T) It was that I did not activate the storage configs. Thank you very much!!! I'ts now working!

Regards
Adrian
 

About

The Proxmox community has been around for many years and offers help and support for Proxmox VE, Proxmox Backup Server, and Proxmox Mail Gateway.
We think our community is one of the best thanks to people like you!

Get your subscription!

The Proxmox team works very hard to make sure you are running the best software and getting stable updates and security enhancements, as well as quick enterprise support. Tens of thousands of happy customers have a Proxmox subscription. Get yours easily in our online shop.

Buy now!