amazon web services - Coturn server - Relay is not working -


i trying setup coturn server webrtc based application. stuck couple of error messages unable understand, , can't find on them on internet.

here details app:

  • two users log on app, , 1 of user can share screen other - stream going in 1 direction

  • i able app work within intranet , on external networks. i'm confident application working fine wherever stun mode sufficient.

  • for of networks stun candidates failing, need turn server relay stream.

i have collected server logs server, in case identify problem based on them:

handle_udp_packet: new udp endpoint: local addr <ip address>:3478, remote addr <ip address2>:59942  handle_turn_command: stun method 0x1 ignored  handle_udp_packet: new udp endpoint: local addr <ip address>:3478, remote addr <ip address2>:59944  handle_turn_command: stun method 0x1 ignored  session 128000000000000096: realm <server url> user <>: incoming packet message processed, error 401: unauthorised  session 128000000000000097: realm <server url> user <>: incoming packet message processed, error 401: unauthorised  handle_turn_command: stun method 0x1 ignored  handle_turn_command: stun method 0x1 ignored  session 128000000000000096: realm <server url> user <>: incoming packet message processed, error 401: unauthorised  session 128000000000000097: realm <server url> user <>: incoming packet message processed, error 401: unauthorised  ipv4. local relay addr: <ip address>:64306  session 128000000000000096: new, realm=<server url>, username=<username>, lifetime=600  session 128000000000000096: realm <server url> user <username>: incoming packet allocate processed, success  ipv4. local relay addr: <ip address>:65384  session 128000000000000097: new, realm=<server url>, username=<username>, lifetime=600  session 128000000000000097: realm <server url> user <username>: incoming packet allocate processed, success  handle_turn_command: stun method 0x1 ignored  handle_turn_command: stun method 0x1 ignored  session 128000000000000096: realm <server url> user <username>: incoming packet allocate processed, success  session 128000000000000097: realm <server url> user <username>: incoming packet allocate processed, success  handle_turn_command: stun method 0x1 ignored  handle_turn_command: stun method 0x1 ignored  handle_turn_command: stun method 0x1 ignored  handle_turn_command: stun method 0x1 ignored  handle_turn_command: stun method 0x1 ignored  handle_turn_command: stun method 0x1 ignored  handle_turn_command: stun method 0x1 ignored  handle_turn_command: stun method 0x1 ignored  handle_turn_command: stun method 0x1 ignored  handle_turn_command: stun method 0x1 ignored  handle_turn_command: stun method 0x1 ignored  handle_turn_command: stun method 0x1 ignored  session 128000000000000096: refreshed, realm=<server url>, username=<username>, lifetime=0  session 128000000000000096: realm <server url> user <username>: incoming packet refresh processed, success  session 128000000000000097: refreshed, realm=<server url>, username=<username>, lifetime=0  session 128000000000000097: realm <server url> user <username>: incoming packet refresh processed, success  session 128000000000000096: closed (2nd stage), user <username> realm <server url> origin <>, local <ip address>:3478, remote <ip address2>:59942, reason: allocation timeout  session 128000000000000096: delete: realm=<server url>, username=<username>  session 128000000000000097: closed (2nd stage), user <username> realm <server url> origin <>, local <ip address>:3478, remote <ip address2>:59944, reason: allocation timeout  session 128000000000000097: delete: realm=<server url>, username=<username> 

here's how turnserver.conf file looks:

listening-port=3478 #tls-listening-port=443 realm=subdomain.domain.com server-name=subdomain.domain.com lt-cred-mech userdb=/etc/turnserdb.conf  cert=/home/ubuntu/certificate.crt pkey=/home/ubuntu/qc.key pkey-pwd=l1ght!t  no-stdout-log verbose 

i particularly concerned following points:

  • should assume since code working stun server, work working turn server well? hence, error means problem turn server?

  • i can see couple of errors stating 'allocation timeout'. mean refer ram/cpu/network allocation may insufficient?

  • some of requests have username portion empty '<>' rather '', , followed '401 unauthorized', while have triple checked rtcpeerconnection configurations - contain username , password.

  • apart logs above, have seen '438 wrong nonce' come in quite well. searched bit that, doesn't seem can control through js. related server configurations?

thanks! appreciate help.

there few problems in turn server setup had.

  • first off, had taken blog 2 years old. result, setup 2 years old - coturn monza. ideal way start coturn ami (amazon machine image)(version 4.5.0.6 details) , use setup server. alternatively, should have @ least taken recent setup through git repository.

  • second problem configurations. before posting question here, had missed open necessary ports on server. once did that, started getting stun responses, relay wasn't working yet.

  • third key problem configurations in turnserver.config file. had barely gone through configurations , after polaris's answer did. config file contains sufficient explanation each configuration, , problem indeed configurations.

  • the last problem test cases. wanted ensure relay "working", , during earlier stages of testing had identified particular network setup require relay (i.e. stuns not able complete request.) learned turn server not able through setup.

    we did spend time trying nostun mode (it's there in turnserver.config), due lack of test cases, never able confirm relay working.

    i don't understand test code on trickle ice page, believe results on there reliable.


Comments

Popular posts from this blog

c# - Update a combobox from a presenter (MVP) -

How to understand 2 main() functions after using uftrace to profile the C++ program? -

How to put a lock and transaction on table using spring 4 or above using jdbcTemplate and annotations like @Transactional? -