[TUTORIAL] USB Automount

Hi, novice user struggle to set up their first system.

I have a 5 TB USB drive that I want to pass to a guest machine. I've attempted to follow the instructions here but I am struggling. The pve7-usb-automount package is installed to the proxmox install, and the drive does show up there as /dev/sdb. I cannot for the life of me figure out how to pass that drive along to a guest OS.

I have tried to use USB passthrough unsuccessfully. I cannot seem to add the disk to an LVM pool either. I'm at a loss as to what to try next. A step by step guide would be helpful, my perusing of the admin guide so far hasn't found anything helpful, but it is more than possible I overlooked something.

Help!
o_O

Edit: I'm an idiot, I didn't realize that changes were pending and not actually implemented. Once I stopped/started the VM then all was well with the world.
 
Last edited:
Guys, after installing for tests and then removing pve7-usb-automount, something broke on my PVE Host. Basically, USB devices are no longer working anymore. Looks like an issue with usb controller driver. Anyone know what I can do to solve this problem? Thanks

usb.png

no more usb devices passthrough to VMs:usb2.png
Actually, now I can only remote acess.. keyboard is not working anymore :(
 
Last edited:
I have problem with use IT in 7.1 version

What can I do?
Some packages could not be installed. This may mean that you have
requested an impossible situation or if you are using the unstable
distribution that some required packages have not yet been created
or been moved out of Incoming.
The following information may help to resolve the situation:

The following packages have unmet dependencies:
python3-pyside2.qtcore : Depends: python3 (< 3.8) but 3.9.2-3 is to be installed
E: Unable to correct problems, you have held broken packages.
root@promox:~#
 
I am moving from Hyper-V back to Proxmox and I have a USB3.1 HDD enclosure for 4 drives and I would like to passthrough all 4 harddrives by-id as I did in the past with SATA Disks. Do I need to mount the USB Disk prior or is mounting just needed if you want to access the disk within proxmox host?

So before I mess up something, I thought I'll better ask the question here if I will need automount for my use case at all.

Thanks for the support
 
Last edited:
@bonek
Seems like you are using old apt repo files and mix with new ones?!? Make sure all your apt repos use your current system codename.

@vlaves
Dont use this tool for what you want to do. This tool is meant for automatic temporary storage mount on PVE. Just use the PVE Interface and passtrough which PVE provides.
 
@vlaves
Dont use this tool for what you want to do. This tool is meant for automatic temporary storage mount on PVE. Just use the PVE Interface and passtrough which PVE provides.
Thanks for the reply :)
Can you please just tell me, if the hard disks of an 4-bay USB3 case would be visible without any further configuration for passthrough in the command line in the folder .../by-id/... so I could just follow the guide here: Passthrough Physical Disk to Virtual Machine (VM) - Proxmox VE
 
I am using PVE 7.3-3 is there a set of instructions for installing this on this version? I see only pve5 and pve6 mentioned here.

I have a 1TB USB HDD that I would like to be able to plug-in as needed to make backups.
 
I am using PVE 7.3-3 is there a set of instructions for installing this on this version? I see only pve5 and pve6 mentioned here.

I have a 1TB USB HDD that I would like to be able to plug-in as needed to make backups.
apt-key adv --recv-keys --keyserver keyserver.ubuntu.com 2FAB19E7CCB7F415
echo "deb https://apt.iteas.at/iteas bullseye main" > /etc/apt/sources.list.d/iteas.list
apt update
apt install pve7-usb-automount
 
apt-key adv --recv-keys --keyserver keyserver.ubuntu.com 2FAB19E7CCB7F415
echo "deb https://apt.iteas.at/iteas bullseye main" > /etc/apt/sources.list.d/iteas.list
apt update
apt install pve7-usb-automount
Thank You --- that is AWESOME!

If I have already mounted this via the SHELL - and give it a name. Is there anything I need to do different? Will the Auto-Mount use the name I have given it already? If I disconnect the drive, and re-connect it - will it always come back with the same name and settings?

I want to use the 1TB EXT HDD for making backups - but disconnect it when I am not using it.

1671629355322.png
 
  • Like
Reactions: MacGyver
@fireon Are there any more updates to pve-usb-automount newer than 0.5-2?

I'm trying to figure out a couple things:

1. The automount works great for inserting new devices into an already-running host. But once the host is rebooted, most of my USB drives don't show up as mounted. I need to re-plug them to get them to automount. Is there a way to make the automount automatically do its thing at startup too? Or is there a better way to do this? FYI, fstab hasn't worked in my experience, maybe due to USB subsystem or USB drives taking too long to be detected.

2. I'm interested changing it to automount at consistent mount paths. Sometimes re-plugging drives in different orders will result in different mount paths. Changing the mount paths from /media/sd* to something like /media/<by-uuid> or /media/<by-label> should be more helpful in this scenario. I think I can make those necessary Python source changes myself. However, once changes are saved, how do you make the host recognize the updated script w/o rebooting?

BTW, does this tool or its config file have any man page or online docs?

cheers,
Mac
 
@fireon Are there any more updates to pve-usb-automount newer than 0.5-2?

I'm trying to figure out a couple things:

1. The automount works great for inserting new devices into an already-running host. But once the host is rebooted, most of my USB drives don't show up as mounted. I need to re-plug them to get them to automount. Is there a way to make the automount automatically do its thing at startup too? Or is there a better way to do this? FYI, fstab hasn't worked in my experience, maybe due to USB subsystem or USB drives taking too long to be detected.

2. I'm interested changing it to automount at consistent mount paths. Sometimes re-plugging drives in different orders will result in different mount paths. Changing the mount paths from /media/sd* to something like /media/<by-uuid> or /media/<by-label> should be more helpful in this scenario. I think I can make those necessary Python source changes myself. However, once changes are saved, how do you make the host recognize the updated script w/o rebooting?

BTW, does this tool or its config file have any man page or online docs?

cheers,
Mac
I'am not the DEV, but the code from my Colleagues (@The_Invisible) is here: https://git.styrion.net/iteas/iteas...roxmox/standalone-features/pve7-usb-automount

We don't need the tool very often anymore.
 
@fireon Are there any more updates to pve-usb-automount newer than 0.5-2?

I'm trying to figure out a couple things:

1. The automount works great for inserting new devices into an already-running host. But once the host is rebooted, most of my USB drives don't show up as mounted. I need to re-plug them to get them to automount. Is there a way to make the automount automatically do its thing at startup too? Or is there a better way to do this? FYI, fstab hasn't worked in my experience, maybe due to USB subsystem or USB drives taking too long to be detected.

2. I'm interested changing it to automount at consistent mount paths. Sometimes re-plugging drives in different orders will result in different mount paths. Changing the mount paths from /media/sd* to something like /media/<by-uuid> or /media/<by-label> should be more helpful in this scenario. I think I can make those necessary Python source changes myself. However, once changes are saved, how do you make the host recognize the updated script w/o rebooting?

BTW, does this tool or its config file have any man page or online docs?

cheers,
Mac
Hello Mac,
do you already have a solution for your second point?

Would also like to always use the same path here!

Thanks very much :)
cheers,

Kev
 
Can you clarify?: This is integrated, more or less, into PVE 8, correct? It seems to be, but your reply above is ambiguous at some level without a direct statement.
 
Can you clarify?: This is integrated, more or less, into PVE 8, correct? It seems to be, but your reply above is ambiguous at some level without a direct statement.
We have not tested it on PVE8 or adapted it for that. Maybe it works without doing anything, but maybe not. As said at our customers this function is no longer needed, because there is a backup server everywhere, besides it is not the best from a security point of view.
 
PVE 8

Don't bother with automount, while it would be nice, PVE8 is much better with USB disks.

1. Plug in your USB device
2. In the Proxmox GUI look under the node you plugged into, "disks" section. Note the USB disk/partition if any (ie /dev/sdc1)
3. Make a temporary mount point (ie /mnt/usb)
4. Go to a shell and mount the usb drive (ie mount /dev/sdc1 /mnt/usb)
5. If you like, go to Datacenter, Storage and add your mount point as "directory" storage.

I'm making a lot of assumptions on what one might want to do. I used automount on my PVE7 systems for easy transfer of VMs between nodes that were either not clustered or not on the same network. I came back looking for a PVE8 update since I needed to grab a very old backup I just happened to have on USB. The above worked fine for that.

As a side note, we have been using Proxmox backup server for a while now and most of what we ever did with USB we do now on the backup server. Easy to setup, does not need a lot of CPU or RAM, just storage. You add it as a storage device to your PVE server(s) and it is great for scheduled or manual backups or simple VM moves on non clustered nodes.
 
  • Like
Reactions: maleko48
PVE 8

Don't bother with automount, while it would be nice, PVE8 is much better with USB disks.

1. Plug in your USB device
2. In the Proxmox GUI look under the node you plugged into, "disks" section. Note the USB disk/partition if any (ie /dev/sdc1)
3. Make a temporary mount point (ie /mnt/usb)
4. Go to a shell and mount the usb drive (ie mount /dev/sdc1 /mnt/usb)
5. If you like, go to Datacenter, Storage and add your mount point as "directory" storage.

I'm making a lot of assumptions on what one might want to do. I used automount on my PVE7 systems for easy transfer of VMs between nodes that were either not clustered or not on the same network. I came back looking for a PVE8 update since I needed to grab a very old backup I just happened to have on USB. The above worked fine for that.

As a side note, we have been using Proxmox backup server for a while now and most of what we ever did with USB we do now on the backup server. Easy to setup, does not need a lot of CPU or RAM, just storage. You add it as a storage device to your PVE server(s) and it is great for scheduled or manual backups or simple VM moves on non clustered nodes.
Is there a good way to test system throughput that will list average / peak transfer rates? I am curious if my 2 consumer SATA SSDs can perform any better than 50MB/s average transfer rate while in ZFS RAID1 mirror w/16GB RAM on a clean install. currently just testing using some 5+GB ISO transfers.

On ProxMox 7.4 I could use the web GUI, but on 8.1 the web GUI freezes on most larger transfers over 1GB in size.

Even when using ProxMox 8.1 and SCP from a Windows 10 host to perform the transfer across LAN the CLI stops updating every so many seconds and seems to freeze and hitch, though it does complete the uploads, albeit at lackluster speeds.
 
Is there a good way to test system throughput that will list average / peak transfer rates? I am curious if my 2 consumer SATA SSDs can perform any better than 50MB/s average transfer rate while in ZFS RAID1 mirror w/16GB RAM on a clean install. currently just testing using some 5+GB ISO transfers.

On ProxMox 7.4 I could use the web GUI, but on 8.1 the web GUI freezes on most larger transfers over 1GB in size.

Even when using ProxMox 8.1 and SCP from a Windows 10 host to perform the transfer across LAN the CLI stops updating every so many seconds and seems to freeze and hitch, though it does complete the uploads, albeit at lackluster speeds.
FYI, this needs to be reposted as a new thread as this comment has nothing to do with this thread.
 
Last edited:

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!