Add another drive to VMdata

mellowism

Member
Oct 30, 2021
5
0
6
42
I am running a small server with only 2 drives. 1x60GB for the Proxmox installation, and 1x500GB for all the VM data.
The 500 disk, is reporting 81% wearout, and I have begun to experience issues the last couple of days, which I suspect has to do with this wearout. Please correct me if that is a wrong assumption.
The issue is that the Proxmox GUI is unreachable, and it is not possible to reach by ssh either. The server is reporting "Task containerd blocked for more than 120 seconds" and reading up it seems that this can be caused by resource starvation, specifically disk. Restarting the server usually works, but then it crashes again after some time.

So now I am planning on replacing the 500GB drive. Preferably with 2x500 drives in ZFS mirror. Before I do this, I have a couple of questions.

My questions are:
Can I just replace it, start Proxmox and restore VM's from backup (that is located on a NFS share on another server), or is there something else that should be done first?

Is it possible to replace the 500GB drive first, and then add another 500 drive and mirror it?

I am fairly new to this, although my Proxmox server has been running for a couple of years. So any help would be much appreciated.
 
I think the answer is a definate YES , I did same thing of wanting to increase the size of the hard drive so closed down all the VMs and backed them up to my NAS.
If you have added a hard drive directly to a VM with eg "qm set 104 -scsi1 /dev/disk/by-id/xxxxxxxxxxxxxxxx" you need to do it again after restoring the image.
Don't forget to copy the iso images etc , which are stored locally ?
 
Last edited:
I think the answer is a definate YES , I did same thing of wanting to increase the size of the hard drive so closed down all the VMs and backed them up to my NAS.
If you have added a hard drive directly to a VM with eg "qm set 104 -scsi1 /dev/disk/by-id/xxxxxxxxxxxxxxxx" you need to do it again after restoring the image.
Don't forget to copy the iso images etc , which are stored locally ?
The GUI is not reachable at all now, so can't access it anymore. Even after restart. However, the containers/VM's are still up though.
I haven't added any drives to any VM's, so hopefully that shouldn't be an issue.

Do you know if I can add another identical drive, and add that as a mirror on an already utilized drive?

Thanks for your input!
 
Do you know if I can add another identical drive, and add that as a mirror on an already utilized drive?
Yes! Please see man zpool-attach

And that is the approach I would recommend. I am not sure about the GUI capabilities, but on the command line it works this way:

Code:
zpool  attach  yourpool  /dev/disk/by-id/id-of-the-existing-single-drive   /dev/disk/by-id/your-new-drive-id

Caution: triple check your command. The standard pitfall is to add a new device as an individual vdev by accident - which is (was?) a really, really problematic fault because it can (could?) not be undone.

Good luck
 
Yes! Please see man zpool-attach

And that is the approach I would recommend. I am not sure about the GUI capabilities, but on the command line it works this way:

Code:
zpool  attach  yourpool  /dev/disk/by-id/id-of-the-existing-single-drive   /dev/disk/by-id/your-new-drive-id

Caution: triple check your command. The standard pitfall is to add a new device as an individual vdev by accident - which is (was?) a really, really problematic fault because it can (could?) not be undone.

Good luck
Yes, a stripe over multiple VDEVs can't be undone. The GUI doesn't support attaching a disk later on, but allows creating a mirror from 2 disks.
 

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!