[Tutorial] How to install UMS in Docker

For help and support with Universal Media Server
Forum rules
Please make sure you follow the Problem Reporting Guidelines before posting if you want a reply
User avatar
mik_s
Moderator
Posts: 1766
Joined: Wed Aug 23, 2017 11:03 pm
Location: UK

Re: [Tutorial] How to install UMS in Docker

Post by mik_s »

Are you sure they are on the same subnet. This means the computer and your devices have an IP starting 192.168.1.x for example with only the x being different.

I don't know how Docker handles networking so I am assuming it translates (bridges?) the computer's IP into an IP inside that container.
For example if the IP of the computer is 192.168.1.20 this can be translated to 172.16.1.20 inside the container.
As long as UMS is using that 172 IP then it should see the network on the outside and any device on 192.168.1 subnet, but this all depends on how the container is setup from what I understand.

Looking over the instructions in the previous posts it does not mention bridging so the default settings might be correct when it comes to this and not something you need to set up. If you have then try going back to default.
Logs are important for us to help, Please follow This Link before asking for support. Just a forum cleaner, Will help if I can but no expert.
freemansteve
Posts: 34
Joined: Tue Apr 19, 2022 10:12 pm

Re: [Tutorial] How to install UMS in Docker

Post by freemansteve »

I largely get IP comms, subnets, bridging (no IP involved) and routing (IP only, no MAC frames), but:

- All my kit is on a single subnet of 192.168.0.0, and the NAS is at 192.168.0.150
- On setting up the container for UMS, the setup requires a new subnet for it to 'live in', e.g. 172.17.0.0, and then the UMS instance appears to be at address 172.17.0.2
- The container manager maps ports so that for example 192.168.0.150:32770 will route to 172.17.0.2:5000 (or similar - I forget the exact mappings, but there are several) and indeed, I can reach the UMS instance that is running in order to set it up via browser from my PC- this must be because of NAT or similar (like a broadband router does), but I would not call this "bridging".
- The basic problem seems to come down to the UMS instance on the NAS not being able to communicate with renderers on my LAN, which at a guess is set up using UPnP, and the messages are not passing between the NAS UMS instance and my LAN.
- N.B. I have several renderers which run fine when UMS is running just on PC - a Cambridge Audio network player, and Foobar2000 (with UPnP component) and VLC (the latter two can run on any PC on my LAN), and several smart TVs. All these devices work fine with the Synology built-in Media server too - point being that the only non-working server is UMS when in a container.
- I also note that each time I restart the UMS instance, the port mappings change - they increment! This is surely a bug?

Luckily I can live with Synology's built-in server until UMS-for-docker or Docker Container can be made to work properly! And when my NAS is turned off, UMS on my PC (with local media) runs very nicely!

Thanks for reading.
User avatar
mik_s
Moderator
Posts: 1766
Joined: Wed Aug 23, 2017 11:03 pm
Location: UK

Re: [Tutorial] How to install UMS in Docker

Post by mik_s »

The main ports UMS uses is 5001 (main), 9001 (web interface), and 9002 (web player) with the default settings.
There might be some system level ports to do with UPnP but I don't remember what they are.

If your container is changing its mappings it is probably with its settings as these should stay the same.
UMS won't be changing its ports, if it cannot bind to what it needs it will just give an error in the logs not find another port.
I only know the basics of setting up a network, basically set everything on auto and everything needing to be on the same subnet, so I can't say exactly what you need to get it working. Try and match the port mappings so keep it 5001<->5001 etc.

There was changes made to the docker installation in 15.4.0 that was just released for patreons. Maybe you could try that once it is publicly released.
Logs are important for us to help, Please follow This Link before asking for support. Just a forum cleaner, Will help if I can but no expert.
freemansteve
Posts: 34
Joined: Tue Apr 19, 2022 10:12 pm

Re: [Tutorial] How to install UMS in Docker

Post by freemansteve »

"The main ports UMS uses is 5001 (main), 9001 (web interface), and 9002 (web player) with the default settings.
There might be some system level ports to do with UPnP but I don't remember what they are."

Thanks for the input. The 5001, 9001 etc ports remain constant for the UMS image, but that seems to be in its own subnet of 172.17...., and as far as I can tell, in order to access these interfaces in UMS from my 192.168.0.0 LAN (which I can) I use the port mappings that get set up for me, so I use 192.168.0.150:32770 (or similar). I assume this is done using NAT in the container. If UMS is restarted, these ports no longer work, and if I delve deeper, I can see that somehow the port numbers 32xxx have all incremented for reasons I don't understand. I can't believe that is not a bug in something.It is probably a separate issue from the lack of UPnP communication. I don't really know how UPnP works for streaming, but I assume either the server or the renderer must use some kind of broadcast to discover each other (I'm too lazy to wireshark this using UMS on my PC (on the same LAN as my renderers!) and I'm sure there is something missing in the config that sorts this out. I'm wondering if there is a missing port mapping or two.

I'll revisit this when the next UMS docker image is available, or if someone with a Synology running DSM 7.3.x has successfully used an existing UMS docker image on that NAS and has some detailed tips - someone surely has done this; I can't believe I'm the only person attempting this setup.
Post Reply