TrueNAS VM, autofs mount, dependent LXCs?

wespiard

New Member
Oct 1, 2024
3
0
1
I'm running Proxmox VE 8.2.7. I have a TrueNAS Core VM, and a few of my unprivileged LXCs access an NFS share provided by the TrueNAS VM via a bind mount.

The solution I ended up with is using autofs to mount the TrueNAS VM's share to the Proxmox host and then bind mount that share to the unprivileged LXCs. To get this to work, I have to use a startup delay of 30-60 seconds after the VM starts, or the LXCs will fail to boot (since the bind mount directory doesn't exist instantaneously).

I'm wondering the following: is there is a way to do this without using autofs?
 
Maybe setting the start order of the TrueNAS to be earlier than the CT's that need it. You can also add a delay before the startup moves on to the next VM/CT.

ETA: I use autofs for this as well, although I have no bind mounts. I just make sure that the NFS VM is started before any of the ones that depend on it and it works fine.
 
Last edited:
  • Like
Reactions: wespiard
Maybe setting the start order of the TrueNAS to be earlier than the CT's that need it. You can also add a delay before the startup moves on to the next VM/CT.

ETA: I use autofs for this as well, although I have no bind mounts. I just make sure that the NFS VM is started before any of the ones that depend on it and it works fine.

As a matter of fact, that's what I'm doing:

To get this to work, I have to use a startup delay of 30-60 seconds after the VM starts

I only chose bind mounts so that I didn't have to install autofs inside the LXCs.
 

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!