[Nice] component-state-changed change to FAIL

ly tran congly85 at yahoo.com
Thu Sep 27 21:02:16 PDT 2012


I see log of both side, and I got the same problem.
I think both side using symetric NAT routers, but how can I using TURN relay server in libnice ?
I folow the mailing list and know that I have to set nice_agent_set_relay_info(), but when I read the test-fullmode.c source code, I saw nice_agent_set_relay_info() only call in NICE_COMPATIBILITY_GOOGLE.
Can I call nice_agent_set_relay_info() with NICE_COMPATIBILITY_DRAFT19 ?

Here are my snip code
/* create nice agent */
self->v_agent=nice_agent_new(g_main_context_default(),NICE_COMPATIBILITY_DRAFT19);
self->v_stream_id=0;


g_signal_connect(G_OBJECT(self->v_agent),"candidate-gathering-done",
G_CALLBACK(priv_cb_candidate_gathering_done),self);
g_signal_connect(G_OBJECT(self->v_agent),"component-state-changed",
G_CALLBACK(priv_cb_component_state_changed),self);

interfaces=nice_list_local_interfaces();

.......

/*note:addastreamwithRTP/RTCPcomponents*/
self->v_stream_id=nice_agent_add_stream(self->v_agent,2);
self->ssrc=0;
Can I call nice_agent_set_relay_info() here ?



________________________________
 From: Youness Alaoui <youness.alaoui at collabora.co.uk>
To: nice at lists.freedesktop.org 
Sent: Friday, September 28, 2012 12:43 AM
Subject: Re: [Nice] component-state-changed change to FAIL
 
You move to FAIL state because you don't receive *any* response from the other
side. your log doesn't have any "received packet", so this means that either the
other side is not sending anything, hasn't been started properly, candidates
haven't been exchanged correctly... or the router on that network in that
different city as well as your local network are both symetric NAT routers,
which means you'd have to use a TURN relay server in order for it to succeed.

On 09/27/2012 04:54 AM, ly tran wrote:
> Hi,
> I setup 2 wifi network in the same company and setup a video call. It's succsess.
> But when I test with 2 wifi network at difference city, I got the following problem.
> Please se my log and tell me know why I always move to FAIL state.
> 
> ** Message: nice_agent_set_remote_candidates START
>   libnice-DEBUG: Agent 0x46773608: set_remote_candidates 1 1
>   libnice-DEBUG: Agent 0x46773608 : Adding remote candidate with addr
> [192.168.123.122]:42330 for s1/c1. U/P '(null)'/'(null)' prio: 2013266431
>   libnice-DEBUG: Agent 0x46773608 : creating new pair 0x5908800 state 5
>   libnice-DEBUG: Agent 0x46773608 : added a new conncheck 0x5908800 with
> foundation of '1:1' to list 1.
>   libnice-DEBUG: Agent 0x46773608 : stream 1 component 1 STATE-CHANGE 0 -> 2.
> ** Message: priv_cb_component_state_changed: stream_id=1, component_id=1,
> state=2, self=0x46771058
> ** Message: rtp comp 1, rtcp com 2, ready 4, disconnected 0 failed 5
>   libnice-DEBUG: Agent 0x46773608 : Adding remote candidate with addr
> [192.168.2.15]:39791 for s1/c1. U/P '(null)'/'(null)' prio: 2013266431
>   libnice-DEBUG: Agent 0x46773608 : creating new pair 0x59188b0 state 5
>   libnice-DEBUG: Agent 0x46773608 : added a new conncheck 0x59188b0 with
> foundation of '1:2' to list 1.
>   libnice-DEBUG: Agent 0x46773608 : Adding remote candidate with addr
> [169.254.224.159]:48202 for s1/c1. U/P '(null)'/'(null)' prio: 2013266431
>   libnice-DEBUG: Agent 0x46773608 : creating new pair 0x5928960 state 5
>   libnice-DEBUG: Agent 0x46773608 : added a new conncheck 0x5928960 with
> foundation of '1:3' to list 1.
>   libnice-DEBUG: Agent 0x46773608 : Pair 0x5908800 with s/c-id 1/1 (1:1) unfrozen.
>   libnice-DEBUG: Agent 0x46773608 : pair 0x5908800 state WAITING
>   libnice-DEBUG: Agent 0x46773608 : priv_conn_check_unfreeze_next returned 1
>   libnice-DEBUG: Agent 0x46773608 : pair 0x5908800 state IN_PROGRESS
>   libnice-DEBUG: Agent 0x46773608 : STUN-CC REQ to '192.168.123.122:42330',
> socket=57, pair=1:1 (c-id:1), tie=2169042258789247143, username='GFbX:nv/N' (9),
> password='EhKVewP4AlLqqZXOtaQWg7' (22), priority=1845494271.
>  Message HMAC-SHA1 message integrity:
>   key     : 0x45684b5665775034416c4c71715a584f746151576737
>   sent    : 0x5a4e6788d61f1da8fc1605673a02555c77a82f42
>  Message HMAC-SHA1 fingerprint: 0xe15bd63b
>   libnice-DEBUG: Agent 0x46773608: conncheck created 92 - 0x590886c
>   libnice-DEBUG: Agent 0x46773608 : timer tick #1: 2 frozen, 1 in-progress, 0
> waiting, 0 succeeded, 0 discovered, 0 nominated, 0 waiting-for-nom.
>   libnice-DEBUG: Agent 0x46773608 : priv_conn_check_tick_unlocked returned 1
>   libnice-DEBUG: Agent 0x46773608 : conn_check_schedule_next returning 1
> ** Message: nice_agent_set_remote_candidates END
>   libnice-DEBUG: Agent 0x46773608: set_remote_candidates 1 2
>   libnice-DEBUG: Agent 0x46773608 : Adding remote candidate with addr
> [192.168.123.122]:44381 for s1/c2. U/P '(null)'/'(null)' prio: 2013266430
>   libnice-DEBUG: Agent 0x46773608 : creating new pair 0x5938a10 state 5
>   libnice-DEBUG: Agent 0x46773608 : added a new conncheck 0x5938a10 with
> foundation of '1:1' to list 1.
>   libnice-DEBUG: Agent 0x46773608 : stream 1 component 2 STATE-CHANGE 0 -> 2.
> ** Message: priv_cb_component_state_changed: stream_id=1, component_id=2,
> state=2, self=0x46771058
> ** Message: rtp comp 1, rtcp com 2, ready 4, disconnected 0 failed 5
>   libnice-DEBUG: Agent 0x46773608 : Adding remote candidate with addr
> [192.168.2.15]:34392 for s1/c2. U/P '(null)'/'(null)' prio: 2013266430
>   libnice-DEBUG: Agent 0x46773608 : creating new pair 0x5948ac0 state 5
>   libnice-DEBUG: Agent 0x46773608 : added a new conncheck 0x5948ac0 with
> foundation of '1:2' to list 1.
>   libnice-DEBUG: Agent 0x46773608 : Adding remote candidate with addr
> [169.254.224.159]:39754 for s1/c2. U/P '(null)'/'(null)' prio: 2013266430
>   libnice-DEBUG: Agent 0x46773608 : creating new pair 0x5958b70 state 5
>   libnice-DEBUG: Agent 0x46773608 : added a new conncheck 0x5958b70 with
> foundation of '1:3' to list 1.
>   libnice-DEBUG: Agent 0x46773608 : Pair 0x59188b0 with s/c-id 1/1 (1:2) unfrozen.
>   libnice-DEBUG: Agent 0x46773608 : pair 0x59188b0 state WAITING
>   libnice-DEBUG: Agent 0x46773608 : priv_conn_check_unfreeze_next returned 1
>   libnice-DEBUG: Agent 0x46773608 : pair 0x59188b0 state IN_PROGRESS
>   libnice-DEBUG: Agent 0x46773608 : STUN-CC REQ to '192.168.2.15:39791',
> socket=57, pair=1:2 (c-id:1), tie=2169042258789247143, username='GFbX:nv/N' (9),
> password='EhKVewP4AlLqqZXOtaQWg7' (22), priority=1845494271.
>  Message HMAC-SHA1 message integrity:
>   key     : 0x45684b5665775034416c4c71715a584f746151576737
>   sent    : 0x8b886837a3597ccc31bbca85c2a3600b316ad4b3
>  Message HMAC-SHA1 fingerprint: 0x10b5df29
>   libnice-DEBUG: Agent 0x46773608: conncheck created 92 - 0x591891c
>   libnice-DEBUG: Agent 0x46773608 : priv_conn_check_tick_unlocked returned 1
>   libnice-DEBUG: Agent 0x46773608 : conn_check_schedule_next returning 1
> UA: remote SDP updated:
> v=0
> o=- 4140380030932220748 6097490881580283500 IN IP4 192.168.123.122
> s=-
> t=0 0
> m=video 42330 RTP/AVP 98
> c=IN IP4 192.168.123.122
> a=rtpmap:98 theora/90000
> a=candidate:1 1 UDP 2013266431 192.168.123.122 42330 typ host
> a=candidate:2 1 UDP 2013266431 192.168.2.15 39791 typ host
> a=candidate:3 1 UDP 2013266431 169.254.224.159 48202 typ host
> a=candidate:1 2 UDP 2013266430 192.168.123.122 44381 typ host
> a=candidate:2 2 UDP 2013266430 192.168.2.15 34392 typ host
> a=candidate:3 2 UDP 2013266430 169.254.224.159 39754 typ host
> a=ice-pwd:EhKVewP4AlLqqZXOtaQWg7
> a=ice-ufrag:GFbX
> a=rtcp:44381
> 
> 
> UA: call to sip:sbc at sip2sip.info is active => 'ready'
> audio inactive, video sendrecv, chat inactive.
>   libnice-DEBUG: Agent 0x46773608 : Pair 0x5928960 with s/c-id 1/1 (1:3) unfrozen.
>   libnice-DEBUG: Agent 0x46773608 : pair 0x5928960 state WAITING
>   libnice-DEBUG: Agent 0x46773608 : pair 0x5928960 state IN_PROGRESS
>   libnice-DEBUG: Agent 0x46773608 : STUN-CC REQ to '169.254.224.159:48202',
> socket=57, pair=1:3 (c-id:1), tie=2169042258789247143, username='GFbX:nv/N' (9),
> password='EhKVewP4AlLqqZXOtaQWg7' (22), priority=1845494271.
>  Message HMAC-SHA1 message integrity:
>   key     : 0x45684b5665775034416c4c71715a584f746151576737
>   sent    : 0xc66284bbbbee723ce5aa74c1d8a96423f1144647
>  Message HMAC-SHA1 fingerprint: 0x66b18657
>   libnice-DEBUG: Agent 0x46773608: conncheck created 92 - 0x59289cc
>   libnice-DEBUG: Agent 0x46773608 : Pair 0x5938a10 with s/c-id 1/2 (1:1) unfrozen.
>   libnice-DEBUG: Agent 0x46773608 : pair 0x5938a10 state WAITING
>   libnice-DEBUG: Agent 0x46773608 : pair 0x5938a10 state IN_PROGRESS
>   libnice-DEBUG: Agent 0x46773608 : STUN-CC REQ to '192.168.123.122:44381',
> socket=58, pair=1:1 (c-id:2), tie=2169042258789247143, username='GFbX:nv/N' (9),
> password='EhKVewP4AlLqqZXOtaQWg7' (22), priority=1845494270.
>  Message HMAC-SHA1 message integrity:
>   key     : 0x45684b5665775034416c4c71715a584f746151576737
>   sent    : 0x264bb548f1ca905998a0a1b3e124909ffd786a28
>  Message HMAC-SHA1 fingerprint: 0xe8e2d7eb
>   libnice-DEBUG: Agent 0x46773608: conncheck created 92 - 0x5938a7c
>   libnice-DEBUG: Agent 0x46773608 : Pair 0x5948ac0 with s/c-id 1/2 (1:2) unfrozen.
>   libnice-DEBUG: Agent 0x46773608 : pair 0x5948ac0 state WAITING
>   libnice-DEBUG: Agent 0x46773608 : pair 0x5948ac0 state IN_PROGRESS
>   libnice-DEBUG: Agent 0x46773608 : STUN-CC REQ to '192.168.2.15:34392',
> socket=58, pair=1:2 (c-id:2), tie=2169042258789247143, username='GFbX:nv/N' (9),
> password='EhKVewP4AlLqqZXOtaQWg7' (22), priority=1845494270.
>  Message HMAC-SHA1 message integrity:
>   key     : 0x45684b5665775034416c4c71715a584f746151576737
>   sent    : 0x883c22df8f8b9c17b690e3ca2c299f72c818fa8b
>  Message HMAC-SHA1 fingerprint: 0xa944093a
>   libnice-DEBUG: Agent 0x46773608: conncheck created 92 - 0x5948b2c
>   libnice-DEBUG: Agent 0x46773608 : Pair 0x5958b70 with s/c-id 1/2 (1:3) unfrozen.
>   libnice-DEBUG: Agent 0x46773608 : pair 0x5958b70 state WAITING
>   libnice-DEBUG: Agent 0x46773608 : pair 0x5958b70 state IN_PROGRESS
>   libnice-DEBUG: Agent 0x46773608 : STUN-CC REQ to '169.254.224.159:39754',
> socket=58, pair=1:3 (c-id:2), tie=2169042258789247143, username='GFbX:nv/N' (9),
> password='EhKVewP4AlLqqZXOtaQWg7' (22), priority=1845494270.
>  Message HMAC-SHA1 message integrity:
>   key     : 0x45684b5665775034416c4c71715a584f746151576737
>   sent    : 0x0d5431f79c5cb2ee59dc57465b9a6fe44c44edc8
>  Message HMAC-SHA1 fingerprint: 0xe4d75b1b
>   libnice-DEBUG: Agent 0x46773608: conncheck created 92 - 0x5958bdc
>   libnice-DEBUG: Agent 0x46773608 :STUN transaction retransmitted (timeout 1185ms).
>   libnice-DEBUG: Agent 0x46773608 :STUN transaction retransmitted (timeout 1185ms).
>   libnice-DEBUG: Agent 0x46773608 :STUN transaction retransmitted (timeout 1194ms).
>   libnice-DEBUG: Agent 0x46773608 :STUN transaction retransmitted (timeout 1195ms).
>   libnice-DEBUG: Agent 0x46773608 :STUN transaction retransmitted (timeout 1194ms).
>   libnice-DEBUG: Agent 0x46773608 :STUN transaction retransmitted (timeout 1195ms).
>   libnice-DEBUG: Agent 0x46773608 : timer tick #51: 0 frozen, 6 in-progress, 0
> waiting, 0 succeeded, 0 discovered, 0 nominated, 0 waiting-for-nom.
>   libnice-DEBUG: Agent 0x46773608 :STUN transaction retransmitted (timeout 2381ms).
>   libnice-DEBUG: Agent 0x46773608 :STUN transaction retransmitted (timeout 2381ms).
>   libnice-DEBUG: Agent 0x46773608 :STUN transaction retransmitted (timeout 2390ms).
>   libnice-DEBUG: Agent 0x46773608 :STUN transaction retransmitted (timeout 2391ms).
>   libnice-DEBUG: Agent 0x46773608 :STUN transaction retransmitted (timeout 2390ms).
>   libnice-DEBUG: Agent 0x46773608 :STUN transaction retransmitted (timeout 2391ms).
>   libnice-DEBUG: Agent 0x46773608 : timer tick #101: 0 frozen, 6 in-progress, 0
> waiting, 0 succeeded, 0 discovered, 0 nominated, 0 waiting-for-nom.
>   libnice-DEBUG: Agent 0x46773608 : timer tick #151: 0 frozen, 6 in-progress, 0
> waiting, 0 succeeded, 0 discovered, 0 nominated, 0 waiting-for-nom.
>   libnice-DEBUG: Agent 0x46773608 : timer tick #201: 0 frozen, 6 in-progress, 0
> waiting, 0 succeeded, 0 discovered, 0 nominated, 0 waiting-for-nom.
>   libnice-DEBUG: Agent 0x46773608 :STUN transaction retransmitted (timeout 4783ms).
>   libnice-DEBUG: Agent 0x46773608 :STUN transaction retransmitted (timeout 4783ms).
>   libnice-DEBUG: Agent 0x46773608 :STUN transaction retransmitted (timeout 4793ms).
>   libnice-DEBUG: Agent 0x46773608 :STUN transaction retransmitted (timeout 4793ms).
>   libnice-DEBUG: Agent 0x46773608 :STUN transaction retransmitted (timeout 4792ms).
>   libnice-DEBUG: Agent 0x46773608 :STUN transaction retransmitted (timeout 4793ms).
>   libnice-DEBUG: Agent 0x46773608 : timer tick #251: 0 frozen, 6 in-progress, 0
> waiting, 0 succeeded, 0 discovered, 0 nominated, 0 waiting-for-nom.
> finished hiding
>   libnice-DEBUG: Agent 0x46773608 : timer tick #301: 0 frozen, 6 in-progress, 0
> waiting, 0 succeeded, 0 discovered, 0 nominated, 0 waiting-for-nom.
>   libnice-DEBUG: Agent 0x46773608 : timer tick #351: 0 frozen, 6 in-progress, 0
> waiting, 0 succeeded, 0 discovered, 0 nominated, 0 waiting-for-nom.
>   libnice-DEBUG: Agent 0x46773608 : timer tick #401: 0 frozen, 6 in-progress, 0
> waiting, 0 succeeded, 0 discovered, 0 nominated, 0 waiting-for-nom.
>   libnice-DEBUG: Agent 0x46773608 : Retransmissions failed, giving up on
> connectivity check 0x5908800
>   libnice-DEBUG: Agent 0x46773608 : pair 0x5908800 state FAILED
>   libnice-DEBUG: Agent 0x46773608 : Retransmissions failed, giving up on
> connectivity check 0x59188b0
>   libnice-DEBUG: Agent 0x46773608 : pair 0x59188b0 state FAILED
>   libnice-DEBUG: Agent 0x46773608 : Retransmissions failed, giving up on
> connectivity check 0x5928960
>   libnice-DEBUG: Agent 0x46773608 : pair 0x5928960 state FAILED
>   libnice-DEBUG: Agent 0x46773608 : Retransmissions failed, giving up on
> connectivity check 0x5938a10
>   libnice-DEBUG: Agent 0x46773608 : pair 0x5938a10 state FAILED
>   libnice-DEBUG: Agent 0x46773608 : Retransmissions failed, giving up on
> connectivity check 0x5948ac0
>   libnice-DEBUG: Agent 0x46773608 : pair 0x5948ac0 state FAILED
>   libnice-DEBUG: Agent 0x46773608 : Retransmissions failed, giving up on
> connectivity check 0x5958b70
>   libnice-DEBUG: Agent 0x46773608 : pair 0x5958b70 state FAILED
>   libnice-DEBUG: Agent 0x46773608 : timer tick #434: 0 frozen, 0 in-progress, 0
> waiting, 0 succeeded, 0 discovered, 0 nominated, 0 waiting-for-nom.
>  libnice-DEBUG: Agent 0x46773608 : priv_conn_check_tick_unlocked: stopping
> conncheck timer
>  libnice-DEBUG: Agent 0x46773608 : stream 1 component 1 STATE-CHANGE 2 -> 5.
> ** Message: priv_cb_component_state_changed: stream_id=1, component_id=1,
> state=5, self=0x46771058
> ** Message: rtp comp 1, rtcp com 2, ready 4, disconnected 0 failed 5
> ** Message: Component state to FAILED.
> 
> 
> _______________________________________________
> nice mailing list
> nice at lists.freedesktop.org
> http://lists.freedesktop.org/mailman/listinfo/nice
> 



_______________________________________________
nice mailing list
nice at lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/nice
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.freedesktop.org/archives/nice/attachments/20120927/b81dd83d/attachment-0001.html>


More information about the nice mailing list