Hello,
very likely you use fix natted contact in reg+proxy. You have to use
that in load balancer, since that is the instance that sees the right
public ip address for UA. reg+proxy will see IP address of LB as being
source IP address.
Cheers,
Daniel
On 03/12/2010 12:15 PM, Pavel Miskov wrote:
Hello Inaki,
thanks for replying and here is more readable form taken from LB:
Pavel
#
U +0.000000 UAC_A_PUB_IP:31488 -> LB_IP:5678
INVITE sip:UAC_B@test.com SIP/2.0.
Via: SIP/2.0/UDP
UAC_A_PRIV_IP:31488;branch=z9hG4bK-d8754z-a9127351d94a483a-1---d8754z-;rport.
Max-Forwards: 70.
Contact:<sip:UAC_A@UAC_A_PRIV_IP:31488>.
To: "UAC_B"<sip:UAC_B@test.com>.
From: "UAC_A"<sip:UAC_A@test.com>;tag=406aba65.
Call-ID: YjEyNjJhYzczOTIyYWYyMjkwZGZiOTFmMjdkNmNmODk..
CSeq: 2 INVITE.
Allow: INVITE, ACK, CANCEL, OPTIONS, BYE, REFER, NOTIFY, MESSAGE,
SUBSCRIBE, INFO.
Content-Type: application/sdp.
Proxy-Authorization: Digest
username="UAC_A",realm="test.com",nonce="4b9a102f000000030feed796808fa4eb1df2de3c9a2b1034",uri="sip:UAC_B@test.com",response="2f023b974dd4cde6f29387681168de8f",algorithm=MD5.
User-Agent: X-Lite release 1100l stamp 47546.
Content-Length: 368.
#
U +0.004000 LB_IP:5678 -> UAC_A_PUB_IP:31488
SIP/2.0 100 Giving a try.
Via: SIP/2.0/UDP
UAC_A_PRIV_IP:31488;branch=z9hG4bK-d8754z-a9127351d94a483a-1---d8754z-;rport=31488;received=UACs_PUB_IP.
To: "UAC_B"<sip:UAC_B@test.com>.
From: "UAC_A"<sip:UAC_A@test.com>;tag=406aba65.
Call-ID: YjEyNjJhYzczOTIyYWYyMjkwZGZiOTFmMjdkNmNmODk..
CSeq: 2 INVITE.
Server: Kamailio (1.5.1-tls (x86_64/linux)).
Content-Length: 0.
.
#
U +0.000000 LB_IP:5678 -> REG_PROXY_IP:5166
INVITE sip:UAC_B@test.com SIP/2.0.
Record-Route:<sip:LB_IP:5678;lr=on>.
Via: SIP/2.0/UDP LB_IP:5678;branch=z9hG4bK3ae9.a8d68282.0.
Via: SIP/2.0/UDP
UAC_A_PRIV_IP:31488;received=UACs_PUB_IP;branch=z9hG4bK-d8754z-a9127351d94a483a-1---d8754z-;rport=31488.
Max-Forwards: 69.
Contact:<sip:UAC_A@UAC_A_PUB_IP:31488>.
To: "UAC_B"<sip:UAC_B@test.com>.
From: "UAC_A"<sip:UAC_A@test.com>;tag=406aba65.
Call-ID: YjEyNjJhYzczOTIyYWYyMjkwZGZiOTFmMjdkNmNmODk..
CSeq: 2 INVITE.
Allow: INVITE, ACK, CANCEL, OPTIONS, BYE, REFER, NOTIFY, MESSAGE,
SUBSCRIBE, INFO.
Content-Type: application/sdp.
Proxy-Authorization: Digest
username="UAC_A",realm="test.com",nonce="4b9a102f000000030feed796808fa4eb1df2de3c9a2b1034",uri="sip:UAC_B@test.com",response="2f023b974dd4cde6f29387681168de8f",algorithm=MD5.
User-Agent: X-Lite release 1100l stamp 47546.
Content-Length: 368.
Path:<sip:LB_IP:5678;lr>.
.
#
U +0.000000 REG_PROXY_IP:5166 -> LB_IP:5678
SIP/2.0 100 Giving a try.
Via: SIP/2.0/UDP LB_IP:5678;branch=z9hG4bK3ae9.a8d68282.0.
Via: SIP/2.0/UDP
UAC_A_PRIV_IP:31488;received=UACs_PUB_IP;branch=z9hG4bK-d8754z-a9127351d94a483a-1---d8754z-;rport=31488.
To: "UAC_B"<sip:UAC_B@test.com>.
From: "UAC_A"<sip:UAC_A@test.com>;tag=406aba65.
Call-ID: YjEyNjJhYzczOTIyYWYyMjkwZGZiOTFmMjdkNmNmODk..
CSeq: 2 INVITE.
Server: Kamailio (1.5.1-tls (x86_64/linux)).
Content-Length: 0.
.
#
U +0.000000 REG_PROXY_IP:5166 -> LB_IP:5678
INVITE sip:UAC_B@UAC_B_PRIV_IP:31468;rinstance=06b43c2b0e1ae81a SIP/2.0.
Record-Route:<sip:REG_PROXY_IP:5166;lr=on;nat=yes>.
Record-Route:<sip:LB_IP:5678;lr=on>.
Via: SIP/2.0/UDP REG_PROXY_IP:5166;branch=z9hG4bK3ae9.ff046b92.0.
Via: SIP/2.0/UDP LB_IP:5678;branch=z9hG4bK3ae9.a8d68282.0.
Via: SIP/2.0/UDP
UAC_A_PRIV_IP:31488;received=UACs_PUB_IP;branch=z9hG4bK-d8754z-a9127351d94a483a-1---d8754z-;rport=31488.
Route:<sip:LB_IP:5678;lr;received="sip:UAC_B_PUB_IP:31468">.
Max-Forwards: 68.
Contact:<sip:UAC_A@UAC_A_PUB_IP:31488>.
To: "UAC_B"<sip:UAC_B@test.com>.
From: "UAC_A"<sip:UAC_A@test.com>;tag=406aba65.
Call-ID: YjEyNjJhYzczOTIyYWYyMjkwZGZiOTFmMjdkNmNmODk..
CSeq: 2 INVITE.
Allow: INVITE, ACK, CANCEL, OPTIONS, BYE, REFER, NOTIFY, MESSAGE,
SUBSCRIBE, INFO.
Content-Type: application/sdp.
User-Agent: X-Lite release 1100l stamp 47546.
Content-Length: 384.
Path:<sip:LB_IP:5678;lr>.
.
#
U +0.032000 LB_IP:5678 -> REG_PROXY_IP:5166
SIP/2.0 100 Giving a try.
Via: SIP/2.0/UDP
REG_PROXY_IP:5166;branch=z9hG4bK3ae9.ff046b92.0;rport=5166;received=REG_PROXY_IP.
Via: SIP/2.0/UDP LB_IP:5678;branch=z9hG4bK3ae9.a8d68282.0.
Via: SIP/2.0/UDP
UAC_A_PRIV_IP:31488;received=UACs_PUB_IP;branch=z9hG4bK-d8754z-a9127351d94a483a-1---d8754z-;rport=31488.
To: "UAC_B"<sip:UAC_B@test.com>.
From: "UAC_A"<sip:UAC_A@test.com>;tag=406aba65.
Call-ID: YjEyNjJhYzczOTIyYWYyMjkwZGZiOTFmMjdkNmNmODk..
CSeq: 2 INVITE.
Server: Kamailio (1.5.1-tls (x86_64/linux)).
Content-Length: 0.
.
#
U +0.000000 LB_IP:5678 -> UAC_B_PUB_IP:31468
INVITE sip:UAC_B@UAC_B_PRIV_IP:31468;rinstance=06b43c2b0e1ae81a SIP/2.0.
Record-Route:<sip:REG_PROXY_IP:5166;lr=on;nat=yes>.
Record-Route:<sip:LB_IP:5678;lr=on>.
Via: SIP/2.0/UDP LB_IP:5678;branch=z9hG4bK3ae9.b8d68282.0.
Via: SIP/2.0/UDP
REG_PROXY_IP:5166;rport=5166;received=REG_PROXY_IP;branch=z9hG4bK3ae9.ff046b92.0.
Via: SIP/2.0/UDP LB_IP:5678;branch=z9hG4bK3ae9.a8d68282.0.
Via: SIP/2.0/UDP
UAC_A_PRIV_IP:31488;received=UACs_PUB_IP;branch=z9hG4bK-d8754z-a9127351d94a483a-1---d8754z-;rport=31488.
Max-Forwards: 67.
Contact:<sip:UAC_A@UAC_A_PUB_IP:31488>.
To: "UAC_B"<sip:UAC_B@test.com>.
From: "UAC_A"<sip:UAC_A@test.com>;tag=406aba65.
Call-ID: YjEyNjJhYzczOTIyYWYyMjkwZGZiOTFmMjdkNmNmODk..
CSeq: 2 INVITE.
Allow: INVITE, ACK, CANCEL, OPTIONS, BYE, REFER, NOTIFY, MESSAGE,
SUBSCRIBE, INFO.
Content-Type: application/sdp.
User-Agent: X-Lite release 1100l stamp 47546.
Content-Length: 384.
Path:<sip:LB_IP:5678;lr>.
.
#
U +0.104000 UAC_B_PUB_IP:31468 -> LB_IP:5678
SIP/2.0 180 Ringing.
Via: SIP/2.0/UDP LB_IP:5678;branch=z9hG4bK3ae9.b8d68282.0.
Via: SIP/2.0/UDP
REG_PROXY_IP:5166;rport=5166;received=REG_PROXY_IP;branch=z9hG4bK3ae9.ff046b92.0.
Via: SIP/2.0/UDP LB_IP:5678;branch=z9hG4bK3ae9.a8d68282.0.
Via: SIP/2.0/UDP
UAC_A_PRIV_IP:31488;received=UACs_PUB_IP;branch=z9hG4bK-d8754z-a9127351d94a483a-1---d8754z-;rport=31488.
Record-Route:<sip:REG_PROXY_IP:5166;lr;nat=yes>.
Record-Route:<sip:LB_IP:5678;lr=on>.
Contact:<sip:UAC_B@UAC_B_PRIV_IP:31468;rinstance=06b43c2b0e1ae81a>.
To: "UAC_B"<sip:UAC_B@test.com>;tag=d6775b48.
From: "UAC_A"<sip:UAC_A@test.com>;tag=406aba65.
Call-ID: YjEyNjJhYzczOTIyYWYyMjkwZGZiOTFmMjdkNmNmODk..
CSeq: 2 INVITE.
User-Agent: X-Lite release 1100l stamp 47546.
Content-Length: 0.
.
#
U +0.000000 LB_IP:5678 -> REG_PROXY_IP:5166
SIP/2.0 180 Ringing.
Via: SIP/2.0/UDP
REG_PROXY_IP:5166;rport=5166;received=REG_PROXY_IP;branch=z9hG4bK3ae9.ff046b92.0.
Via: SIP/2.0/UDP LB_IP:5678;branch=z9hG4bK3ae9.a8d68282.0.
Via: SIP/2.0/UDP
UAC_A_PRIV_IP:31488;received=UACs_PUB_IP;branch=z9hG4bK-d8754z-a9127351d94a483a-1---d8754z-;rport=31488.
Record-Route:<sip:REG_PROXY_IP:5166;lr;nat=yes>.
Record-Route:<sip:LB_IP:5678;lr=on>.
Contact:<sip:UAC_B@UAC_B_PRIV_IP:31468;rinstance=06b43c2b0e1ae81a>.
To: "UAC_B"<sip:UAC_B@test.com>;tag=d6775b48.
From: "UAC_A"<sip:UAC_A@test.com>;tag=406aba65.
Call-ID: YjEyNjJhYzczOTIyYWYyMjkwZGZiOTFmMjdkNmNmODk..
CSeq: 2 INVITE.
User-Agent: X-Lite release 1100l stamp 47546.
Content-Length: 0.
.
#
U +0.004000 REG_PROXY_IP:5166 -> LB_IP:5678
SIP/2.0 180 Ringing.
Via: SIP/2.0/UDP LB_IP:5678;branch=z9hG4bK3ae9.a8d68282.0.
Via: SIP/2.0/UDP
UAC_A_PRIV_IP:31488;received=UACs_PUB_IP;branch=z9hG4bK-d8754z-a9127351d94a483a-1---d8754z-;rport=31488.
Record-Route:<sip:REG_PROXY_IP:5166;lr;nat=yes>.
Record-Route:<sip:LB_IP:5678;lr=on>.
Contact:<sip:UAC_B@LB_IP:5678;rinstance=06b43c2b0e1ae81a>.
To: "UAC_B"<sip:UAC_B@test.com>;tag=d6775b48.
From: "UAC_A"<sip:UAC_A@test.com>;tag=406aba65.
Call-ID: YjEyNjJhYzczOTIyYWYyMjkwZGZiOTFmMjdkNmNmODk..
CSeq: 2 INVITE.
User-Agent: X-Lite release 1100l stamp 47546.
Content-Length: 0.
.
#
U +0.000000 LB_IP:5678 -> UAC_A_PUB_IP:31488
SIP/2.0 180 Ringing.
Via: SIP/2.0/UDP
UAC_A_PRIV_IP:31488;received=UACs_PUB_IP;branch=z9hG4bK-d8754z-a9127351d94a483a-1---d8754z-;rport=31488.
Record-Route:<sip:REG_PROXY_IP:5166;lr;nat=yes>.
Record-Route:<sip:LB_IP:5678;lr=on>.
Contact:<sip:UAC_B@LB_IP:5678;rinstance=06b43c2b0e1ae81a>.
To: "UAC_B"<sip:UAC_B@test.com>;tag=d6775b48.
From: "UAC_A"<sip:UAC_A@test.com>;tag=406aba65.
Call-ID: YjEyNjJhYzczOTIyYWYyMjkwZGZiOTFmMjdkNmNmODk..
CSeq: 2 INVITE.
User-Agent: X-Lite release 1100l stamp 47546.
Content-Length: 0.
.
#
U +0.732000 UAC_B_PUB_IP:31468 -> LB_IP:5678
SIP/2.0 200 OK.
Via: SIP/2.0/UDP LB_IP:5678;branch=z9hG4bK3ae9.b8d68282.0.
Via: SIP/2.0/UDP
REG_PROXY_IP:5166;rport=5166;received=REG_PROXY_IP;branch=z9hG4bK3ae9.ff046b92.0.
Via: SIP/2.0/UDP LB_IP:5678;branch=z9hG4bK3ae9.a8d68282.0.
Via: SIP/2.0/UDP
UAC_A_PRIV_IP:31488;received=UACs_PUB_IP;branch=z9hG4bK-d8754z-a9127351d94a483a-1---d8754z-;rport=31488.
Record-Route:<sip:REG_PROXY_IP:5166;lr;nat=yes>.
Record-Route:<sip:LB_IP:5678;lr=on>.
Contact:<sip:UAC_B@UAC_B_PRIV_IP:31468;rinstance=06b43c2b0e1ae81a>.
To: "UAC_B"<sip:UAC_B@test.com>;tag=d6775b48.
From: "UAC_A"<sip:UAC_A@test.com>;tag=406aba65.
Call-ID: YjEyNjJhYzczOTIyYWYyMjkwZGZiOTFmMjdkNmNmODk..
CSeq: 2 INVITE.
Session-Expires: 95;refresher=uas.
Min-SE: 90.
Allow: INVITE, ACK, CANCEL, OPTIONS, BYE, REFER, NOTIFY, MESSAGE,
SUBSCRIBE, INFO.
Content-Type: application/sdp.
Supported: timer.
User-Agent: X-Lite release 1100l stamp 47546.
Content-Length: 364.
.
#
U +0.000000 LB_IP:5678 -> REG_PROXY_IP:5166
SIP/2.0 200 OK.
Via: SIP/2.0/UDP
REG_PROXY_IP:5166;rport=5166;received=REG_PROXY_IP;branch=z9hG4bK3ae9.ff046b92.0.
Via: SIP/2.0/UDP LB_IP:5678;branch=z9hG4bK3ae9.a8d68282.0.
Via: SIP/2.0/UDP
UAC_A_PRIV_IP:31488;received=UACs_PUB_IP;branch=z9hG4bK-d8754z-a9127351d94a483a-1---d8754z-;rport=31488.
Record-Route:<sip:REG_PROXY_IP:5166;lr;nat=yes>.
Record-Route:<sip:LB_IP:5678;lr=on>.
Contact:<sip:UAC_B@UAC_B_PRIV_IP:31468;rinstance=06b43c2b0e1ae81a>.
To: "UAC_B"<sip:UAC_B@test.com>;tag=d6775b48.
From: "UAC_A"<sip:UAC_A@test.com>;tag=406aba65.
Call-ID: YjEyNjJhYzczOTIyYWYyMjkwZGZiOTFmMjdkNmNmODk..
CSeq: 2 INVITE.
Session-Expires: 95;refresher=uas.
Min-SE: 90.
Allow: INVITE, ACK, CANCEL, OPTIONS, BYE, REFER, NOTIFY, MESSAGE,
SUBSCRIBE, INFO.
Content-Type: application/sdp.
Supported: timer.
User-Agent: X-Lite release 1100l stamp 47546.
Content-Length: 364.
.
#
U +0.008000 REG_PROXY_IP:5166 -> LB_IP:5678
SIP/2.0 200 OK.
Via: SIP/2.0/UDP LB_IP:5678;branch=z9hG4bK3ae9.a8d68282.0.
Via: SIP/2.0/UDP
UAC_A_PRIV_IP:31488;received=UACs_PUB_IP;branch=z9hG4bK-d8754z-a9127351d94a483a-1---d8754z-;rport=31488.
Record-Route:<sip:REG_PROXY_IP:5166;lr;nat=yes>.
Record-Route:<sip:LB_IP:5678;lr=on>.
Contact:<sip:UAC_B@LB_IP:5678;rinstance=06b43c2b0e1ae81a>.
To: "UAC_B"<sip:UAC_B@test.com>;tag=d6775b48.
From: "UAC_A"<sip:UAC_A@test.com>;tag=406aba65.
Call-ID: YjEyNjJhYzczOTIyYWYyMjkwZGZiOTFmMjdkNmNmODk..
CSeq: 2 INVITE.
Session-Expires: 95;refresher=uas.
Min-SE: 90.
Allow: INVITE, ACK, CANCEL, OPTIONS, BYE, REFER, NOTIFY, MESSAGE,
SUBSCRIBE, INFO.
Content-Type: application/sdp.
Supported: timer.
User-Agent: X-Lite release 1100l stamp 47546.
Content-Length: 381.
.
#
U +0.000000 LB_IP:5678 -> UAC_A_PUB_IP:31488
SIP/2.0 200 OK.
Via: SIP/2.0/UDP
UAC_A_PRIV_IP:31488;received=UACs_PUB_IP;branch=z9hG4bK-d8754z-a9127351d94a483a-1---d8754z-;rport=31488.
Record-Route:<sip:REG_PROXY_IP:5166;lr;nat=yes>.
Record-Route:<sip:LB_IP:5678;lr=on>.
Contact:<sip:UAC_B@LB_IP:5678;rinstance=06b43c2b0e1ae81a>.
To: "UAC_B"<sip:UAC_B@test.com>;tag=d6775b48.
From: "UAC_A"<sip:UAC_A@test.com>;tag=406aba65.
Call-ID: YjEyNjJhYzczOTIyYWYyMjkwZGZiOTFmMjdkNmNmODk..
CSeq: 2 INVITE.
Session-Expires: 95;refresher=uas.
Min-SE: 90.
Allow: INVITE, ACK, CANCEL, OPTIONS, BYE, REFER, NOTIFY, MESSAGE,
SUBSCRIBE, INFO.
Content-Type: application/sdp.
Supported: timer.
User-Agent: X-Lite release 1100l stamp 47546.
Content-Length: 381.
.
#
U +0.144000 UAC_A_PUB_IP:31488 -> LB_IP:5678
ACK sip:UAC_B@LB_IP:5678;rinstance=06b43c2b0e1ae81a SIP/2.0.
Via: SIP/2.0/UDP
UAC_A_PRIV_IP:31488;branch=z9hG4bK-d8754z-5f2152497c1dcb39-1---d8754z-;rport.
Max-Forwards: 70.
Route:<sip:LB_IP:5678;lr>.
Route:<sip:REG_PROXY_IP:5166;lr;nat=yes>.
Contact:<sip:UAC_A@UAC_A_PRIV_IP:31488>.
To: "UAC_B"<sip:UAC_B@test.com>;tag=d6775b48.
From: "UAC_A"<sip:UAC_A@test.com>;tag=406aba65.
Call-ID: YjEyNjJhYzczOTIyYWYyMjkwZGZiOTFmMjdkNmNmODk..
CSeq: 2 ACK.
Proxy-Authorization: Digest
username="UAC_A",realm="test.com",nonce="4b9a102f000000030feed796808fa4eb1df2de3c9a2b1034",uri="sip:UAC_B@test.com",response="2f023b974dd4cde6f29387681168de8f",algorithm=MD5.
User-Agent: X-Lite release 1100l stamp 47546.
Content-Length: 0.
.
#
U +0.000000 LB_IP:5678 -> REG_PROXY_IP:5166
ACK sip:REG_PROXY_IP:5166;lr;nat=yes SIP/2.0.
Via: SIP/2.0/UDP LB_IP:5678;branch=z9hG4bK3ae9.a8d68282.2.
Via: SIP/2.0/UDP
LB_IP:5678;rport=5678;received=LB_IP;branch=z9hG4bK3ae9.a8d68282.2.
Via: SIP/2.0/UDP
UAC_A_PRIV_IP:31488;received=UACs_PUB_IP;branch=z9hG4bK-d8754z-5f2152497c1dcb39-1---d8754z-;rport=31488.
Max-Forwards: 68.
Contact:<sip:UAC_A@UAC_A_PUB_IP:31488>.
To: "UAC_B"<sip:UAC_B@test.com>;tag=d6775b48.
From: "UAC_A"<sip:UAC_A@test.com>;tag=406aba65.
Call-ID: YjEyNjJhYzczOTIyYWYyMjkwZGZiOTFmMjdkNmNmODk..
CSeq: 2 ACK.
Proxy-Authorization: Digest
username="UAC_A",realm="test.com",nonce="4b9a102f000000030feed796808fa4eb1df2de3c9a2b1034",uri="sip:UAC_B@test.com",response="2f023b974dd4cde6f29387681168de8f",algorithm=MD5.
User-Agent: X-Lite release 1100l stamp 47546.
Content-Length: 0.
P-hint: rr-enforced.
P-hint: rr-enforced.
.
On Fri, Mar 12, 2010 at 11:04 AM, Iñaki Baz Castillo<ibc(a)aliax.net> wrote:
2010/3/12 Pavel
Miskov<miskov.pavel(a)gmail.com>om>:
Hello list,
let me first show my scenario:
UAC_A ---> LB ---> |
| PROXY+REG #1
| or
| PROXY+REG #2
UAC_B<--- LB<--- |
Could you please repeat the trace but in a easier format:
ngrep -d eth0 -W byline -T port 5060
--
Iñaki Baz Castillo
<ibc(a)aliax.net>
_______________________________________________
Kamailio (OpenSER) - Users mailing list
Users(a)lists.kamailio.org
http://lists.kamailio.org/cgi-bin/mailman/listinfo/users
http://lists.openser-project.org/cgi-bin/mailman/listinfo/users
--
Daniel-Constantin Mierla
Kamailio SIP Router Masterclass, Berlin, March 22-26, 2010
*