Share one disk between multiple containers or virtual machines

banch3v

New Member
Oct 13, 2023
13
0
1
Hello,

First of all, I'd like to say that I am complete beginer. I've watched several hours Proxmox tutorials and basically everything I do is copy pase from a tutorial videos.

So here is the deal:
  1. I have a Synology / Xpenology VM which I use for NAS.
  2. I have an LXC where I run Jellyfin on debian 12 with transcoding
My goal is now to connect my NAS VM storage to that Jellyfin container.

I face several problems which I will bring down to two:
  1. I have no idea how to do it. After days of researching I couldn't find anyone whos doing something similar
  2. I don't have any ZFS for some reason: https://prnt.sc/F6aI-apmg0Ko > https://prnt.sc/oMib3-xsboyv
I feel like I am hitting the wall everytime I try to find a solution so I really hope someone can help me out here.
 
You need the right words to google: You need CIFS or NFS to share files from one machine to another.
Thanks. That was helpful input. Now I am stuck on "mount.nfs: access denied by server while mounting". I guess nothing goes smoothly in this field :)))
 
Thanks. That was helpful input. Now I am stuck on "mount.nfs: access denied by server while mounting". I guess nothing goes smoothly in this field :)))
You normally export filesystems via NFS to a host, all others do not have the right to access it. The host is the container/VM that wants to mount this nfs share.
 
Thanks. That actually helped me realize that at least my NAS is capable to accept NFS connection. I did link it to my host (https://prnt.sc/0S_sxXgNOe1E). Also gave me an idea that I can backup my the whole Proxmox on my NAS. Which is nice.

Sadly, I still can't sort it out why it does not let me connect the NFS to my jellyfin LXC... And after 5 hours of try and error I am still at level 1 :/

Any suggestions here, guys?


TBH, follwed this bellow from Chat GPT and as you can guess, I stucked at step 3: "mount -t nfs <Synology_IP>:/<shared_folder> /mnt/synology_share". It just dont let me mount the NFS... And I tried everything. I had the longest Chat GPT debugging conversation.

-------------------------------------
To link the storage from the Synology NAS VM to the LXC container running Jellyfin in Proxmox, you can use several methods. One common approach is to use NFS (Network File System) to export the storage from the Synology NAS VM and mount it on the Jellyfin LXC container. Here's a step-by-step guide:

Step 1: Configure NFS on Synology NAS VM​

  1. Enable NFS on Synology:
    • Log in to the Synology NAS VM.
    • Open the Control Panel and go to "File Services."
    • Enable NFS and set up NFS permissions for the specific directory you want to share.
  2. Create an NFS Share:
    • In the Control Panel, go to "Shared Folder."
    • Create a new shared folder or use an existing one.
    • Go to "NFS Permissions" and configure it to allow access to the IP address of your Jellyfin LXC container.

Step 2: Find the IP Address of Jellyfin LXC​

  1. Get the IP address of the Jellyfin LXC container:
    • Log in to the Proxmox web interface.
    • Navigate to the "LXC" tab and select your Jellyfin container.
    • Find the IP address assigned to the container.

Step 3: Mount NFS Share on Jellyfin LXC​

  1. Install NFS client on Jellyfin LXC:
    • Log in to the Jellyfin LXC container.
    • Install the NFS client:
      bashCopy code
      apt update
      apt install nfs-common
  2. Mount the NFS share:
    • Create a directory on the Jellyfin LXC to mount the Synology NFS share:
      bashCopy code
      mkdir /mnt/synology_share
    • Mount the NFS share:
      bashCopy code
      mount -t nfs <Synology_IP>:/<shared_folder> /mnt/synology_share
      Replace <Synology_IP> with the IP address of your Synology NAS VM and <shared_folder> with the name of the shared folder.
  3. Configure Jellyfin:
    • Update Jellyfin's media library to point to the directory you mounted.

Step 4: Automate the Mount Process (Optional)​

  1. Edit /etc/fstab (optional but recommended):
    • To automatically mount the NFS share at startup, add an entry to the /etc/fstab file:
      bashCopy code
      <Synology_IP>:/<shared_folder> /mnt/synology_share nfs defaults 0 0
      Save the file.
  2. Test the mount:
    • Run mount -a to test if the NFS share mounts without errors.
Now, your Jellyfin LXC container should have access to the storage provided by the Synology NAS VM through NFS. Make sure to adjust the configurations and paths based on your specific setup.
 
Last edited:
Thanks. That actually helped me realize that at least my NAS is capable to accept NFS connection. I did link it to my host (https://prnt.sc/0S_sxXgNOe1E). Also gave me an idea that I can backup my the whole Proxmox on my NAS. Which is nice.

Sadly, I still can't sort it out why it does not let me connect the NFS to my jellyfin LXC... And after 5 hours of try and error I am still at level 1 :/

Any suggestions here, guys?
What's your networking setup on that PVE for the LXC? Is it bridged so it gets onto the same network as the NFS share is on?
 
Definately not bridged. It sounds like something that I should've purposly done and I didn't for sure. It looks like this: https://prnt.sc/hnzAEdTx2mHD. Or perhaps it is? https://prnt.sc/vKZpWe50qXa2
It actually looks like it's bridged to vmbr0 which would share your network, is 192.168.0.1 your gateway in the network, same as what the NFS share is on? Did you try to e.g. ping it from inside the jellyfin shell by IP address? Also, what does it mean that it "does not let [you] connect?" precisely? How it fails vs what you expected from what configuration/steps is always good to describe.
 
  • Like
Reactions: banch3v
It actually looks like it's bridged to vmbr0 which would share your network, is 192.168.0.1 your gateway in the network, same as what the NFS share is on? Did you try to e.g. ping it from inside the jellyfin shell by IP address? Also, what does it mean that it "does not let [you] connect?" precisely? How it fails vs what you expected from what configuration/steps is always good to describe.
Ok, I'll share a bit more info about what I did. First of all, my setup:
- Jellyfin LXC - https://prnt.sc/VHr41o5IY1qP
- Synology - https://prnt.sc/etiDrKGsPCt6

So they both share same gateway and have different IP.

I've followd GPT's tutorials and when I went to step 3, I've stucked for several ours on mounting the NFS.

I use the following command 'mount -t nfs -o nfsvers=3 192.168.0.249:/volume1/MediaServer /mnt/synology_share' based on this path here: https://prnt.sc/o8FDdrCZWsTC

But no matter what I did I didn't manage to go trough that denial - https://prnt.sc/BenICcIm33fV. Some of the things were: disable firewall, provide different rights, pinging https://prnt.sc/oVxUrVkROGAx (no problem), access SSH to verify that the config is correct, and many many other things that GPT asked me to do.

Perhaps, tomorrow, I'll try to install jellyfin on a VM instead of container and try again... Maybe I'll have more luck using VM.

My ultimate goal, as I meantioned is to connect my NAS media dir with Jellyfin and stream from there.
 
Last edited:
So they both share same gateway and have different IP.
That's good.

I've followd GPT's tutorials and when I went to step 3, I've stucked for several ours on mounting the NFS.

I use the following command 'mount -t nfs -o nfsvers=3 192.168.0.249:/volume1/MediaServer /mnt/synology_share' based on this path here: https://prnt.sc/o8FDdrCZWsTC
So for full disclosure, I do not use Synology, so not familiar with GUI, I do however know how the NFS server runs that it handles behind all that. It might be that someone who has a look at your screenshot immediately gets an idea, but to get that someone's attention, I would adjust your threat title to include "Synology NFS share". Now with that out of the way ...
But no matter what I did I didn't manage to go trough that denial - https://prnt.sc/BenICcIm33fV. Some of the things were: disable firewall, provide different rights, pinging https://prnt.sc/oVxUrVkROGAx (no problem), access SSH to verify that the config is correct, and many many other things that GPT asked me to do.

This GPT is quite funny, isn't it? :) Alright, I would basically start troubleshooting (which you already did good with the pings) and now on the jellyfin try out what this one says:
Code:
showmount -e 192.168.0.294

Perhaps, tomorrow, I'll try to install jellyfin on a VM instead of container and try again... Maybe I'll have more luck using VM.

Pretty sure the LXC container is just fine for your setup.

My ultimate goal, as I meantioned is to connect my NAS media dir with Jellyfin and stream from there.

Yes, it's just about getting the export and rights correct, that's literally all to it.
 
Last edited by a moderator:
That's good.


So for full disclosure, I do not use Synology, so not familiar with GUI, I do however know how the NFS server runs that it handles behind all that. It might be that someone who has a look at your screenshot immediately gets an idea, but to get that someone's attention, I would adjust your threat title to include "Synology NFS share". Now with that out of the way ...


This GPT is quite funny, isn't it? :) Alright, I would basically start troubleshooting (which you already did good with the pings) and now on the jellyfin try out what this one says:
Code:
showmount -e 192.168.0.294



Pretty sure the LXC container is just fine for your setup.



Yes, it's just about getting the export and rights correct, that's literally all to it.
Showmount is showing everything as it should be: https://prnt.sc/37kedi6YmYzo
That bloody thing is so stubborn! I really don't see why I get rejected on my LXC but connect like not a single problem here: https://prnt.sc/PMG8aK1hygft

You can also check if you enabled NFS for the container:

Options -> Features -> NFS
That's a funny one. I didn't have enable it - https://prnt.sc/WpXiClYRi-qh. Now it is enabled but that very sadly didn't solve it :/ I would be so frustrated and in the same way so happy if that would've been the case :D
 
Last edited:
Yep. I feel like I am almost at the finish line. I succesffully mounter my movies NFS - https://prnt.sc/3ndV6-RrzEzy.
Now the problem is that Jellyfin does not find anything. My guess is that there should be an NFS option which let me access all subdirectory files. Something like that /volume1/MediaServer/Movies* (where the * means everything inside this folder). I will be trying to sort this out now. Let me know if you have any idea.

Thank you for your help guys. I would not be able to make it without you!
 
It is most probably a permission problem, maybe look into that.
Yep. That was it. I should've given permission the LXC user or jellyfin one to access the subdirectories. Everything works alright now.

But ofcourse the problems does not end. My TV runs one movie alright but another not. I suppose that there must be some kind of config issue or something related to the transcoding. I belive it is comming from the TV itself because my other devices (phone, pc) runs it ok.

I've opened a thread here: https://forum.jellyfin.org/t-only-on-tv-player-error-encountered

Thank you for everything!
 
Thank you once again. I think to take a break away from this project since I am loosing sleep over. Couldn't make it work. Stuck on the transcoding for more than 10 hours. Couldn't manage to solive it.
 
Last edited:

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!