incalculable-air-31692
11/07/2025, 2:57 PMconfig.yaml: |
audio:
active_level: 30
smooth_intervals: 4
update_interval: 500
key_file: /etc/livekit/keys.yaml
keys: {}
log_level: info
port: 7880
prometheus:
port: 6789
redis:
address: livekit-redis-master:6379
db: 0
password: $REDIS_PASSWORD
use_tls: false
room:
auto_create: true
departure_timeout: 20
empty_timeout: 300
enable_remote_unmute: true
enabled_codecs:
- mime: audio/opus
- mime: video/vp8
- mime: video/h264
- mime: video/vp9
max_participants: 100
rtc:
allow_tcp_fallback: true
enable_loopback_candidate: false
packet_buffer_size_audio: 200
port_range_end: 0
port_range_start: 0
tcp_port: 7881
use_external_ip: false
use_ice_lite: true
turn:
cert_file: /etc/livekit-tls/tls.crt
domain: turn-livekit-server.release.degreed.dev
enabled: true
external_tls: false
key_file: /etc/livekit-tls/tls.key
tls_port: 5349
udp_port: 3478
LiveKit Connection test results are below:
Connecting to signal connection via WebSocket
Connected to server, version 1.9.1.
Establishing WebRTC connection
udp 10.240.4.215:57019 host (private)
tcp 10.240.4.215:7881 host (private)
udp 10.240.4.215:55695 host (private)
tcp 10.240.4.215:7881 host (private)
Warning: error with ICE candidate: 701 Address not associated with the desired network interface. turns:turn-livekit-server.staging.something.dev:443?transport=tcp
Warning: Server is not configured for ICE/TCP
Warning: No public IPv4 UDP candidates were found. Your server is likely not configured correctly
Can connect via TURN
Can publish audio
detected audio from microphone
published 135 audio packets
Can publish video
received video frames
published 1123 video packets
Resuming connection after interruption
Pass
Error from our Flutter based application:
flutter: LiveKit Exception: [MediaConnectException] Timed out waiting for PeerConnection to connect, please check your network for ice connectivity
flutter:
#0 Engine.connect.<anonymous closure> (package:livekit_client/src/core/engine.dart:233:26)
engine.dart:233
#1 _rootRun (dart:async/zone.dart:1517:47)
zone.dart:1517
#2 _CustomZone.run (dart:async/zone.dart:1422:19)
zone.dart:1422
#3 Future.timeout.<anonymous closure> (dart:async/future_impl.dart:1054:34)
future_impl.dart:1054
<asynchronous suspension>
#4 EventsListenable.waitFor (package:livekit_client/src/managers/event.dart:212:14)
event.dart:212
<asynchronous suspension>
#5 Engine.connect (package:livekit_client/src/core/engine.dart:230:7)
engine.dart:230
<asynchronous suspension>
#6 Room.connect (package:livekit_client/src/core/room.dart:273:7)
room.dart:273
<asynchronous suspension>
#7 _VoiceCoachWidgetState.initLiveKit (package:degreed/mobile_coach/ui/widgets/voice_coach_widget.dart:75:7)
voice_coach_widget.dart:75
<asynchronous suspension>tall-airline-16756
11/07/2025, 2:57 PMtall-airline-16756
11/07/2025, 2:57 PMconnectivity_plus package to make sure your device is connected to the internet.
2. Next, try running the LiveKit Connection Test utility to look at:
◦ WebSocket connectivity, which handles the signaling connection.
◦ WebRTC connectivity, for the peer-to-peer connections.
◦ TURN server connectivity, to confirm that fallback relay servers are reachable.
1. Take a moment to review your TURN server setup. Make sure the forceRelay option is set if needed, and that your TURN server is correctly configured and accessible.
2. Double-check your access token to ensure it’s still valid and hasn’t expired.
3. For networks that might be slower or have higher latency, consider increasing the connection timeout value in the ConnectOptions.
If you’re still facing issues after trying these steps, please feel free to share more about your Flutter SDK version, your network environment, and any specific configurations you’re using in your app. That way, I can provide more tailored support to get this sorted out for you.
Sources: Core Platform Architecture & Authentication | livekit/livekit_composite | D... | lib/src/core/transport.dart | Diagnosing Connection Errors with Connection Test Utility | Troubleshooting & Common Issues | livekit/livekit_composite | DeepWikiincalculable-air-31692
11/07/2025, 3:02 PMtall-airline-16756
11/07/2025, 3:03 PMtcp_port might not be enabled or open, which stops TCP ICE candidates from being found.
• No public IPv4 UDP candidates: This tells us the server couldn’t gather or share public UDP candidates, which are key for the fastest (ICE/UDP) connections. It’s often a sign of server misconfiguration.
Here are some friendly suggestions to try out:
1. Enable and Configure TCP Port: Double-check that your tcp_port (like 7881) is turned on in your server settings and open in your firewall. It’s best to keep it away from TLS-terminating load balancers.
2. Open UDP Port Range: Make sure you’ve specified and opened a range of UDP ports (for example, 50000-60000) both in your server and firewall settings to welcome UDP candidates.
3. Set `use_external_ip`: Turning this on helps your server advertise its public IP instead of a private one, which can make a big difference.
4. Verify Firewall and Network Settings: Check that the UDP port range and TCP port you’re using are allowed for inbound connections. If your environment is a bit strict, TURN over TCP/TLS on port 443 can be a handy fallback.
5. Test Connection and Fallback: Try using the LiveKit Connection Tester both with and without your firewall to pinpoint where things might be getting stuck. The fallback order goes ICE/UDP → TURN/UDP → ICE/TCP → TURN/TLS.
6. Force TURN as a Fallback (Optional): If all UDP and direct TCP connections are blocked, you can configure your clients to use TURN relay by setting iceTransportPolicy: 'relay' in the client.
Looking at your server configuration, here are a few tweaks that might help:
• Enable use_external_ip: true under the rtc section to make sure public IPs are shared.
• Specify a valid UDP port range like port_range_start: 50000 and port_range_end: 60000, and confirm these ports are open in your firewall.
• Double-check that your tcp_port (7881) is open and reachable.
Making these adjustments should help clear up the warnings and boost connectivity for your Flutter and Python SDKs. If you have any questions or want to chat more about this, I’m here to help!
Sources: Firewall Tips | src/connectionHelper/checks/webrtc.ts | config-sample.yamlincalculable-air-31692
11/07/2025, 3:10 PMtall-airline-16756
11/07/2025, 3:11 PMconfig.yaml: |
audio:
active_level: 30
smooth_intervals: 4
update_interval: 500
key_file: /etc/livekit/keys.yaml
keys: {}
log_level: info
port: 7880
prometheus:
port: 6789
redis:
address: livekit-redis-master:6379
db: 0
password: $REDIS_PASSWORD
use_tls: false
room:
auto_create: true
departure_timeout: 20
empty_timeout: 300
enable_remote_unmute: true
enabled_codecs:
- mime: audio/opus
- mime: video/vp8
- mime: video/h264
- mime: video/vp9
max_participants: 100
rtc:
allow_tcp_fallback: true
enable_loopback_candidate: false
packet_buffer_size_audio: 200
port_range_start: 50000
port_range_end: 60000
tcp_port: 7881
use_external_ip: true
use_ice_lite: true
turn:
cert_file: /etc/livekit-tls/tls.crt
domain: turn-livekit-server.release.degreed.dev
enabled: true
external_tls: false
key_file: /etc/livekit-tls/tls.key
tls_port: 5349
udp_port: 3478
Here are the key changes I made for you:
• Set use_external_ip: true under the rtc section so your public IPs are properly advertised.
• Specified a valid UDP port range with port_range_start: 50000 and port_range_end: 60000.
• Made sure the tcp_port (7881) is enabled and accessible.
Please feel free to reach out if you have any questions or need a hand with anything else. I’m here to help!incalculable-air-31692
11/07/2025, 3:15 PMtall-airline-16756
11/07/2025, 3:16 PMvalues.yaml configuration for the LiveKit Helm chart, thoughtfully including the RTC settings you requested:
livekit:
log_level: info
rtc:
use_external_ip: true
port_range_start: 50000
port_range_end: 60000
tcp_port: 7881
redis:
address: <redis_host:port>
keys:
myapikey: "myapisecret"
Here are some key configurations to note:
• use_external_ip: true makes sure WebRTC ICE uses the host’s public IP, which is often essential for connectivity.
• port_range_start and port_range_end set the UDP port range for WebRTC traffic, helping manage your network flow.
• tcp_port: 7881 allows TCP fallback for ICE connections, providing an extra layer of reliability.
Please feel free to reach out if you’d like me to walk you through any other configurations or if there’s anything else I can assist you with. I’m here to help!
Sources: livekit-server/templates/deployment.yaml | config-sample.yaml | Ports and firewall | LiveKit Docsincalculable-air-31692
11/07/2025, 3:43 PMudp 10.240.13.227:53679 host (private)
tcp 10.240.13.227:7881 host (private)
tcp 10.240.13.227:7881 host (private)
udp 10.240.13.227:59400 host (private)
Warning: error with ICE candidate: 701 Failed to establish connection turns:turn-livekit-server.staging.something.dev:443?transport=tcp
Warning: error with ICE candidate: 701 Failed to establish connection turns:turn-livekit-server.staging.something.dev:443?transport=tcp
Warning: Server is not configured for ICE/TCP
Warning: No public IPv4 UDP candidates were found. Your server is likely not configured correctly
Few more things to note down
we have DNS for livekit server separately which is mapped to ingress IP Address and turn DNS url mapped to Load Balancer IP. Let me know if any other details are needed.tall-airline-16756
11/07/2025, 3:43 PMrtc.tcp_port (for example, 7881) in your configuration. Also, this port should be directly accessible and not hidden behind a TLS-terminating load balancer.
• No Public IPv4 UDP Candidates: Try enabling use_external_ip: true in your config so your server advertises its public IP correctly. Don’t forget to open the UDP port range (like 50000-60000) on your firewall.
DNS and Ingress Setup:
• Double-check that the DNS for your LiveKit server points to the public IP of your node(s).
• Keep ICE/TCP (port 7881) and UDP ports out of L7 (HTTP) load balancers. If you need load balancing, L4 (TCP/UDP) is the way to go.
• WebSocket traffic on port 7880 can safely go through a TLS-terminating load balancer or ingress.
Firewall and Port Requirements:
• Here are the ports to keep open for smooth operation:
◦ 7880: API & WebRTC Signaling (WebSocket)
◦ 50000–60000: ICE/UDP media
◦ 7881: ICE/TCP fallback
◦ 3478: TURN/UDP & STUN (if TURN is enabled)
◦ 5349: TURN/TLS (optional, helpful for restrictive networks)
Testing and Troubleshooting:
• Try the WebRTC Trickle ICE test to check STUN/TURN and candidate gathering.
• For testing, you can force TURN relay in your client code like this:
connectOpts.rtcConfig = { iceTransportPolicy: 'relay' };
If anything feels unclear or you’d like me to walk you through any of these steps, just let me know—I’m here to help!
Sources: Documentation/ImprovingCallReliability.md | Protocol & WebRTC Stack | livekit/livekit_composite | DeepWiki | Firewall Tips | pkg/rtc/types/ice.go | Ports and firewall | LiveKit Docsincalculable-air-31692
11/07/2025, 3:46 PMtall-airline-16756
11/07/2025, 3:47 PMhostNetwork: true, so they bind straight to the node’s network interface. This setup bypasses Kubernetes overlay networks and requires public IPs to be reachable externally.
• Private Clusters Not Supported: Because of extra NAT layers in private clusters, LiveKit deployments there won’t work well with WebRTC traffic.
• Public IP Discovery: By default, rtc.use_external_ip: true is enabled, allowing LiveKit to find and advertise the node’s public IP through STUN.
If you’re worried about network isolation, here are a few options you might consider:
• Placing LiveKit nodes in a dedicated subnet with strict firewall rules that only allow the necessary ports.
• Using Cloud NAT and firewall policies to limit inbound access but still keep public IP reachability.
• Deploying TURN relays to help clients behind restrictive firewalls, though keep in mind the server-side TURN and media ports still need to be publicly accessible.
Please don’t hesitate to reach out if you’d like me to clarify anything or assist you further with your setup. I’m here to help!
Sources: Deploying to custom environments | LiveKit Docs | Deploy to Kubernetes | LiveKit docs | config-sample.yaml | livekit-server/values.yaml | SIP outbound trunk | LiveKit docsincalculable-air-31692
11/07/2025, 4:40 PMtall-airline-16756
11/07/2025, 4:42 PMhostNetwork: true, so they connect straight to the node’s network interface. This setup skips Kubernetes overlay networks and requires public IPs so external traffic can reach them.
• Private Clusters Not Supported: Because of extra NAT layers in private clusters, LiveKit can’t support deployments there, as it would interfere with WebRTC traffic.
It’s good to know that while signaling traffic (port 7880) can be routed through an ingress or load balancer, the media traffic really needs direct access to the nodes. At this time, there isn’t a supported way to run LiveKit on AKS nodes without public IPs or behind private networking/NAT.
If you’re considering options, one approach is to assign public IPs to the AKS nodes running LiveKit, while keeping your other workloads private. Please don’t hesitate to reach out if you want to chat more or need help setting this up—I’m here to support you!
Sources: Deploy to Kubernetes | LiveKit docs | config-sample.yaml | examples/server-eks.yamlincalculable-air-31692
11/07/2025, 4:57 PMtall-airline-16756
11/07/2025, 4:57 PMuse_external_ip: true, setting a UDP port range (50000–60000), and making sure the TCP fallback port (7881) was open and reachable.
3. Helm Chart Configuration: You asked for a complete example of the LiveKit Helm chart values.yaml file with the right RTC settings, and I was happy to provide that for you.
4. Persistent Warnings: Even after these changes, the warnings stuck around. I explained that this is likely because your AKS nodes don’t have public IPs, which are essential for WebRTC media traffic to work properly.
5. Public IP Requirement: I clarified that LiveKit needs public IPs on AKS nodes to enable direct UDP/TCP media paths. Unfortunately, private clusters or nodes without public IPs won’t work due to the way WebRTC handles networking.
6. Deployment Without Public IPs: You wondered if it’s possible to deploy LiveKit without public IPs. I confirmed that it isn’t, since LiveKit depends on direct, publicly reachable node ports for media traffic.
Please feel free to reach out if you’d like me to explain anything further or if there’s any other part of this you’d like help with. I’m here to support you!