Proxmox and remote folder issues

Astaoth

Member
Aug 31, 2021
11
0
6
54
Hi,

I've 2 issues with Proxmox and a remote folder :

1 :
I've some VM disk storage on a directory, which is reachable through a sshfs mountpoint. I manage this mount point with my fstab and ssh keys in order to automount it. And when I've an issue with it while booting this VMs, they will obviously not boot. Once I've connected myself on m proxmox, fixed the issue and mounted the sshfs director, is there a way to launch again the VMs which should be autostarted in a single command ?

2 :
I use this sshfs directory into Proxmox by adding a directory in the datacenter storage. But when the sshfs director isn't mounted, Proxmox makes in less than 10 sec a new directory inside the one which serves as the mountpoint, called "images". How could I prevent this ?

Thanks !
 
Last edited:
Hi,

I've 2 issues with Proxmox and a remote folder :

1 :
I've some VM disk storage on a directory, which is reachable through a sshfs mountpoint. I manage this mount point with my fstab and ssh keys in order to automount it. And when I've an issue with it while booting this VMs, they will obviously not boot. Once I've connected myself on m proxmox, fixed the issue and mounted the sshfs director, is there a way to launch again the VMs which should be autostarted in a single command ?

To my knowledge, no (not in a single command). But I just noticed there's a weird autostart flag [1]:

--autostart <boolean> (default = 0)
Automatic restart after crash (currently ignored).

Not sure what to think of it. I have not tested it.

Of course you can always script it with some creative qm status parsing.

2 :
I use this sshfs directory into Proxmox by adding a directory in the datacenter storage. But when the sshfs director isn't mounted, Proxmox makes in less than 10 sec a new directory inside the one which serves as the mountpoint, called "images". How could I prevent this ?

I don't know what PVE will be doing when you do this, but common way to prevent your mountpoints to be filled up by the system while unmounted is to chattr +i /mnt/xyz [2]. It certainly will not go on creating anything there though.

[1] https://pve.proxmox.com/pve-docs/qm.1.html
[2] https://manpages.debian.org/bookworm/e2fsprogs/chattr.1.en.html#i
 
  • Like
Reactions: Astaoth
I don't know what PVE will be doing when you do this, but common way to prevent your mountpoints to be filled up by the system while unmounted is to chattr +i /mnt/xyz [2]. It certainly will not go on creating anything there though.
Thanks for this command ! I didn't know it was a possible flag, I don't use them often.

To my knowledge, no (not in a single command). But I just noticed there's a weird autostart flag [1]:


Not sure what to think of it. I have not tested it.

Of course you can always script it with some creative qm status parsing.
I've checked a little for making a script, however it doesn't look like I can get the vm onboot value from qm status or qm config. Do you know how I could get if a VM has the "start at boot" option enabled ?
 

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!