[sip-comm-dev] "Address already in use: Cannot bind" When placing SIP Calls


#1

Could any one send me a patch that solves error: "Address already in use: Cannot bind".
Or at least point out where to look for implementation in trunk (in which classes)?

I would appreciate this because some time ago I made branch I did some development and merging would be problematic.

···

-----Original Message-----
From: Carlos Alexandre [mailto:Carlos.Alexandre@nav.pt]
Sent: Friday, September 12, 2008 11:43 AM
To: dev@sip-communicator.dev.java.net
Subject: RE: [sip-comm-dev] "Address already in use: Cannot bind" When placing SIP Calls

Hello, i was trying 1336.
Ill give it another try.
Thankyou
Carlos

-----Original Message-----
From: Emil Ivov [mailto:emcho@sip-communicator.org]
Sent: quinta-feira, 11 de Setembro de 2008 18:19
To: dev@sip-communicator.dev.java.net
Subject: Re: [sip-comm-dev] "Address already in use: Cannot bind" When placing SIP Calls

Hey Carlos,

I just tried this with build 1339 (r4443). This was indeed a problem
yesterday but I've made 10 SIP calls and every time my media was leaving
from port 5000.

In other words the Damian's patch seems to have fixed the issue.

Are you sure you were using the latest build?

Cheers
Emil

Carlos Alexandre написа:

Hello
I Tryed the latest build and i tis not solved yet.

Basicly I can just make 50 calls, because the retrys count is 100, and the ports are incremented by two in each call, one for data and one for control.

The problem is that the ports are not released for reuse...

Hás anyone faced this problem? Or is it me?

Carlos

-----Original Message-----
From: Damian Minkov [mailto:damencho@damencho.com]
Sent: quinta-feira, 11 de Setembro de 2008 8:21
To: dev@sip-communicator.dev.java.net
Subject: Re: [sip-comm-dev] "Address already in use: Cannot bind" When placing SIP Calls

Hi,

check the latest build the issue is fixed there.

Thanks
damencho

Carlos Alexandre wrote:

Hello everyone.
I´ve testing SC on Windows against an Asterisk Voip Server.
-When I place my first Call, it Works fine.
-When I place my second call, I get this Exception

10:24:06.140 WARNING: impl.media.CallSessionImpl.allocatePort().1728 Retrying a bind because of a failure. Failed Address is: DataAddress: /0.0.0.0
ControlAddress: /0.0.0.0
DataPort: 5002
ControlPort: 5003
java.net.BindException: Address already in use: Cannot bind
        at java.net.PlainDatagramSocketImpl.bind0(Native Method)

-When I Place my third Call, i get the same Exception two times, for Dataport 5002 e ControlPort 5003, and also for , Dataport 5004 e ControlPort 5005, and so on, and soo n and so on

After 10 calls , im getting 11 exceptions, making the use os SC more difficult the more you use it.

How do I make the addresses reuseble ?
Thanks

Carlos

Below im sending the full Exception Stack

10:24:18.187 WARNING: impl.media.CallSessionImpl.allocatePort().1728 Retrying a bind because of a failure. Failed Address is: DataAddress: /0.0.0.0
ControlAddress: /0.0.0.0
DataPort: 5002
ControlPort: 5003
java.net.BindException: Address already in use: Cannot bind
        at java.net.PlainDatagramSocketImpl.bind0(Native Method)
        at java.net.PlainDatagramSocketImpl.bind(PlainDatagramSocketImpl.java:82)
        at java.net.DatagramSocket.bind(DatagramSocket.java:368)
        at java.net.DatagramSocket.<init>(DatagramSocket.java:210)
        at java.net.DatagramSocket.<init>(DatagramSocket.java:261)
        at java.net.DatagramSocket.<init>(DatagramSocket.java:234)
        at net.java.sip.communicator.impl.netaddr.NetworkAddressManagerServiceImpl.getPublicAddressFor(NetworkAddressManagerServiceImpl.java:385)
        at net.java.sip.communicator.impl.media.CallSessionImpl.allocatePort(CallSessionImpl.java:1720)
        at net.java.sip.communicator.impl.media.CallSessionImpl.allocateMediaPorts(CallSessionImpl.java:1810)
        at net.java.sip.communicator.impl.media.CallSessionImpl.createSessionDescription(CallSessionImpl.java:1261)
        at net.java.sip.communicator.impl.media.CallSessionImpl.createSdpOffer(CallSessionImpl.java:543)
        at net.java.sip.communicator.impl.protocol.sip.OperationSetBasicTelephonySipImpl.createOutgoingCall(OperationSetBasicTelephonySipImpl.java:238)
        at net.java.sip.communicator.impl.protocol.sip.OperationSetBasicTelephonySipImpl.createCall(OperationSetBasicTelephonySipImpl.java:98)
        at net.java.sip.communicator.impl.gui.main.call.CallManager$CreateCallThread.run(CallManager.java:1102)

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@sip-communicator.dev.java.net
For additional commands, e-mail: dev-help@sip-communicator.dev.java.net

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@sip-communicator.dev.java.net
For additional commands, e-mail: dev-help@sip-communicator.dev.java.net

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@sip-communicator.dev.java.net
For additional commands, e-mail: dev-help@sip-communicator.dev.java.net

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@sip-communicator.dev.java.net
For additional commands, e-mail: dev-help@sip-communicator.dev.java.net

NextiraOne Polska Sp. z o.o.
z siedziba w Warszawie
ul. Chmielna 85/87
00-805 Warszawa
Sad Rejonowy dla m.st. Warszawy,
XII Wydzial Gospodarczy KRS 0000063801
Prezes Zarzadu: Marek Kobielski,
Czlonkowie Zarzadu: Rafi Kouyoumdjian, Jean-Jacques Francois Berthelon
Kapital Zakladowy: 11 192 000 PLN
NIP: 952-18-51-834

Wiadomosc ta jest przeznaczona wylacznie dla ich odbiorcow i jest poufna. Jesli nie jestescie Panstwo adresatami tej wiadomosci, prosimy o jej usuniecie. Kazde przegladanie, rozpowszechnianie oraz kazde inne uzycie, takze uzycie w zaufany sposob przez osoby inne niz zamierzony odbiorca, jest zakazane.

This e-mail message is intended solely for the addressees and is confidential. If you receive this message in error, please delete it. Any review, dissemination or other use of, or taking of any action in reliance upon, this message by persons or entities other than the intended recipient is prohibited.