Jitsi Docker - ICE discovery fails

Hi All,
Please help me discover what I’m doing wrong.

In my new setup, I’m using Jitsi in docker. The server is a VPS with fixed IP on the internet. The docker environment starts as expected, with two unexpected behavior:

  1. ICE seems to fail
    DOCKER_HOST_ADDRESS is set to my external public internet IP

I’ve also checked that when I’m starting with docker-compose, the generated config files seems ok.

more ~/.jitsi-meet-cfg/jvb/sip-communicator.properties

org.ice4j.ice.harvest.NAT_HARVESTER_LOCAL_ADDRESS=172.18.0.5
org.ice4j.ice.harvest.NAT_HARVESTER_PUBLIC_ADDRESS=79.xxx.xxx.xxx

but when the third participant joins, connection breaks. In the logs I only see local IP addresses. There are even IP addresses I don’t recognize, for example 172.19.0.1

jvb_1 | INFO: new Pair added: 172.18.0.5:10000/udp/host → 172.21.0.1:52888/udp/host (stream-3d5420ec.RTP).
jvb_1 | May 02, 2021 4:13:30 PM org.jitsi.utils.logging2.LoggerImpl log
jvb_1 | INFO: new Pair added: 172.18.0.5:10000/udp/host → 172.18.0.1:36317/udp/host (stream-3d5420ec.RTP).
jvb_1 | May 02, 2021 4:13:30 PM org.jitsi.utils.logging2.LoggerImpl log
jvb_1 | INFO: new Pair added: 172.18.0.5:10000/udp/host → 172.20.0.1:46255/udp/host (stream-3d5420ec.RTP).
jvb_1 | May 02, 2021 4:13:30 PM org.jitsi.utils.logging2.LoggerImpl log
jvb_1 | INFO: new Pair added: 172.18.0.5:10000/udp/host → 172.19.0.1:46640/udp/host (stream-3d5420ec.RTP).
jvb_1 | May 02, 2021 4:13:30 PM org.jitsi.utils.logging2.LoggerImpl log
jvb_1 | INFO: new Pair added: 172.18.0.5:10000/udp/host → 172.17.0.1:57429/udp/host (stream-3d5420ec.RTP).
jvb_1 | May 02, 2021 4:13:30 PM org.jitsi.utils.logging2.LoggerImpl log
jvb_1 | INFO: new Pair added: 172.18.0.5:10000/udp/host → 192.168.0.144:34749/udp/host (stream-3d5420ec.RTP).
jvb_1 | May 02, 2021 4:13:30 PM org.jitsi.utils.logging2.LoggerImpl log
jvb_1 | INFO: new Pair added: 172.18.0.5:4443/tcp/host → 172.21.0.1:9/tcp/host (stream-3d5420ec.RTP).
jvb_1 | May 02, 2021 4:13:30 PM org.jitsi.utils.logging2.LoggerImpl log
jvb_1 | INFO: new Pair added: 172.18.0.5:4443/tcp/host → 172.18.0.1:9/tcp/host (stream-3d5420ec.RTP).
jvb_1 | May 02, 2021 4:13:30 PM org.jitsi.utils.logging2.LoggerImpl log
jvb_1 | INFO: new Pair added: 172.18.0.5:4443/tcp/host → 172.20.0.1:9/tcp/host (stream-3d5420ec.RTP).
jvb_1 | May 02, 2021 4:13:30 PM org.jitsi.utils.logging2.LoggerImpl log
jvb_1 | INFO: new Pair added: 172.18.0.5:4443/tcp/host → 172.19.0.1:9/tcp/host (stream-3d5420ec.RTP).
jvb_1 | May 02, 2021 4:13:30 PM org.jitsi.utils.logging2.LoggerImpl log
jvb_1 | INFO: new Pair added: 172.18.0.5:4443/tcp/host → 172.17.0.1:9/tcp/host (stream-3d5420ec.RTP).
jvb_1 | May 02, 2021 4:13:30 PM org.jitsi.utils.logging2.LoggerImpl log
jvb_1 | INFO: new Pair added: 172.18.0.5:4443/tcp/host → 192.168.0.144:9/tcp/host (stream-3d5420ec.RTP).
jvb_1 | May 02, 2021 4:13:30 PM org.jitsi.utils.logging2.LoggerImpl log
jvb_1 | SEVERE: Health check failed in PT0S:
jvb_1 | java.lang.Exception: Address discovery through STUN failed
jvb_1 | at org.jitsi.videobridge.health.JvbHealthChecker.check(JvbHealthChecker.kt:40)
jvb_1 | at org.jitsi.videobridge.health.JvbHealthChecker.access$check(JvbHealthChecker.kt:25)
jvb_1 | at org.jitsi.videobridge.health.JvbHealthChecker$healthChecker$1.invoke(JvbHealthChecker.kt:32)
jvb_1 | at org.jitsi.videobridge.health.JvbHealthChecker$healthChecker$1.invoke(JvbHealthChecker.kt:25)
jvb_1 | at org.jitsi.health.HealthChecker.run(HealthChecker.kt:145)
jvb_1 | at org.jitsi.utils.concurrent.RecurringRunnableExecutor.run(RecurringRunnableExecutor.java:216)
jvb_1 | at org.jitsi.utils.concurrent.RecurringRunnableExecutor.runInThread(RecurringRunnableExecutor.java:292)
jvb_1 | at org.jitsi.utils.concurrent.RecurringRunnableExecutor.access$000(RecurringRunnableExecutor.java:36)
jvb_1 | at org.jitsi.utils.concurrent.RecurringRunnableExecutor$1.run(RecurringRunnableExecutor.java:328)
jvb_1 |
jvb_1 | May 02, 2021 4:13:30 PM org.jitsi.utils.logging2.LoggerImpl log
jvb_1 | INFO: Pair failed: 172.18.0.5:10000/udp/host → 172.21.0.1:52888/udp/host (stream-3d5420ec.RTP)
jvb_1 | May 02, 2021 4:13:30 PM org.jitsi.utils.logging2.LoggerImpl log
jvb_1 | INFO: Pair failed: 172.18.0.5:10000/udp/host → 172.18.0.1:36317/udp/host (stream-3d5420ec.RTP)
jvb_1 | May 02, 2021 4:13:30 PM org.jitsi.utils.logging2.LoggerImpl log
jvb_1 | INFO: Pair failed: 172.18.0.5:10000/udp/host → 172.20.0.1:46255/udp/host (stream-3d5420ec.RTP)
jvb_1 | May 02, 2021 4:13:30 PM org.jitsi.utils.logging2.LoggerImpl log
jvb_1 | INFO: Pair failed: 172.18.0.5:10000/udp/host → 172.19.0.1:46640/udp/host (stream-3d5420ec.RTP)
jvb_1 | May 02, 2021 4:13:30 PM org.jitsi.utils.logging2.LoggerImpl log
jvb_1 | INFO: Pair failed: 172.18.0.5:10000/udp/host → 172.17.0.1:57429/udp/host (stream-3d5420ec.RTP)
jvb_1 | May 02, 2021 4:13:30 PM org.jitsi.utils.logging2.LoggerImpl log
jvb_1 | INFO: Pair failed: 172.18.0.5:10000/udp/host → 192.168.0.144:34749/udp/host (stream-3d5420ec.RTP)
jvb_1 | May 02, 2021 4:13:30 PM org.jitsi.utils.logging2.LoggerImpl log
jvb_1 | INFO: Pair failed: 172.18.0.5:4443/tcp/host → 172.21.0.1:9/tcp/host (stream-3d5420ec.RTP)
jvb_1 | May 02, 2021 4:13:30 PM org.jitsi.utils.logging2.LoggerImpl log
jvb_1 | INFO: Pair failed: 172.18.0.5:4443/tcp/host → 172.18.0.1:9/tcp/host (stream-3d5420ec.RTP)
jvb_1 | May 02, 2021 4:13:30 PM org.jitsi.utils.logging2.LoggerImpl log
jvb_1 | INFO: Pair failed: 172.18.0.5:4443/tcp/host → 172.20.0.1:9/tcp/host (stream-3d5420ec.RTP)
jvb_1 | May 02, 2021 4:13:30 PM org.jitsi.utils.logging2.LoggerImpl log
jvb_1 | INFO: Pair failed: 172.18.0.5:4443/tcp/host → 172.19.0.1:9/tcp/host (stream-3d5420ec.RTP)
jvb_1 | May 02, 2021 4:13:30 PM org.jitsi.utils.logging2.LoggerImpl log
jvb_1 | INFO: Pair failed: 172.18.0.5:4443/tcp/host → 172.17.0.1:9/tcp/host (stream-3d5420ec.RTP)
jvb_1 | May 02, 2021 4:13:30 PM org.jitsi.utils.logging2.LoggerImpl log
jvb_1 | INFO: Pair failed: 172.18.0.5:4443/tcp/host → 192.168.0.144:9/tcp/host (stream-3d5420ec.RTP)

  1. The stun discovery does not work. In the log files in the beginning there is one message:

jicofo_1 | INFO: Scheduled health-check task for: jvbbrewery@internal-muc.meet.jitsi/7374a0d747aa
jvb_1 | May 02, 2021 4:29:09 PM org.jitsi.utils.logging2.LoggerImpl log
jvb_1 | INFO: Performed a successful health check in PT0.002S. Sticky failure: false
jvb_1 | May 02, 2021 4:29:19 PM org.ice4j.ice.harvest.StunMappingCandidateHarvester discover
jvb_1 | INFO: We failed to obtain addresses for the following reason:
jvb_1 | java.lang.IllegalArgumentException: unresolved address
jvb_1 | at java.net.DatagramPacket.setSocketAddress(DatagramPacket.java:316)
jvb_1 | at java.net.DatagramPacket.(DatagramPacket.java:144)
jvb_1 | at org.ice4j.stack.Connector.sendMessage(Connector.java:325)
jvb_1 | at org.ice4j.stack.NetAccessManager.sendMessage(NetAccessManager.java:654)
jvb_1 | at org.ice4j.stack.NetAccessManager.sendMessage(NetAccessManager.java:600)
jvb_1 | at org.ice4j.stack.StunClientTransaction.sendRequest0(StunClientTransaction.java:267)
jvb_1 | at org.ice4j.stack.StunClientTransaction.sendRequest(StunClientTransaction.java:245)
jvb_1 | at org.ice4j.stack.StunStack.sendRequest(StunStack.java:680)
jvb_1 | at org.ice4j.stack.StunStack.sendRequest(StunStack.java:618)

An after there is this repeating log message:

java.lang.Exception: Address discovery through STUN failed
jvb_1 | at org.jitsi.videobridge.health.JvbHealthChecker.check(JvbHealthChecker.kt:40)

I’ve tried this with meet-jit-si-turnrelay.jitsi.net:443 and also with google stun servers, none of the are working.
Commenting out the JVB_STUN_SERVERS setting removes the error message. Since I have fixed ip on the internet, I don’t really need stun discovery.

Any help is appreciated.