Page 1 of 1

Stuck - /dev/net/tun issue

Posted: Sun Jan 12, 2025 9:49 pm
by aarwannabe

Hello,

Complete newbie to Linux, and trying to setup YAMS.

What I have done:

  1. Physically put together the setup. It is a Dell Optiplex micro with 2 external WD harddrives in a dedicated case connected by USB to the PC.
  2. Installed Debian 12. I kind of stumbled my way through the install, and later found some guides, but I don't think I messed too much up there. I found this AFTER the fact: https://www.linuxtechi.com/how-to-insta ... p-by-step/ the only differences I noticed was messing up my domain name or whatever and not selecting LVM on my harddrive.
  3. Connected my external HDDs and partitioned them as well as used mergerfs to pair them together into one location (/mnt/storage) following this guide: https://noted.lol/mergerfs-and-snapraid-setup-1/
  4. Followed the linked guide here: https://www.digitalocean.com/community/ ... in-as-root but most of it was pretty irrelevant, just made sure that my user had admin privileges (already did I think and setup the firewall.
  5. Tried to install YAMS from my user (not root)

First snag: was getting access errors for sed, which actually was solved by a restart.

New snag: I get to "Everything installed correctly! Starting YAMS services... This may take a while..."

11/12 succeed, except gluetun (I have been selecting "n" for the VPN as I plan only to use Usenet). I get an error:

Error response from daemon: error gathering device information while adding custom device "/dev/net/tun": no such file or directory
Failed to start YAMS services

And here I'm very lost. I can see that /dev/net exists, but not /tun. I can manually create a /dev/net/tun folder but then the install fails with a permissions error anyways, so I have since deleted the folder.

Any hints or ideas? I only found two resources, one on this forum (which was something to do with Proxmox) and this recent reddit thread: https://www.reddit.com/r/gluetun/commen ... g_did_you/ but I couldn't get those docker compose down and docker compose up commands to work because I don't have a config file, which I assume is due to the failed installation.


Re: Stuck - /dev/net/tun issue

Posted: Sun Jan 12, 2025 9:59 pm
by rogs

Hey @aarwannabe!

That's weird that you don't have /dev/tun enabled. Either way, yams should be working since you are not using a VPN.

Do you have the yams command available? If you do, go to /your/install/location and comment gluetun out. yams restart should work now

If you don't have the yams command available, comment out gluetun in the docker compose included in the installer and then answer no to the VPN question. Then it should work.

Cheers!

Roger.


Re: Stuck - /dev/net/tun issue

Posted: Tue Jan 14, 2025 9:17 pm
by aarwannabe

Hey @rogs thanks for the reply!

This did indeed work. However, if you have time, I am wonder what else I might be able to do to solve this. While I don't think I will be using torrents, I can't write that off as a certainty, and also just feel weird to comment out the error and be unable to use a VPN. Could you expand a bit on what /dev/net/tun is, and when it should be created? I'm wondering at what point I messed up.

Further (sorry if this should be another thread) I am struggling to get Plex to open in my browser. I changed the settings as found in the guide.

Some questions about Plex:

  1. I added the line from the guide "<Preferences allowedNetworks="<your_subnet_IP>/255.255.255.0" ..." as a NEW line in the config file, but then got errors when using the docker logs. I ended up appending it to the existing line as "allowedNetworks="<your_subnet_IP>/255.255.255.0" />" and didn't get the error.
    1.a. What exactly do the three dots do? I see you said that it says "leave the rest of the file as is" but I don't really understand what that means. I edited it with nano because I couldn't figure out how to use vim.
  2. Using the modified line (again, please correct me if I messed that up) I couldn't access Plex via my browser. The other components worked fine. All were at 192.168.30.3:port and so I added my subnet IP as 192.168.30.0 and the page just doesn't load. My building has one main internet connection going to what I assume is a router and switch, with my own router plugged into that. Is this a network issue, or something with YAMS that I messed up. If it's the former, I probably need to get my own connection...

Re: Stuck - /dev/net/tun issue

Posted: Tue Jan 14, 2025 9:32 pm
by rogs

This is the first time I don't see /dev/tun available in Debian, so I think you might have borked the install more than we think. If I where you, I would install the OS again just to be sure.

/dev/tun represents a TUN (network TUNnel) device. A TUN device is a virtual network device used to simulate a network layer (IP) device. It is commonly used in VPN (Virtual Private Network) software to create encrypted tunnels for secure communication over the internet.

Regarding Plex:

  • You can use nano, that's fine. The ... means “leave the rest of the file as is”. You only need to add the allowedNetworks bit. Basically, don't change anything after the allowedNetworks="<your_subnet_IP>/255.255.255.0" part.
  • You might not be using another kind of subnet. You might need to figure that out in your router settings. Your building internet/router/switch shouldn't matter in this case, since your devices are connected to your router.

Re: Stuck - /dev/net/tun issue

Posted: Tue Jan 14, 2025 10:00 pm
by aarwannabe

Oh man, I feel dumb. I just realized now that you were indicating the line goes BEHIND the already existing "<Preferences " and then the ... makes tons of sense. My first attempt I added it on a new line :lol:

Okay.

So I will definitely try a new install of Debian and come back to you if I can't get the /tun part to work since it should be standard with Debian. I'll double check my settings with a fresh install and a more thorough guide.

Re: Plex

I see that my server address is 192.168.3.30 (excuses, I mixed it up before). In my router settings (setup by someone else, with actual network knowledge to connect to the shared router/switch) I see eth0 [interface ethernet] (Internet) at 192.168.1.3/24 and switch 0 [interface switch] at 192.168.3.1/24. DHCP is 192.168.3.0/24

I have tried both 192.168.3.0 and 192.168.1.0 in the Preferences.xml. In both cases the "docker logs plex" pops up what looks like 2 similar logs starting with giant LSIO letters.

In both logs, for both IP settings, it says "Connection to localhost (::1) 32400 port [tcp/*] succeeded!

In the first half it always says "Critical: libusb_init failed" but that section is missing on the second log. I'm not sure if there are any insights to be gained there for you other than "it's something with your network". Sorry I can't copy and paste the actual stuff, I don't have a GUI on the server, so I'm on a different computer, and my attempts to SSH in appeared to get me on someone elses' server in the building since my password wasn't working...

Edit: Just found the | Less command. I lied, it's a ton of stacked logs, and now I see the "you can ignore the libusb_init error" written.


Re: Stuck - /dev/net/tun issue

Posted: Wed Jan 15, 2025 11:11 am
by rogs

Sorry, but I don't know how to help you with your network issues since they where configured by someone else :|

Maybe you can ask that person for help?