On Wed, Mar 29, 2017 at 09:57:02PM +0900, Tahiro Hashizume wrote:
B.)Kamailio listens on five IP addresses on dummyN which has 10.1.1.1N/32 (N=0-4, so dummy0 has 10.1.1.10/32, for example) making five SIP+RTP sessions to the same remote host to appear as if they are from five different hosts - so that a single instance of Asterisk running on debian may be registered (through Kamailio) on the same remote host by using five different accounts and source IP addresses.
...
Should be simple, but so far cannot find good sources of reference. I need your advice.
...
Snipping your long story, summarized to: sipserver only accepts 1 connection from 1 ipadress (which is kind of strange, have you tried 1 ipaddress and different source ports?) and you want to make multiple from 1 machine (with multiple ipadresses).
If my understanding is correct the solution is simple, in kamailio use force_send_socket to send requests to the sipserver from different adresses (10.1.1.1N).
The hard part is how you will differentiate the REGISTERS from asterisk to the sipserver. The easiest way I can think of right now is to listen on multiple ports with kamailio and tell the kamailio peers to connect to these in a unique way.
So in kamailio it would something like: if($Rp=="5070") { force_send_socket(10.0.1.10:5060); } else if($Rp=="5071") { force_send_socket(10.0.1.11:5060); } else if(...)
... route(RELAY);