[SOLVED] How to permanently mount a windows network folder in an Ubuntu VM on Proxmox

curiouscase

New Member
Jul 20, 2024
15
2
3
As title implies, I want to permanently mount a network folder from my Windows 11 on an Ubuntu VM on Proxmox with read write permissions. The username for my windows is an email and the password contains characters like "!". I tried a few things and either I keep on getting error 13 permission denied which seems due to login failure or the mount only works till I restart.

I would appreciate if someone could point me to a guide on how to achieve this.
Thanks!
 
Last edited:
Hi @curiouscase , to avoid the sequence of "try this; i already did" - can you please post exactly what you tried?
Include the exact command and file output. If possible, use text encoded with CODE tags.

Cheers


Blockbridge : Ultra low latency all-NVME shared storage for Proxmox - https://www.blockbridge.com/proxmox
I am not a technical person per se and I just follow guides/tutorials to achieve what I want.

One video that I followed is this: https://www.youtube.com/watch?v=sYalClAw_wk&list=PL2MAiBWQIXNDg0-glIY8wk9EoWaP5OfJw&index=4&t=1s

Then I also tried the Ubuntu guide: https://documentation.ubuntu.com/server/how-to/samba/mount-cifs-shares-permanently/

Both these led me to error 13 permission denied.

Then I tried
Code:
sudo mount.cifs //server/path /mnt/cifs -o rw,username='abc.xyz@gmail.com',password='Abc!d12ef3g',uid=1000,gid=1000,x-systemd.automount 0 0
with
Code:
//server/path /mnt/cifs -o rw,username='abc.xyz@gmail.com',password='Abc!d12ef3g',uid=1000,gid=1000,x-systemd.automount 0 0
address to /etc/fstab. This added the mount but after restart it does not work.
 
I am not quite following what exactly you added to fstab, but if it was the second CODE'ed line - it is wrong.
Here are a few points off the top of my head:

- No filesystem type (cifs) between the mount point and the options.
- The -o is not used inside /etc/fstab.
- Quoting not required for options

At the very least it should be:L
//server/path /mnt/cifs cifs rw,username=abc.xyz@gmail.com,password=Abc!d12ef3g,uid=1000,gid=1000,x-systemd.automount 0 0

There may be more changes needed. You can continue testing by editing the fstab and then running "mount -a". If the line is correct - the mount will be established and should work after reboot.

Good luck

PS note that none of this is related to PVE installation and configuration. It is basic Linux management.
PPS PVE has its own CIFS plugin/management that does not rely on "fstab". You may want to try to get that working first. You can do so by adding "storage" with type CIFS via GUI


Blockbridge : Ultra low latency all-NVME shared storage for Proxmox - https://www.blockbridge.com/proxmox
 
Last edited:
I am not quite following what exactly you added to fstab, but if it was the second CODE'ed line - it is wrong.
Here are a few points off the top of my head:

- No filesystem type (cifs) between the mount point and the options.
- The -o is not used inside /etc/fstab.
- Quoting Not Required for Options

At the very least it should be:L
//server/path /mnt/cifs cifs rw,username=abc.xyz@gmail.com,password=Abc!d12ef3g,uid=1000,gid=1000,x-systemd.automount 0 0

There may be more changes needed. You can continue testing by editing the fstab and then running "mount -a". If the line is correct - the mount will be established and should work after reboot.

Good luck

PS note that none of this is related to PVE installation and configuration. It is basic Linux management.
PPS PVE has its own CIFS plugin/management that does not rely on "fstab". You may want to try to get that working first. You can do so by adding "storage" with type CIFS via GUI


Blockbridge : Ultra low latency all-NVME shared storage for Proxmox - https://www.blockbridge.com/proxmox
Tried those and then it again leads to error 13 permission denied
 
Tried those and then it again leads to error 13 permission denied
Can you clarify what "those" are? Does that refer to your originally pasted fstab option? Something else you tried previously? Or an attempt made based on my feedback?

You need to be more factual in your replies than "tried and it didnt work". Provide exact configuration text, commands and their output, including the actual password. If you are concerned about it - change it to something else now or later. In fact, something easy to try - create a simple "username" with alphabetic "password" - can you make that work?

Can you confirm that you were able to establish a successful mount by using mount.cifs command ?

Have you plugged your error message into a search engine and reviewed any of the advice given? I.e.: https://unix.stackexchange.com/questions/124342/mount-error-13-permission-denied


Blockbridge : Ultra low latency all-NVME shared storage for Proxmox - https://www.blockbridge.com/proxmox
 
For the benefit of other future forum user, posting the actual solution would make this thread more useful. Or at least a link to the guide you used.
Unfortunately the absence of which appears to suggest a lack of appreciation for the effort @bbgeek17 has invested in your assistance.
Here is the guide that I followed: https://askubuntu.com/questions/1341844/how-do-i-permanently-mount-a-windows-network-share-in-ubuntu

I was not sure if I should put it or not as previously it was mentioned its a basic Linux issue and not Proxmox issue.