This Question is Answered

1 "correct" answer available (4 pts) 2 "helpful" answers available (2 pts)
6 Replies Last post: Jul 16, 2008 6:15 AM by rags  
Click to view rags's profile   12 posts since
Jul 14, 2008

Jul 14, 2008 7:37 AM

OpenSBC Media Proxying


Hi,

I am trying to use OpenSBC to proxy media between two endpoints. At the moment however, the two SIP endpoints are seeing each other's ip addresses in the SDP and not the SBC's - looks like the media addresses in the SDP aren't being rewritten. I have set the configuration option and checked the option to "Always Proxy Media".

For testing purposes, both SIP endpoints are on the same network but are connecting to different network interfaces on the OpenSBC. I don't know if that's causing media not to be proxied. Any ideas/suggestions would be appreciated.

Also, even though I have set SIP Logging to 5 on OpenSBC, I don't see anything being logged into syslog. Is this a known problem?

Thanks

Click to view joegen's profile   125 posts since
Apr 28, 2007
1. Jul 14, 2008 8:53 PM in response to: rags
Re: OpenSBC Media Proxying
Best guess, the call is getting proxied instead of using the B2BUA. Check the mode in general parameters and set it to B2BOnlyMode.

Joegen

rags wrote:

Hi,

I am trying to use OpenSBC to proxy media between two endpoints. At the moment however, the two SIP endpoints are seeing each other's ip addresses in the SDP and not the SBC's - looks like the media addresses in the SDP aren't being rewritten. I have set the configuration option and checked the option to "Always Proxy Media".

For testing purposes, both SIP endpoints are on the same network but are connecting to different network interfaces on the OpenSBC. I don't know if that's causing media not to be proxied. Any ideas/suggestions would be appreciated.

Also, even though I have set SIP Logging to 5 on OpenSBC, I don't see anything being logged into syslog. Is this a known problem?

Thanks

Click to view joegen's profile   125 posts since
Apr 28, 2007
3. Jul 15, 2008 5:39 AM in response to: rags
Re: OpenSBC Media Proxying
I see. So you are assuming that OpenSBC will not proxy media if the two legs came from the same subnet. Unfortunately, OpenSBC is not capable of doing this as of the moment. If you have suggestions how to accomplish this through C++ code, I'm willing to look at it and add the functionality. If any of the leg has a private IP address, OpenSBC will automatically proxy media. Now, I am not sure whether your problem is actually OpenSBC always proxying media or not at all. Level 5 logs would be desirable. they can be located in the same folder as opensbc binary undes the "logs" directory.

Joegen

rags wrote:

Hi,

Thanks for the suggestion. I tried it out but still no luck! If it helps, I can put up my entire config setting here - perhaps its something else that's quite trivial?

Is OpenSBC smart enough to realize that both endpoints are on the same network and can relay media to each other, thereby not taking any action to relay media? I would think not, but just wanted to confirm.

Rags

Click to view joegen's profile   125 posts since
Apr 28, 2007
5. Jul 15, 2008 8:08 PM in response to: rags
Re: OpenSBC Media Proxying
337808:42:17.775 INF: CID=0x0e9c *** CREATED *** PROXY Session ZmM2N2Q3Mzg5NTc4Nzc3NzAwNjc5NmIxZDUxYzY2NzM.

The line above gave it all away. Your call is being proxied and is not using the B2BUA subsystem. The first reason why OpenSBC would proxy this call is sip:07918039798@10.238.67.22 resolves to a remote IP and OpenSBC must be either running in ProxyOnly or Full mode. Since 10.238.67.22 is a remote address and does not resolve to OpenSBC (172.25.58.153), it allowed the call to do simple relay. Try the following steps.

1. Set OpenSBC to B2BOnly mode
2. In B2BUA-Routes add sip:07918039798* sip:10.238.67.22
3. Restart OpenSBC (changing modes require a restart)

Then make your call again.

Joegen

rags wrote:
Sorry, I think I got the wrong meaning across: what I meant was that I want the media proxied regardless, but its not happening at the moment.

Thanks for pointing out the location of the logs. I am copy-pasting the relevant bits from the logs, where the original invite is being proxied across, with no changes to the sdp content with media proxy information. Hope this provides a clue as to the error in my config setting:


337808:42:17.774 DBG: CID=0x0e9c *** CREATING TRANSACTION (IST) ***
337808:42:17.774 DBG: CID=0x0e9c Message: INVITE sip:07918039798@10.238.67.22 SIP/2.0
337808:42:17.774 DBG: CID=0x0e9c Call-Id: ZmM2N2Q3Mzg5NTc4Nzc3NzAwNjc5NmIxZDUxYzY2NzM.
337808:42:17.774 DBG: CID=0x0e9c
337808:42:17.774 DTL: CID=0x0e9c IST(635520095) *** CREATED *** - IST|ZmM2N2Q3Mzg5NTc4Nzc3NzAwNjc5NmIxZDUxYzY2NzM.|z9hG4bKe0fb.28f0c4a5.0|INVITE
337808:42:17.774 DTL: CID=0x0e9c IST(635520095) Event(SIPMessage) - INVITE sip:07918039798@10.238.67.22 SIP/2.0
337808:42:17.774 DBG: CID=0x0e9c TRANSACTION: (IST) INVITE sip:07918039798@10.238.67.22 SIP/2.0 State: 0
337808:42:17.775 DBG: CID=0x0e9c Event: SIPStack::Enqueue(INVITE sip:07918039798@10.238.67.22 SIP/2.0)
337808:42:17.775 DTL: CID=0x0e9c IST(635520095) StateIdle->StateProceeding
337808:42:17.775 DBG: CID=0x0e9c Event: B2BUserAgent::ProcessEvent( INVITE sip:07918039798@10.238.67.22 SIP/2.0 )
337808:42:17.775 DTL: CID=0x0e9c Event: ---> Inbound - INVITE sip:07918039798@10.238.67.22 SIP/2.0
337808:42:17.775 INF: CID=0x0e9c Session CREATED
337808:42:17.775 INF: CID=0x0e9c *** CREATED *** PROXY Session ZmM2N2Q3Mzg5NTc4Nzc3NzAwNjc5NmIxZDUxYzY2NzM.
337808:42:17.775 DTL: CID=0x0e9c *** MESSAGE ARRIVAL *** for SIP Session ZmM2N2Q3Mzg5NTc4Nzc3NzAwNjc5NmIxZDUxYzY2NzM.
337808:42:17.776 DBG: CID=0x0e9c
337808:42:17.776 DBG: CID=0x0e9c INVITE sip:07918039798@10.238.67.22 SIP/2.0
337808:42:17.776 DBG: CID=0x0e9c From: "rags" <sip:raghav@10.241.55.159>;tag=026d2b1f
337808:42:17.776 DBG: CID=0x0e9c To: "sip:07918039798@10.238.67.22" <sip:07918039798@10.238.67.22>
337808:42:17.776 DBG: CID=0x0e9c Via: SIP/2.0/UDP 132.146.185.195;branch=z9hG4bKe0fb.28f0c4a5.0;rport=5060;received=132.146.185.195
337808:42:17.776 DBG: CID=0x0e9c Via: SIP/2.0/UDP 10.73.132.197:10000;branch=z9hG4bK-d87543-f472a7290509fd10-1--d87543-;rport=10000
337808:42:17.776 DBG: CID=0x0e9c CSeq: 1 INVITE
337808:42:17.776 DBG: CID=0x0e9c Call-ID: ZmM2N2Q3Mzg5NTc4Nzc3NzAwNjc5NmIxZDUxYzY2NzM.
337808:42:17.776 DBG: CID=0x0e9c Contact: <sip:raghav@10.73.132.197:10000>
337808:42:17.776 DBG: CID=0x0e9c Record-Route: <sip:132.146.185.195;lr=on;ftag=026d2b1f>
337808:42:17.776 DBG: CID=0x0e9c User-Agent: X-Lite release 1011s stamp 41150
337808:42:17.776 DBG: CID=0x0e9c Max-Forwards: 69
337808:42:17.776 DBG: CID=0x0e9c Allow: INVITE, ACK, CANCEL, OPTIONS, BYE, REFER, NOTIFY, MESSAGE, SUBSCRIBE, INFO
337808:42:17.776 DBG: CID=0x0e9c Content-Type: application/sdp
337808:42:17.776 DBG: CID=0x0e9c Content-Length: 578
337808:42:17.776 DBG: CID=0x0e9c
337808:42:17.776 DBG: CID=0x0e9c v=0
337808:42:17.776 DBG: CID=0x0e9c o=- 8 2 IN IP4 10.73.132.197
337808:42:17.776 DBG: CID=0x0e9c s=CounterPath X-Lite 3.0
337808:42:17.776 DBG: CID=0x0e9c c=IN IP4 10.73.132.197
337808:42:17.776 DBG: CID=0x0e9c t=0 0
337808:42:17.776 DBG: CID=0x0e9c m=audio 10002 RTP/AVP 107 119 100 106 0 105 98 8 101
337808:42:17.776 DBG: CID=0x0e9c a=alt:1 4 : VfUyFaLJ SB/GLKoD 10.73.132.197 10002
337808:42:17.776 DBG: CID=0x0e9c a=alt:2 3 : F1JL93dN 624GThyt 138.250.176.196 10002
337808:42:17.776 DBG: CID=0x0e9c a=alt:3 2 : q+9APTLY cLZ43ft2 192.168.109.1 10002
337808:42:17.776 DBG: CID=0x0e9c a=alt:4 1 : ETnIXU+3 lwN5ypi3 192.168.120.1 10002
337808:42:17.776 DBG: CID=0x0e9c a=fmtp:101 0-15
337808:42:17.776 DBG: CID=0x0e9c a=rtpmap:107 BV32/16000
337808:42:17.776 DBG: CID=0x0e9c a=rtpmap:119 BV32-FEC/16000
337808:42:17.776 DBG: CID=0x0e9c a=rtpmap:100 SPEEX/16000
337808:42:17.776 DBG: CID=0x0e9c a=rtpmap:106 SPEEX-FEC/16000
337808:42:17.776 DBG: CID=0x0e9c a=rtpmap:105 SPEEX-FEC/8000
337808:42:17.776 DBG: CID=0x0e9c a=rtpmap:98 iLBC/8000
337808:42:17.776 DBG: CID=0x0e9c a=rtpmap:101 telephone-event/8000
337808:42:17.776 DBG: CID=0x0e9c a=sendrecv
337808:42:17.776 DBG: CID=0x0e9c
337808:42:17.777 PWL: CID=0x0000 *** NO STATIC ROUTE DEFINED *** From: sip:raghav@10.241.55.159 Target: sip:07918039798@10.238.67.22
337808:42:17.777 PWL: CID=0x0000 *** NO STATIC ROUTE DEFINED *** From: sip:raghav@10.241.55.159 Target: sip:07918039798@10.238.67.22
337808:42:17.777 DBG: CID=0x06cb CREATED via=172.25.58.151:5060 for target=10.238.67.22 protocol=UDP
337808:42:17.777 DBG: CID=0x0e9c Proxying request INVITE sip:07918039798@10.238.67.22 SIP/2.0
337808:42:17.778 DBG: CID=0x0e9c Finding transaction for INVITE sip:07918039798@10.238.67.22 SIP/2.0
337808:42:17.778 DBG: CID=0x0e9c Setting Transaction ID to ZmM2N2Q3Mzg5NTc4Nzc3NzAwNjc5NmIxZDUxYzY2NzM.|z9hG4bKf848a299b750dd11977fb74232f37f37-fe79ee50cf93b5672f379653f1114400|INVITE
337808:42:17.778 DBG: CID=0x0e9c
337808:42:17.778 DBG: CID=0x0e9c *** CREATING TRANSACTION (ICT) ***
337808:42:17.778 DBG: CID=0x0e9c Message: INVITE sip:07918039798@10.238.67.22 SIP/2.0
337808:42:17.778 DBG: CID=0x0e9c Call-Id: ZmM2N2Q3Mzg5NTc4Nzc3NzAwNjc5NmIxZDUxYzY2NzM.
337808:42:17.778 DBG: CID=0x0e9c
337808:42:17.778 DTL: CID=0x0e9c ICT(635520096) *** CREATED *** - ICT|ZmM2N2Q3Mzg5NTc4Nzc3NzAwNjc5NmIxZDUxYzY2NzM.|z9hG4bKf848a299b750dd11977fb74232f37f37-fe79ee50cf93b5672f379653f1114400|INVITE
337808:42:17.778 DTL: CID=0x0e9c ICT(635520096) Event(SIPMessage) - INVITE sip:07918039798@10.238.67.22 SIP/2.0
337808:42:17.778 DBG: CID=0x0e9c TRANSACTION: (ICT) INVITE sip:07918039798@10.238.67.22 SIP/2.0 State: 0
337808:42:17.779 DBG: CID=0x0e9c
337808:42:17.779 DBG: CID=0x0e9c TRANSMIT: REQ: INVITE (1)
337808:42:17.779 DBG: CID=0x0e9c TO: sip:07918039798@10.238.67.22
337808:42:17.779 DBG: CID=0x0e9c XOR: FALSE
337808:42:17.779 DBG: CID=0x0e9c DST: 10.238.67.22 PORT: 5060
337808:42:17.779 DBG: CID=0x0e9c
337808:42:17.779 DBG: CID=0x0e9c
337808:42:17.779 DBG: CID=0x0e9c SEND: enc=0 1470 Bytes to 10.238.67.22:5060:UDP (INVITE sip:07918039798@10.238.67.22 SIP/2.0) Interface Address=172.25.58.153
337808:42:17.779 DBG: CID=0x0e9c INVITE sip:07918039798@10.238.67.22 SIP/2.0
337808:42:17.779 DBG: CID=0x0e9c From: "rags" <sip:raghav@10.241.55.159>;tag=026d2b1f
337808:42:17.779 DBG: CID=0x0e9c To: "sip:07918039798@10.238.67.22" <sip:07918039798@10.238.67.22>
337808:42:17.779 DBG: CID=0x0e9c Via: SIP/2.0/UDP 172.25.58.151:5060;iid=9785;branch=z9hG4bKf848a299b750dd11977fb74232f37f37-fe79ee50cf93b5672f379653f1114400;uas-addr=10.238.67.22;rport
337808:42:17.779 DBG: CID=0x0e9c Via: SIP/2.0/UDP 132.146.185.195;branch=z9hG4bKe0fb.28f0c4a5.0;rport=5060;received=132.146.185.195
337808:42:17.779 DBG: CID=0x0e9c Via: SIP/2.0/UDP 10.73.132.197:10000;branch=z9hG4bK-d87543-f472a7290509fd10-1--d87543-;rport=10000
337808:42:17.779 DBG: CID=0x0e9c CSeq: 1 INVITE
337808:42:17.779 DBG: CID=0x0e9c Call-ID: ZmM2N2Q3Mzg5NTc4Nzc3NzAwNjc5NmIxZDUxYzY2NzM.
337808:42:17.779 DBG: CID=0x0e9c Contact: <sip:raghav@10.73.132.197:10000>
337808:42:17.779 DBG: CID=0x0e9c Record-Route: <sip:132.146.185.195;lr=on;ftag=026d2b1f>
337808:42:17.779 DBG: CID=0x0e9c User-Agent: X-Lite release 1011s stamp 41150
337808:42:17.779 DBG: CID=0x0e9c Max-Forwards: 68
337808:42:17.779 DBG: CID=0x0e9c Allow: INVITE, ACK, CANCEL, OPTIONS, BYE, REFER, NOTIFY, MESSAGE, SUBSCRIBE, INFO
337808:42:17.779 DBG: CID=0x0e9c Content-Type: application/sdp
337808:42:17.779 DBG: CID=0x0e9c Content-Length: 578
337808:42:17.779 DBG: CID=0x0e9c
337808:42:17.779 DBG: CID=0x0e9c v=0
337808:42:17.779 DBG: CID=0x0e9c o=- 8 2 IN IP4 10.73.132.197
337808:42:17.779 DBG: CID=0x0e9c s=CounterPath X-Lite 3.0
337808:42:17.779 DBG: CID=0x0e9c c=IN IP4 10.73.132.197
337808:42:17.779 DBG: CID=0x0e9c t=0 0
337808:42:17.779 DBG: CID=0x0e9c m=audio 10002 RTP/AVP 107 119 100 106 0 105 98 8 101
337808:42:17.779 DBG: CID=0x0e9c a=alt:1 4 : VfUyFaLJ SB/GLKoD 10.73.132.197 10002
337808:42:17.779 DBG: CID=0x0e9c a=alt:2 3 : F1JL93dN 624GThyt 138.250.176.196 10002
337808:42:17.779 DBG: CID=0x0e9c a=alt:3 2 : q+9APTLY cLZ43ft2 192.168.109.1 10002
337808:42:17.779 DBG: CID=0x0e9c a=alt:4 1 : ETnIXU+3 lwN5ypi3 192.168.120.1 10002
337808:42:17.779 DBG: CID=0x0e9c a=fmtp:101 0-15
337808:42:17.779 DBG: CID=0x0e9c a=rtpmap:107 BV32/16000
337808:42:17.779 DBG: CID=0x0e9c a=rtpmap:119 BV32-FEC/16000
337808:42:17.779 DBG: CID=0x0e9c a=rtpmap:100 SPEEX/16000
337808:42:17.779 DBG: CID=0x0e9c a=rtpmap:106 SPEEX-FEC/16000
337808:42:17.779 DBG: CID=0x0e9c a=rtpmap:105 SPEEX-FEC/8000
337808:42:17.779 DBG: CID=0x0e9c a=rtpmap:98 iLBC/8000
337808:42:17.779 DBG: CID=0x0e9c a=rtpmap:101 telephone-event/8000
337808:42:17.779 DBG: CID=0x0e9c a=sendrecv
337808:42:17.779 DBG: CID=0x0e9c
337808:42:17.780 DBG: CID=0x0e9c Finding transaction for INVITE sip:07918039798@10.238.67.22 SIP/2.0
337808:42:17.780 DBG: CID=0x0e9c Setting Transaction ID to ZmM2N2Q3Mzg5NTc4Nzc3NzAwNjc5NmIxZDUxYzY2NzM.|z9hG4bKf848a299b750dd11977fb74232f37f37-fe79ee50cf93b5672f379653f1114400|INVITE
337808:42:17.780 DTL: CID=0x0e9c Found ICT|ZmM2N2Q3Mzg5NTc4Nzc3NzAwNjc5NmIxZDUxYzY2NzM.|z9hG4bKf848a299b750dd11977fb74232f37f37-fe79ee50cf93b5672f379653f1114400|INVITE for INVITE sip:07918039798@10.238.67.22 SIP/2.0
337808:42:17.781 DTL: CID=0x0e9c ICT(635520096) Event(SIPMessage) - INVITE sip:07918039798@10.238.67.22 SIP/2.0
337808:42:17.781 INF: CID=0x0e9c Event: Setting UA Core Proxy to handle event INVITE
337808:42:17.781 DBG: CID=0x0e9c TRANSACTION: (ICT) INVITE sip:07918039798@10.238.67.22 SIP/2.0 State: 0
337808:42:17.781 DTL: CID=0x0e9c Event: ---> TransportWrite - INVITE
337808:42:17.781 DTL: CID=0x0e9c ICT(635520096) StateIdle->StateCalling(INVITE sip:07918039798@10.238.67.22 SIP/2.0)
337808:42:17.781 DBG: CID=0x0e9c ICT(635520096) Timer A( 500 ms ) STARTED
337808:42:17.781 DBG: CID=0x0e9c ICT(635520096) Timer B( 10000 ms ) STARTED
337808:42:17.795 DBG: CID=0x0e9c ICT(635520096) Timer A( 500 ms ) EXPIRED
337808:42:17.795 DTL: CID=0x0e9c ICT(635520096) Event( Timer-A ) Interval: 500
337808:42:17.796 DBG: CID=0x0e9c
337808:42:17.796 DBG: CID=0x0e9c TRANSMIT: REQ: INVITE (1)
337808:42:17.796 DBG: CID=0x0e9c TO: sip:07918039798@10.238.67.22
337808:42:17.796 DBG: CID=0x0e9c XOR: FALSE
337808:42:17.796 DBG: CID=0x0e9c DST: 10.238.67.22 PORT: 5060