[SR-Users] Kamailio routing incoming phone call ranges to different dispatch groups

Patrik Nilsson patrik.n at pm.me
Tue Aug 25 06:09:02 CEST 2020


Hi,

Although what I'm trying to achieve seems like an easy task, I have been tearing my hair for the past two days getting Kamailio to dispatch incoming phone calls to two different groups of Asterisk servers in my dispatcher list. I have 30 dedicated phone numbers from Telco: 020131600 - 020131629. I want 00-19 to be routed to Group 1, and 20-29 to be routed to Group 2, with a Round-robin algorithm. I'm aware that I can set up these incoming phone numbers in each Asterisk server's extension dial plans; nevertheless, I want Kamailio to do the initial incoming routing to a specific group (as Group 2, for instance, will never receive calls from for instance 02013161).

Example dispatcher.list:
#Company A (Group 1)
1 sip:10.50.0.1 0 0 maxload=20
1 sip:10.50.0.2 0 0 maxload=20
1 sip:10.50.0.3 0 0 maxload=20
#Company B (Group 2)
2 sip: 10.60.0.1 0 0 maxload=20
2 sip: 10.60.0.2 0 0 maxload=20
2 sip: 10.60.0.3 0 0 maxload=20

I assume this is done in the route[DISPATCH] of my kamailio.cfg, using ds_select_dst, but my previous attempts to get this routing to work just breaks the config file.

I appreciate any help that I can get!

Best regards,
Patrik
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.kamailio.org/pipermail/sr-users/attachments/20200825/43a56c6e/attachment.htm>


More information about the sr-users mailing list