PJSIP Client sending request on same connection

NS
Naveen Shivanna
Fri, Dec 20, 2019 1:05 PM

Hi All,

Hoping for a solution. Your help will be appreciated.

Problem

PJsip client sends SIP requests on the same TCP connection

Setup details

I have pjsip client service which sends request to SIP servers on Google Cloud Platform (GCP) installed on same VPC.
In between these 2 components we are introducing "Internal TCP load balancer". Basically we wanted to load balance the TCP traffic(SIP Messages) from pjsip client to different SIP Servers sitting behind the load balancer as depicted in the diagram below.

Observation

Since the pjsip have single transport created and hence the request goes on the same connection to Load Balancer ip-address. Load balancer balances the traffic based on the rule "Client IP, Src port and protocol".. Since any request coming from PBX1 pjsip client will always be having same ip-address and the connection is also same.. all the requests for going to one SIP Server. Because of this we are not able to load balance the traffic to other SIP Servers

Could any one suggest me how I can create different connections for each SIP session created by same PBX pjsip client (PBX1).

Regards
Naveen.S


NOTE: This e-mail (including any attachments) is for the sole use of the intended recipient(s) and may contain information that is confidential and/or protected by legal privilege. Any unauthorized review, use, copy, disclosure or distribution of this e-mail is strictly prohibited. If you are not the intended recipient, please notify Mitel immediately and destroy all copies of this e-mail. Mitel does not accept any liability for breach of security, error or virus that may result from the transmission of this message.

Hi All, Hoping for a solution. Your help will be appreciated. Problem PJsip client sends SIP requests on the same TCP connection Setup details I have pjsip client service which sends request to SIP servers on Google Cloud Platform (GCP) installed on same VPC. In between these 2 components we are introducing "Internal TCP load balancer". Basically we wanted to load balance the TCP traffic(SIP Messages) from pjsip client to different SIP Servers sitting behind the load balancer as depicted in the diagram below. Observation Since the pjsip have single transport created and hence the request goes on the same connection to Load Balancer ip-address. Load balancer balances the traffic based on the rule "Client IP, Src port and protocol".. Since any request coming from PBX1 pjsip client will always be having same ip-address and the connection is also same.. all the requests for going to one SIP Server. Because of this we are not able to load balance the traffic to other SIP Servers Could any one suggest me how I can create different connections for each SIP session created by same PBX pjsip client (PBX1). Regards Naveen.S ________________________________ NOTE: This e-mail (including any attachments) is for the sole use of the intended recipient(s) and may contain information that is confidential and/or protected by legal privilege. Any unauthorized review, use, copy, disclosure or distribution of this e-mail is strictly prohibited. If you are not the intended recipient, please notify Mitel immediately and destroy all copies of this e-mail. Mitel does not accept any liability for breach of security, error or virus that may result from the transmission of this message.
NS
Naveen Shivanna
Mon, Dec 23, 2019 9:18 AM

Hi All,

I have created an endpoint and starting the transport associating with the same endpoint.

Is there any example of using multiple endpoints and associating transport for each of the endpoints.. so that I can have multiple TCP connections created.

Anyone please give me suggestion for my use case.

Regards
Naveen.S

From: pjsip pjsip-bounces@lists.pjsip.org On Behalf Of Naveen Shivanna
Sent: Friday, December 20, 2019 6:35 PM
To: pjsip@lists.pjsip.org
Subject: [pjsip] PJSIP Client sending request on same connection

Hi All,

Hoping for a solution. Your help will be appreciated.

Problem

PJsip client sends SIP requests on the same TCP connection

Setup details

I have pjsip client service which sends request to SIP servers on Google Cloud Platform (GCP) installed on same VPC.
In between these 2 components we are introducing "Internal TCP load balancer". Basically we wanted to load balance the TCP traffic(SIP Messages) from pjsip client to different SIP Servers sitting behind the load balancer as depicted in the diagram below.

[cid:image001.jpg@01D5B99F.C5DD4910]

Observation

Since the pjsip have single transport created and hence the request goes on the same connection to Load Balancer ip-address. Load balancer balances the traffic based on the rule "Client IP, Src port and protocol".. Since any request coming from PBX1 pjsip client will always be having same ip-address and the connection is also same.. all the requests for going to one SIP Server. Because of this we are not able to load balance the traffic to other SIP Servers

Could any one suggest me how I can create different connections for each SIP session created by same PBX pjsip client (PBX1).

Regards
Naveen.S


NOTE: This e-mail (including any attachments) is for the sole use of the intended recipient(s) and may contain information that is confidential and/or protected by legal privilege. Any unauthorized review, use, copy, disclosure or distribution of this e-mail is strictly prohibited. If you are not the intended recipient, please notify Mitel immediately and destroy all copies of this e-mail. Mitel does not accept any liability for breach of security, error or virus that may result from the transmission of this message.

Hi All, I have created an endpoint and starting the transport associating with the same endpoint. Is there any example of using multiple endpoints and associating transport for each of the endpoints.. so that I can have multiple TCP connections created. Anyone please give me suggestion for my use case. Regards Naveen.S From: pjsip <pjsip-bounces@lists.pjsip.org> On Behalf Of Naveen Shivanna Sent: Friday, December 20, 2019 6:35 PM To: pjsip@lists.pjsip.org Subject: [pjsip] PJSIP Client sending request on same connection Hi All, Hoping for a solution. Your help will be appreciated. Problem PJsip client sends SIP requests on the same TCP connection Setup details I have pjsip client service which sends request to SIP servers on Google Cloud Platform (GCP) installed on same VPC. In between these 2 components we are introducing "Internal TCP load balancer". Basically we wanted to load balance the TCP traffic(SIP Messages) from pjsip client to different SIP Servers sitting behind the load balancer as depicted in the diagram below. [cid:image001.jpg@01D5B99F.C5DD4910] Observation Since the pjsip have single transport created and hence the request goes on the same connection to Load Balancer ip-address. Load balancer balances the traffic based on the rule "Client IP, Src port and protocol".. Since any request coming from PBX1 pjsip client will always be having same ip-address and the connection is also same.. all the requests for going to one SIP Server. Because of this we are not able to load balance the traffic to other SIP Servers Could any one suggest me how I can create different connections for each SIP session created by same PBX pjsip client (PBX1). Regards Naveen.S ________________________________ NOTE: This e-mail (including any attachments) is for the sole use of the intended recipient(s) and may contain information that is confidential and/or protected by legal privilege. Any unauthorized review, use, copy, disclosure or distribution of this e-mail is strictly prohibited. If you are not the intended recipient, please notify Mitel immediately and destroy all copies of this e-mail. Mitel does not accept any liability for breach of security, error or virus that may result from the transmission of this message.
NS
Naveen Shivanna
Wed, May 13, 2020 6:12 AM

Hi All,

Could anyone reply to my query below.

Regards
Naveen.S

From: pjsip pjsip-bounces@lists.pjsip.org On Behalf Of Naveen Shivanna
Sent: Friday, December 20, 2019 6:35 PM
To: pjsip@lists.pjsip.org
Subject: [pjsip] PJSIP Client sending request on same connection

Hi All,

Hoping for a solution. Your help will be appreciated.

Problem

PJsip client sends SIP requests on the same TCP connection

Setup details

I have pjsip client service which sends request to SIP servers on Google Cloud Platform (GCP) installed on same VPC.
In between these 2 components we are introducing "Internal TCP load balancer". Basically we wanted to load balance the TCP traffic(SIP Messages) from pjsip client to different SIP Servers sitting behind the load balancer as depicted in the diagram below.

[cid:image001.jpg@01D6291B.86CBD750]

Observation

Since the pjsip have single transport created and hence the request goes on the same connection to Load Balancer ip-address. Load balancer balances the traffic based on the rule "Client IP, Src port and protocol".. Since any request coming from PBX1 pjsip client will always be having same ip-address and the connection is also same.. all the requests for going to one SIP Server. Because of this we are not able to load balance the traffic to other SIP Servers

Could any one suggest me how I can create different connections for each SIP session created by same PBX pjsip client (PBX1).

Regards
Naveen.S


NOTE: This e-mail (including any attachments) is for the sole use of the intended recipient(s) and may contain information that is confidential and/or protected by legal privilege. Any unauthorized review, use, copy, disclosure or distribution of this e-mail is strictly prohibited. If you are not the intended recipient, please notify Mitel immediately and destroy all copies of this e-mail. Mitel does not accept any liability for breach of security, error or virus that may result from the transmission of this message.

Hi All, Could anyone reply to my query below. Regards Naveen.S From: pjsip <pjsip-bounces@lists.pjsip.org> On Behalf Of Naveen Shivanna Sent: Friday, December 20, 2019 6:35 PM To: pjsip@lists.pjsip.org Subject: [pjsip] PJSIP Client sending request on same connection Hi All, Hoping for a solution. Your help will be appreciated. Problem PJsip client sends SIP requests on the same TCP connection Setup details I have pjsip client service which sends request to SIP servers on Google Cloud Platform (GCP) installed on same VPC. In between these 2 components we are introducing "Internal TCP load balancer". Basically we wanted to load balance the TCP traffic(SIP Messages) from pjsip client to different SIP Servers sitting behind the load balancer as depicted in the diagram below. [cid:image001.jpg@01D6291B.86CBD750] Observation Since the pjsip have single transport created and hence the request goes on the same connection to Load Balancer ip-address. Load balancer balances the traffic based on the rule "Client IP, Src port and protocol".. Since any request coming from PBX1 pjsip client will always be having same ip-address and the connection is also same.. all the requests for going to one SIP Server. Because of this we are not able to load balance the traffic to other SIP Servers Could any one suggest me how I can create different connections for each SIP session created by same PBX pjsip client (PBX1). Regards Naveen.S ________________________________ NOTE: This e-mail (including any attachments) is for the sole use of the intended recipient(s) and may contain information that is confidential and/or protected by legal privilege. Any unauthorized review, use, copy, disclosure or distribution of this e-mail is strictly prohibited. If you are not the intended recipient, please notify Mitel immediately and destroy all copies of this e-mail. Mitel does not accept any liability for breach of security, error or virus that may result from the transmission of this message.
KF
Kjeld Flarup
Wed, May 13, 2020 8:37 AM

Hi Naveen

What load balancer are You using?
I would suggest using Kamailio, it is designed to do SIP load balancing.

Kjeld

Den ons. 13. maj 2020 kl. 08.13 skrev Naveen Shivanna <
naveen.shivanna@mitel.com>:

Hi All,

Could anyone reply to my query below.

Regards

Naveen.S

From: pjsip pjsip-bounces@lists.pjsip.org *On Behalf Of *Naveen
Shivanna
Sent: Friday, December 20, 2019 6:35 PM
To: pjsip@lists.pjsip.org
Subject: [pjsip] PJSIP Client sending request on same connection

Hi All,

Hoping for a solution. Your help will be appreciated.

Problem

PJsip client sends SIP requests on the same TCP connection

*Setup details *

I have pjsip client service which sends request to SIP servers on Google
Cloud Platform
(GCP) installed on same VPC.

In between these 2 components we are introducing "Internal TCP load
balancer
". Basically we wanted to load balance the TCP traffic(SIP
Messages) from pjsip client to different SIP Servers sitting behind the
load balancer as depicted in the diagram below.

Observation

Since the pjsip have single transport created and hence the request goes
on the same connection to Load Balancer ip-address. Load balancer balances
the traffic based on the rule “Client IP, Src port and protocol”.. Since
any request coming from PBX1 pjsip client will always be having same
ip-address and the connection is also same.. all the requests for going to
one SIP Server. Because of this we are not able to load balance the traffic
to other SIP Servers

Could any one suggest me how I can create different connections for each
SIP session created by same PBX pjsip client (PBX1).

Regards

Naveen.S

  • ________________________________  *

NOTE: This e-mail (including any attachments) is for the sole use of the
intended recipient(s) and may contain information that is confidential
and/or protected by legal privilege. Any unauthorized review, use, copy,
disclosure or distribution of this e-mail is strictly prohibited. If you
are not the intended recipient, please notify Mitel immediately and destroy
all copies of this e-mail. Mitel does not accept any liability for breach
of security, error or virus that may result from the transmission of this
message.


Visit our blog: http://blog.pjsip.org

pjsip mailing list
pjsip@lists.pjsip.org
http://lists.pjsip.org/mailman/listinfo/pjsip_lists.pjsip.org

--

--------------------- Med Liberalistiske Hilsner ----------------------

Civilingeniør, Kjeld Flarup - Mit sind er mere åbent end min tegnebog
Sofienlundvej 6B, 7560 Hjerm, Tlf: 40 29 41 49
Den ikke akademiske hjemmeside for liberalismen - www.liberalismen.dk

Hi Naveen What load balancer are You using? I would suggest using Kamailio, it is designed to do SIP load balancing. Kjeld Den ons. 13. maj 2020 kl. 08.13 skrev Naveen Shivanna < naveen.shivanna@mitel.com>: > Hi All, > > > > Could anyone reply to my query below. > > > > Regards > > Naveen.S > > > > *From:* pjsip <pjsip-bounces@lists.pjsip.org> *On Behalf Of *Naveen > Shivanna > *Sent:* Friday, December 20, 2019 6:35 PM > *To:* pjsip@lists.pjsip.org > *Subject:* [pjsip] PJSIP Client sending request on same connection > > > > Hi All, > > > > Hoping for a solution. Your help will be appreciated. > > > > *Problem* > > > > PJsip client sends SIP requests on the same TCP connection > > > > *Setup details * > > > > I have pjsip client service which sends request to SIP servers on *Google > Cloud Platform* (GCP) installed on same VPC. > > In between these 2 components we are introducing "*Internal TCP load > balancer*". Basically we wanted to load balance the TCP traffic(SIP > Messages) from pjsip client to different SIP Servers sitting behind the > load balancer as depicted in the diagram below. > > > > > > *Observation* > > > > Since the pjsip have single transport created and hence the request goes > on the same connection to Load Balancer ip-address. Load balancer balances > the traffic based on the rule “Client IP, Src port and protocol”.. Since > any request coming from PBX1 pjsip client will always be having same > ip-address and the connection is also same.. all the requests for going to > one SIP Server. Because of this we are not able to load balance the traffic > to other SIP Servers > > > > Could any one suggest me how I can create different connections for each > SIP session created by same PBX pjsip client (PBX1). > > > > Regards > > Naveen.S > > > > > > * ________________________________ * > > NOTE: This e-mail (including any attachments) is for the sole use of the > intended recipient(s) and may contain information that is confidential > and/or protected by legal privilege. Any unauthorized review, use, copy, > disclosure or distribution of this e-mail is strictly prohibited. If you > are not the intended recipient, please notify Mitel immediately and destroy > all copies of this e-mail. Mitel does not accept any liability for breach > of security, error or virus that may result from the transmission of this > message. > _______________________________________________ > Visit our blog: http://blog.pjsip.org > > pjsip mailing list > pjsip@lists.pjsip.org > http://lists.pjsip.org/mailman/listinfo/pjsip_lists.pjsip.org > -- --------------------- Med Liberalistiske Hilsner ---------------------- Civilingeniør, Kjeld Flarup - Mit sind er mere åbent end min tegnebog Sofienlundvej 6B, 7560 Hjerm, Tlf: 40 29 41 49 Den ikke akademiske hjemmeside for liberalismen - www.liberalismen.dk
NS
Naveen Shivanna
Wed, May 13, 2020 9:29 AM

Hi Kjeld,

We are using GCP Internal TCP load balancer.

For SIP Client we are using PJSIP.

Regards
Naveen.S
From: pjsip pjsip-bounces@lists.pjsip.org On Behalf Of Kjeld Flarup
Sent: Wednesday, May 13, 2020 2:08 PM
To: pjsip list pjsip@lists.pjsip.org
Subject: Re: [pjsip] PJSIP Client sending request on same connection

Hi Naveen

What load balancer are You using?
I would suggest using Kamailio, it is designed to do SIP load balancing.

Kjeld

Den ons. 13. maj 2020 kl. 08.13 skrev Naveen Shivanna <naveen.shivanna@mitel.commailto:naveen.shivanna@mitel.com>:
Hi All,

Could anyone reply to my query below.

Regards
Naveen.S

From: pjsip <pjsip-bounces@lists.pjsip.orgmailto:pjsip-bounces@lists.pjsip.org> On Behalf Of Naveen Shivanna
Sent: Friday, December 20, 2019 6:35 PM
To: pjsip@lists.pjsip.orgmailto:pjsip@lists.pjsip.org
Subject: [pjsip] PJSIP Client sending request on same connection

Hi All,

Hoping for a solution. Your help will be appreciated.

Problem

PJsip client sends SIP requests on the same TCP connection

Setup details

I have pjsip client service which sends request to SIP servers on Google Cloud Platform (GCP) installed on same VPC.
In between these 2 components we are introducing "Internal TCP load balancer". Basically we wanted to load balance the TCP traffic(SIP Messages) from pjsip client to different SIP Servers sitting behind the load balancer as depicted in the diagram below.

[cid:image001.jpg@01D62937.1C1F6D10]

Observation

Since the pjsip have single transport created and hence the request goes on the same connection to Load Balancer ip-address. Load balancer balances the traffic based on the rule “Client IP, Src port and protocol”.. Since any request coming from PBX1 pjsip client will always be having same ip-address and the connection is also same.. all the requests for going to one SIP Server. Because of this we are not able to load balance the traffic to other SIP Servers

Could any one suggest me how I can create different connections for each SIP session created by same PBX pjsip client (PBX1).

Regards
Naveen.S


NOTE: This e-mail (including any attachments) is for the sole use of the intended recipient(s) and may contain information that is confidential and/or protected by legal privilege. Any unauthorized review, use, copy, disclosure or distribution of this e-mail is strictly prohibited. If you are not the intended recipient, please notify Mitel immediately and destroy all copies of this e-mail. Mitel does not accept any liability for breach of security, error or virus that may result from the transmission of this message.


Visit our blog: http://blog.pjsip.orghttps://can01.safelinks.protection.outlook.com/?url=http%3A%2F%2Fblog.pjsip.org%2F&data=02%7C01%7Cnaveen.shivanna%40mitel.com%7C890f77e9c0da4a657f5d08d7f71907de%7C4bff5a2bb30d493981ff8f76138347df%7C1%7C0%7C637249559201391605&sdata=6vVmzZtGpNwlHBtkJgiiIlwQ7zaTyWCqmhe3t2nKj%2Fc%3D&reserved=0

pjsip mailing list
pjsip@lists.pjsip.orgmailto:pjsip@lists.pjsip.org
http://lists.pjsip.org/mailman/listinfo/pjsip_lists.pjsip.orghttps://can01.safelinks.protection.outlook.com/?url=http%3A%2F%2Flists.pjsip.org%2Fmailman%2Flistinfo%2Fpjsip_lists.pjsip.org&data=02%7C01%7Cnaveen.shivanna%40mitel.com%7C890f77e9c0da4a657f5d08d7f71907de%7C4bff5a2bb30d493981ff8f76138347df%7C1%7C0%7C637249559201401600&sdata=hPE7RB9RYKKMXPNDgl4css224kcaLnQ4O5silxXeIdA%3D&reserved=0

--

--------------------- Med Liberalistiske Hilsner ----------------------

Civilingeniør, Kjeld Flarup - Mit sind er mere åbent end min tegnebog

Sofienlundvej 6B, 7560 Hjerm, Tlf: 40 29 41 49

Den ikke akademiske hjemmeside for liberalismen - www.liberalismen.dkhttps://can01.safelinks.protection.outlook.com/?url=http%3A%2F%2Fwww.liberalismen.dk%2F&data=02%7C01%7Cnaveen.shivanna%40mitel.com%7C890f77e9c0da4a657f5d08d7f71907de%7C4bff5a2bb30d493981ff8f76138347df%7C1%7C0%7C637249559201401600&sdata=TtkHeeYFVY%2FbB8tBjB3ptfc%2B10TzUWdLQTC7%2Bay6nC8%3D&reserved=0

Hi Kjeld, We are using GCP Internal TCP load balancer. For SIP Client we are using PJSIP. Regards Naveen.S From: pjsip <pjsip-bounces@lists.pjsip.org> On Behalf Of Kjeld Flarup Sent: Wednesday, May 13, 2020 2:08 PM To: pjsip list <pjsip@lists.pjsip.org> Subject: Re: [pjsip] PJSIP Client sending request on same connection Hi Naveen What load balancer are You using? I would suggest using Kamailio, it is designed to do SIP load balancing. Kjeld Den ons. 13. maj 2020 kl. 08.13 skrev Naveen Shivanna <naveen.shivanna@mitel.com<mailto:naveen.shivanna@mitel.com>>: Hi All, Could anyone reply to my query below. Regards Naveen.S From: pjsip <pjsip-bounces@lists.pjsip.org<mailto:pjsip-bounces@lists.pjsip.org>> On Behalf Of Naveen Shivanna Sent: Friday, December 20, 2019 6:35 PM To: pjsip@lists.pjsip.org<mailto:pjsip@lists.pjsip.org> Subject: [pjsip] PJSIP Client sending request on same connection Hi All, Hoping for a solution. Your help will be appreciated. Problem PJsip client sends SIP requests on the same TCP connection Setup details I have pjsip client service which sends request to SIP servers on Google Cloud Platform (GCP) installed on same VPC. In between these 2 components we are introducing "Internal TCP load balancer". Basically we wanted to load balance the TCP traffic(SIP Messages) from pjsip client to different SIP Servers sitting behind the load balancer as depicted in the diagram below. [cid:image001.jpg@01D62937.1C1F6D10] Observation Since the pjsip have single transport created and hence the request goes on the same connection to Load Balancer ip-address. Load balancer balances the traffic based on the rule “Client IP, Src port and protocol”.. Since any request coming from PBX1 pjsip client will always be having same ip-address and the connection is also same.. all the requests for going to one SIP Server. Because of this we are not able to load balance the traffic to other SIP Servers Could any one suggest me how I can create different connections for each SIP session created by same PBX pjsip client (PBX1). Regards Naveen.S ________________________________ NOTE: This e-mail (including any attachments) is for the sole use of the intended recipient(s) and may contain information that is confidential and/or protected by legal privilege. Any unauthorized review, use, copy, disclosure or distribution of this e-mail is strictly prohibited. If you are not the intended recipient, please notify Mitel immediately and destroy all copies of this e-mail. Mitel does not accept any liability for breach of security, error or virus that may result from the transmission of this message. _______________________________________________ Visit our blog: http://blog.pjsip.org<https://can01.safelinks.protection.outlook.com/?url=http%3A%2F%2Fblog.pjsip.org%2F&data=02%7C01%7Cnaveen.shivanna%40mitel.com%7C890f77e9c0da4a657f5d08d7f71907de%7C4bff5a2bb30d493981ff8f76138347df%7C1%7C0%7C637249559201391605&sdata=6vVmzZtGpNwlHBtkJgiiIlwQ7zaTyWCqmhe3t2nKj%2Fc%3D&reserved=0> pjsip mailing list pjsip@lists.pjsip.org<mailto:pjsip@lists.pjsip.org> http://lists.pjsip.org/mailman/listinfo/pjsip_lists.pjsip.org<https://can01.safelinks.protection.outlook.com/?url=http%3A%2F%2Flists.pjsip.org%2Fmailman%2Flistinfo%2Fpjsip_lists.pjsip.org&data=02%7C01%7Cnaveen.shivanna%40mitel.com%7C890f77e9c0da4a657f5d08d7f71907de%7C4bff5a2bb30d493981ff8f76138347df%7C1%7C0%7C637249559201401600&sdata=hPE7RB9RYKKMXPNDgl4css224kcaLnQ4O5silxXeIdA%3D&reserved=0> -- --------------------- Med Liberalistiske Hilsner ---------------------- Civilingeniør, Kjeld Flarup - Mit sind er mere åbent end min tegnebog Sofienlundvej 6B, 7560 Hjerm, Tlf: 40 29 41 49 Den ikke akademiske hjemmeside for liberalismen - www.liberalismen.dk<https://can01.safelinks.protection.outlook.com/?url=http%3A%2F%2Fwww.liberalismen.dk%2F&data=02%7C01%7Cnaveen.shivanna%40mitel.com%7C890f77e9c0da4a657f5d08d7f71907de%7C4bff5a2bb30d493981ff8f76138347df%7C1%7C0%7C637249559201401600&sdata=TtkHeeYFVY%2FbB8tBjB3ptfc%2B10TzUWdLQTC7%2Bay6nC8%3D&reserved=0>
KF
Kjeld Flarup
Wed, May 13, 2020 11:46 AM

I Think that it is wrong to fix this in the client.

Somehow I think that You are lucky that a normal TCP load balancer works.

Kjeld

Den ons. 13. maj 2020 kl. 11.30 skrev Naveen Shivanna <
naveen.shivanna@mitel.com>:

Hi Kjeld,

We are using GCP Internal TCP load balancer.

For SIP Client we are using PJSIP.

Regards

Naveen.S

From: pjsip pjsip-bounces@lists.pjsip.org *On Behalf Of *Kjeld Flarup
Sent: Wednesday, May 13, 2020 2:08 PM
To: pjsip list pjsip@lists.pjsip.org
Subject: Re: [pjsip] PJSIP Client sending request on same connection

Hi Naveen

What load balancer are You using?

I would suggest using Kamailio, it is designed to do SIP load balancing.

Kjeld

Den ons. 13. maj 2020 kl. 08.13 skrev Naveen Shivanna <
naveen.shivanna@mitel.com>:

Hi All,

Could anyone reply to my query below.

Regards

Naveen.S

From: pjsip pjsip-bounces@lists.pjsip.org *On Behalf Of *Naveen
Shivanna
Sent: Friday, December 20, 2019 6:35 PM
To: pjsip@lists.pjsip.org
Subject: [pjsip] PJSIP Client sending request on same connection

Hi All,

Hoping for a solution. Your help will be appreciated.

Problem

PJsip client sends SIP requests on the same TCP connection

*Setup details *

I have pjsip client service which sends request to SIP servers on Google
Cloud Platform
(GCP) installed on same VPC.

In between these 2 components we are introducing "Internal TCP load
balancer
". Basically we wanted to load balance the TCP traffic(SIP
Messages) from pjsip client to different SIP Servers sitting behind the
load balancer as depicted in the diagram below.

Observation

Since the pjsip have single transport created and hence the request goes
on the same connection to Load Balancer ip-address. Load balancer balances
the traffic based on the rule “Client IP, Src port and protocol”.. Since
any request coming from PBX1 pjsip client will always be having same
ip-address and the connection is also same.. all the requests for going to
one SIP Server. Because of this we are not able to load balance the traffic
to other SIP Servers

Could any one suggest me how I can create different connections for each
SIP session created by same PBX pjsip client (PBX1).

Regards

Naveen.S

  • ________________________________  *

NOTE: This e-mail (including any attachments) is for the sole use of the
intended recipient(s) and may contain information that is confidential
and/or protected by legal privilege. Any unauthorized review, use, copy,
disclosure or distribution of this e-mail is strictly prohibited. If you
are not the intended recipient, please notify Mitel immediately and destroy
all copies of this e-mail. Mitel does not accept any liability for breach
of security, error or virus that may result from the transmission of this
message.


Visit our blog: http://blog.pjsip.org
https://can01.safelinks.protection.outlook.com/?url=http%3A%2F%2Fblog.pjsip.org%2F&data=02%7C01%7Cnaveen.shivanna%40mitel.com%7C890f77e9c0da4a657f5d08d7f71907de%7C4bff5a2bb30d493981ff8f76138347df%7C1%7C0%7C637249559201391605&sdata=6vVmzZtGpNwlHBtkJgiiIlwQ7zaTyWCqmhe3t2nKj%2Fc%3D&reserved=0

pjsip mailing list
pjsip@lists.pjsip.org
http://lists.pjsip.org/mailman/listinfo/pjsip_lists.pjsip.org
https://can01.safelinks.protection.outlook.com/?url=http%3A%2F%2Flists.pjsip.org%2Fmailman%2Flistinfo%2Fpjsip_lists.pjsip.org&data=02%7C01%7Cnaveen.shivanna%40mitel.com%7C890f77e9c0da4a657f5d08d7f71907de%7C4bff5a2bb30d493981ff8f76138347df%7C1%7C0%7C637249559201401600&sdata=hPE7RB9RYKKMXPNDgl4css224kcaLnQ4O5silxXeIdA%3D&reserved=0

--

--------------------- Med Liberalistiske Hilsner ----------------------

Civilingeniør, Kjeld Flarup - Mit sind er mere åbent end min tegnebog

Sofienlundvej 6B, 7560 Hjerm, Tlf: 40 29 41 49

Den ikke akademiske hjemmeside for liberalismen - www.liberalismen.dk <https://can01.safelinks.protection.outlook.com/?url=http%3A%2F%2Fwww.liberalismen.dk%2F&data=02%7C01%7Cnaveen.shivanna%40mitel.com%7C890f77e9c0da4a657f5d08d7f71907de%7C4bff5a2bb30d493981ff8f76138347df%7C1%7C0%7C637249559201401600&sdata=TtkHeeYFVY%2FbB8tBjB3ptfc%2B10TzUWdLQTC7%2Bay6nC8%3D&reserved=0>

Visit our blog: http://blog.pjsip.org

pjsip mailing list
pjsip@lists.pjsip.org
http://lists.pjsip.org/mailman/listinfo/pjsip_lists.pjsip.org

--

--------------------- Med Liberalistiske Hilsner ----------------------

Civilingeniør, Kjeld Flarup - Mit sind er mere åbent end min tegnebog
Sofienlundvej 6B, 7560 Hjerm, Tlf: 40 29 41 49
Den ikke akademiske hjemmeside for liberalismen - www.liberalismen.dk

I Think that it is wrong to fix this in the client. Somehow I think that You are lucky that a normal TCP load balancer works. Kjeld Den ons. 13. maj 2020 kl. 11.30 skrev Naveen Shivanna < naveen.shivanna@mitel.com>: > Hi Kjeld, > > > > > > We are using GCP Internal TCP load balancer. > > > > For SIP Client we are using PJSIP. > > > > Regards > > Naveen.S > > *From:* pjsip <pjsip-bounces@lists.pjsip.org> *On Behalf Of *Kjeld Flarup > *Sent:* Wednesday, May 13, 2020 2:08 PM > *To:* pjsip list <pjsip@lists.pjsip.org> > *Subject:* Re: [pjsip] PJSIP Client sending request on same connection > > > > Hi Naveen > > > > What load balancer are You using? > > I would suggest using Kamailio, it is designed to do SIP load balancing. > > > > Kjeld > > > > Den ons. 13. maj 2020 kl. 08.13 skrev Naveen Shivanna < > naveen.shivanna@mitel.com>: > > Hi All, > > > > Could anyone reply to my query below. > > > > Regards > > Naveen.S > > > > *From:* pjsip <pjsip-bounces@lists.pjsip.org> *On Behalf Of *Naveen > Shivanna > *Sent:* Friday, December 20, 2019 6:35 PM > *To:* pjsip@lists.pjsip.org > *Subject:* [pjsip] PJSIP Client sending request on same connection > > > > Hi All, > > > > Hoping for a solution. Your help will be appreciated. > > > > *Problem* > > > > PJsip client sends SIP requests on the same TCP connection > > > > *Setup details * > > > > I have pjsip client service which sends request to SIP servers on *Google > Cloud Platform* (GCP) installed on same VPC. > > In between these 2 components we are introducing "*Internal TCP load > balancer*". Basically we wanted to load balance the TCP traffic(SIP > Messages) from pjsip client to different SIP Servers sitting behind the > load balancer as depicted in the diagram below. > > > > > > *Observation* > > > > Since the pjsip have single transport created and hence the request goes > on the same connection to Load Balancer ip-address. Load balancer balances > the traffic based on the rule “Client IP, Src port and protocol”.. Since > any request coming from PBX1 pjsip client will always be having same > ip-address and the connection is also same.. all the requests for going to > one SIP Server. Because of this we are not able to load balance the traffic > to other SIP Servers > > > > Could any one suggest me how I can create different connections for each > SIP session created by same PBX pjsip client (PBX1). > > > > Regards > > Naveen.S > > > > > > * ________________________________ * > > NOTE: This e-mail (including any attachments) is for the sole use of the > intended recipient(s) and may contain information that is confidential > and/or protected by legal privilege. Any unauthorized review, use, copy, > disclosure or distribution of this e-mail is strictly prohibited. If you > are not the intended recipient, please notify Mitel immediately and destroy > all copies of this e-mail. Mitel does not accept any liability for breach > of security, error or virus that may result from the transmission of this > message. > > _______________________________________________ > Visit our blog: http://blog.pjsip.org > <https://can01.safelinks.protection.outlook.com/?url=http%3A%2F%2Fblog.pjsip.org%2F&data=02%7C01%7Cnaveen.shivanna%40mitel.com%7C890f77e9c0da4a657f5d08d7f71907de%7C4bff5a2bb30d493981ff8f76138347df%7C1%7C0%7C637249559201391605&sdata=6vVmzZtGpNwlHBtkJgiiIlwQ7zaTyWCqmhe3t2nKj%2Fc%3D&reserved=0> > > pjsip mailing list > pjsip@lists.pjsip.org > http://lists.pjsip.org/mailman/listinfo/pjsip_lists.pjsip.org > <https://can01.safelinks.protection.outlook.com/?url=http%3A%2F%2Flists.pjsip.org%2Fmailman%2Flistinfo%2Fpjsip_lists.pjsip.org&data=02%7C01%7Cnaveen.shivanna%40mitel.com%7C890f77e9c0da4a657f5d08d7f71907de%7C4bff5a2bb30d493981ff8f76138347df%7C1%7C0%7C637249559201401600&sdata=hPE7RB9RYKKMXPNDgl4css224kcaLnQ4O5silxXeIdA%3D&reserved=0> > > > > > -- > > --------------------- Med Liberalistiske Hilsner ---------------------- > > Civilingeniør, Kjeld Flarup - Mit sind er mere åbent end min tegnebog > > Sofienlundvej 6B, 7560 Hjerm, Tlf: 40 29 41 49 > > Den ikke akademiske hjemmeside for liberalismen - www.liberalismen.dk <https://can01.safelinks.protection.outlook.com/?url=http%3A%2F%2Fwww.liberalismen.dk%2F&data=02%7C01%7Cnaveen.shivanna%40mitel.com%7C890f77e9c0da4a657f5d08d7f71907de%7C4bff5a2bb30d493981ff8f76138347df%7C1%7C0%7C637249559201401600&sdata=TtkHeeYFVY%2FbB8tBjB3ptfc%2B10TzUWdLQTC7%2Bay6nC8%3D&reserved=0> > > > > _______________________________________________ > Visit our blog: http://blog.pjsip.org > > pjsip mailing list > pjsip@lists.pjsip.org > http://lists.pjsip.org/mailman/listinfo/pjsip_lists.pjsip.org > -- --------------------- Med Liberalistiske Hilsner ---------------------- Civilingeniør, Kjeld Flarup - Mit sind er mere åbent end min tegnebog Sofienlundvej 6B, 7560 Hjerm, Tlf: 40 29 41 49 Den ikke akademiske hjemmeside for liberalismen - www.liberalismen.dk