[SOLVED] USB HDD mount to LXC

voarsh

Member
Nov 20, 2020
218
19
23
28
Hi.
Bit a of newbie question I suppose:
How do I mount a USB HDD device to a LXC?
https://pve.proxmox.com/wiki/Linux_Container#_bind_mount_points

These instructions aren't clear.

I can see my USB device on the host (lsusb) under Disks, but I don't know what to do next. Do I mount the USB device on the host under a folder?

I did:
nano /etc/pve/lxc/100.conf
Added:
lxc.cgroup.devices.allow: c 189:385 rwm
lxc.mount.entry: /dev/bus/usb dev/bus/usb none bind,optional,create=dir


On the LXC:
ls -l /dev/bus/usb/004
total 0
crw-rw-r-- 1 nobody nogroup 189, 384 Dec 1 18:35 001
crw-rw-r-- 1 nobody nogroup 189, 385 Dec 4 19:57 002

No idea what to do next.
 
Last edited:
Even when I make a ubuntu VM and add the USB device in hardware, I don't see it listed in df -Th
 
I tried to:
mount the USB on the HOST.
I made a mount point on the container.
The container gets permission denied trying to CD into the folder.
I try granting all permissions on the folder on the host and I get (chmod a+rwx) :
chmod: changing permissions of '/mnt/bindmounts/shared/': Read-only file system

But no luck
 

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!