Problem with "mount --bind"

A

amicobromo

Guest
Good morning,
I'm writing because I have a problem that I can't fix following the istructions I found on this forum.

I installed a CT (debian7.0-x86_64) and I can find the file system:

root@proxmox:/var/lib/vz/private/102# ls
bin
boot
dev
...

I mounted a NAS file system in /tmp/nas, and it works

root@proxmox:/var/lib/vz/private/102# ls /tmp/nas
file1
file2

I tried to mount that directory inside le CT:

root@proxmox:/var/lib/vz/private/102# mount --bind /tmp/nas/ /var/lib/vz/private/102/nas

root@proxmox:/var/lib/vz/private/102# ls var/lib/vz/private/102/nas
file1
file2

When I try to look inside /nas from the OS installed in CT I can find any files inside the folder:

amicobromo@julia:~$ ls /nas
[empty folder]

Where is the error?

Thank you very much!

Francesco
 

Thank you for your reply, but still it doesn't work.

I am a beginner regarding this type of virtualization, but the point is that I can not understand why if from the host ("Proxmox") I can see the mounted contents inside the
folder of the container, when I work from the container OS this folder is empty. :confused::confused:
 
When you start a container, it mounts /var/lib/vz/private/102 to /var/lib/vz/root/102 (and use that at runtime),
 

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!