Proxmox VM´s with USB disks?

Hi,
I have a Lenovo tiny with 32GB RAM and was thinking that it would be a waste of resources to install a single Storj node on that computer.

I also have some USB disks laying around, and was thinking to install ProxMox and multiple VM nodes, and then attach a USB disk to each node.
That way I get the USB disk to work on something rather than they just lay still and do nothing.

Im still new to ProxMox, does anyone have experience with running a Storj node on a VM and attaching USB drive to it?
Or would this be a bad idea ?

If you want to create other VMs on that server then proxmox is a way to go. I have an LXC Container running a storage node and a USB drive mounted on the proxmox server itself.
Alternatively if you only want to run storage nodes, it might be simpler to run several storagenode docker containers directly on the Lenovo server (installed with your favorite Linux distro) using different ports for each container.
I do both.

2 Likes

short answer: no

long answer: no no no noooooooooo

4 Likes

Please don’t teach newbies to shoot themselves in the foot by bypassing the rules and killing the network. Lost data = lost customers = lost payout, especially for such not reliable setups.

3 Likes

For multiple nodes I would not recommend to use one VM per node - why to waste resources?
The direct connection of USB disk to the VM will cause multiple issues, so it’s better to use a virtual disk instead, allow the host to manage disks, not VM.

3 Likes

Agree, actually I would even not use any VM unless there’s a strict need.

So, multiple docker instances or LXC-containers would serve the same purpose, which are really lightweight in comparison.

If I would do this, I would pass them through as block devices. Much easier. Mind the fact they need enough power, especially if they are bus powered you can run in trouble quite soon. Then it looks like you’ve got bad drives and failing file systems, but it’s just underpower …

Hi,
Not sure what you mean with block device? But I have now created a VM on Proxmox and attached a USB disk to this VM:

image

And yes agreed that the USB disk should have its own power so we don’t have to get it from the USB port :slight_smile:

In the guest OS I see the USB disk as an external HDD that can be ejected, so I guess that is not what you meant when suggesting to pass them through as block devices?

But so far its been running fine…

I will also try and get a LXC Container up and running at some point.

Every disk, when attached to a computer independent of the bus protocol (sas, nvme, scsi, sata, usb, …) will become a block device in Linux, just like a raw disk in Windows. You can list them using lsblk. The host is managing usb protocol and so on. The benefit of this, is that it’s usually more reliable than passing through USB-devices to a VM, aside from the fact it’s easier to make persistent and the fact the QEMU USB-driver had it’s issues till quite recently which I don’t know whether they already have been resolved.

To make it persistent, it’s easier to attach: /dev/disk/by-uuid/{UUID}, /dev/disk/by-label/{label} or /dev/disk/by-partlabel/{partlabel}.

Se for example: Passthrough Physical Disk to Virtual Machine (VM) - Proxmox VE

Besides, in order to prevent problems I would disable udisks2 service, to prevent auto mounting.

2 Likes