Y’all are trans, and I know how much you trans Zoomers code (no idea if that’s a Linux thing or not tho), so I thought I might try Hexbear for some tech help. I’m fried, I’ve watched so damn many tutorials and read so many threads on this but I can’t seem to work it out. I barely know a few basic commands in the console, and the alphabet soup of different directories, programs, and the very language that’s used to discuss Linux is too much for me to process. I’ve learned a lot, but I need some help.

I’ve built a pretty nice server that’s not doing much right now besides NAS storage. I’m running a TrueNAS scale VM on Proxmox, I’m filling it up with all my pirate booty, and I want to watch it through Jellyfin, which I have installed to an LXC container (unprivileged for security, tried it both ways and I can’t get it). The problem is, how do I get jelly to see the NAS drive? I don’t know how to map it one way or another. I’m running the storage through an HBA in ZFS mirror with an SMB data set that I can see just fine and access in Windows, but jelly seems to just be stuck in it’s own little world.

I’ve seen things about creating users within jelly, which I tried, and it just tells me that the user I supposedly created with SMB credentials doesn’t exist. Tried using the GUI to find the NAS via IP, no dice. I’m fucking tired, I’ve been at it for a week or so now, I just want to watch a movie this weekend.

  • Okay, so it’s giving me an error:

    root@pve:~# mount /mnt/lxc_shares/nas_rwx mount: /etc/fstab: parse error at line 3 – ignored mount: /mnt/lxc_shares/nas_rwx: can’t find in /etc/fstab. mount: (hint) your fstab has been modified, but systemd still uses the old version; use ‘systemctl daemon-reload’ to reload.

    I edited the /fstab file like you said and this is the printout:

    proc /proc proc defaults 0 0 //192.168.X.XXX/mnt/XXXX/XXXX /mnt/lxc_shares/nas_rwx cifs _netdev,x-systemd.automount,noatime,uid=100000,gid=110000,dir_mode=0770,file_mode=0770,user=XXXX,pass=XXXX 0 0

    If I then enter the echo command, this is what I get:

    root@pve:~# echo ‘mp0: /mnt/lxc_shares/nas_rwx/,mp=/mnt/nas’ | tee -a /etc/pve/lxc/100.conf mp0: /mnt/lxc_shares/nas_rwx/,mp=/mnt/nas

    Looks okay?

    I was able to then go on to jelly and the only directory option it gives me to map is “/mnt/nas” and that’s not working.

    What do?

    • YearOfTheCommieDesktop [they/them]@hexbear.net
      link
      fedilink
      English
      arrow-up
      1
      ·
      edit-2
      2 years ago

      hmm okay…

      the parse error is a bit odd. do any of the values substituted for XXXX contain spaces by any chance. /etc/fstab uses spaces to separate the 6 different config parameters, so if any of them contain a space (including the folder names) it messes things up.

      If that’s the issue, try substituting the space with \040 i.e. //192.168.1.1/My\040Folder/otherfolder /mnt/lxc_shares/nas_rwx cifs _netdev,x-systemd.automount,noatime,uid=100000,gid=110000,dir_mode=0770,file_mode=0770,user=XXXX,pass=XXXX 0 0

      you might also need to run systemctl daemon-reload and try the mount again like the message suggests, honestly don’t recall how that interaction works…

      • Okay, so I did that. My directory is [IP]/mnt/M14 - Media/Media, so I changed it to /mnt/M14\040-\040Media/Media. Is that correct? it hasn’t worked yet, getting this error:

        mount /mnt/lxc_shares/nas_rwx mount error(2): No such file or directory Refer to the mount.cifs(8) manual page (e.g. man mount.cifs) and kernel log messages (dmesg) mount: (hint) your fstab has been modified, but systemd still uses the old version; use ‘systemctl daemon-reload’ to reload.

        • YearOfTheCommieDesktop [they/them]@hexbear.net
          link
          fedilink
          English
          arrow-up
          2
          ·
          2 years ago

          okay that took care of the space issue at least judging by the different error!

          https://unix.stackexchange.com/a/154465/162315 this seems to indicate that for CIFS No such file or directory errors could be caused by a variety of non-obvious issues. if you ran the mkdir command the mount point /mnt/lxc_shares/nas_rwx should exist so I’m going to leave that aside.

          This post seems like a more plausible issue. Is the name of your smb share really “mnt”, or is that just the start of the path to the dir you’ve shared?

          If that is the actual SMB share name, then maybe it is an issue with subdirectories… In that case I would try mounting the base level share directly, and if that works, then you can change the /etc/pve/lxc/ configuration to only bind mount the subdirectory you want into the jellyfin container.

          • Okay, so under the SMB tab on TrueNAS the “path” is /mnt/M14 - Media/Media. The name of the ZFS pool is just M14 - Media though. So I’m not at all sure what the answer is there. And as far as your solution… I have know idea what the heck that means lol! I read the thread and I still don’t know what to do.

            • YearOfTheCommieDesktop [they/them]@hexbear.net
              link
              fedilink
              English
              arrow-up
              2
              ·
              edit-2
              2 years ago

              so, looking at some tutorials, as I haven’t used truenas before, when you look at this bit there should be both a Path (the local-to-truenas path to the directory being shared) and a Name (the name of the share). You want the Name field.

              I believe it should be //192.168.x.xxx/name_here rather than giving the full path. So hopefully truenas can tell you the name of the smb share.

              Buuuut, according to that truenas page, the default name if none is set is the last folder in the path. So if you can’t find any indication of a name for the SMB share that you set, try //192.168.x.xxx/Media since that is (correct me if I’m wrong) the last folder name in the path.

              the subdirectory thing I can elaborate on if that turns out to be the issue still somehow, but I’m kinda doubting it at this point.

              SMB is a windows thing so the concepts aren’t usual linux concepts exactly, especially having a named share rather than just mounting based on the file/dir path is… a bit weird