Hi,
I searched around the web to load balance asterisk servers and found
Kamailio for possible solution. Let's say I have two identical asterisk
servers with same dialplan and configuration and I want both servers look
like they have same IP address from clients. Based on my understanding, we
need 1 Kamailio as load balancer and 2 Asterisk servers as the real servers.
Let's say the setup is :
Kamailio load balancer 192.168.2.1
Asterisk Server #1 192.168.2.2
Asterisk Server #2 192.168.2.3
My question is, X-Lite softphone Configuration should be set to domain
192.168.2.1, right?
I also want to know the step by step configuration to set kamailio as load
balancer. I have not used Kamailio before. However after searching the
documentation, the step (based on my understanding) is somewhat like this :
1. Install Kamailio. I will use the step by step here :
http://kamailio.org/dokuwiki/doku.php/install:kamailio-1.5.x-from-svn
2. Then, using dipatcher module, I will configure it using this guide here :
http://kamailio.org/dokuwiki/doku.php/asterisk:load-balancing-and-ha
Then modify the dispatcher.list file to match the IP address of my asterisk
servers :
*1 sip:192.168.2.2:5060
1 sip:192.168.2.3:5060*
Am I missing some steps?
Do I also need to configure dialplan or any other file at Kamailio load
balancer? Or those two steps basically done it all for simple load balancing
configuration? Thanks for your responses.
Best Regard,
Kurt Weasel.
here is correct reqwest and reqwest via kamailio
is there any way to rewrite To: field in kamailio
because now it nto work
correct reqwest(asterisk)
RECEIVING FROM: 69.70.173.195:5060
CANCEL sip:34249@193.110.78.12:8484 SIP/2.0
Via: SIP/2.0/UDP 192.168.1.180:5060;branch=z9hG4bK4c97bd4a
From: "Unknown"
<sip:Unknown@voip1.bravotelecom.com<sip%3AUnknown(a)voip1.bravotelecom.com>
>;tag=as366a0ba0
To: <sip:34249@193.110.78.12:8484>
Call-ID: 322db75c71be4ba45a61c7666b93e6be(a)voip1.bravotelecom.com
CSeq: 102 CANCEL
User-Agent: Asterisk PBX
Max-Forwards: 70
Content-Length: 0
incorrect reqwest(multi-homed kamailio, asterisk originate to internal eth)
RECEIVING FROM: 69.70.173.195:5060
CANCEL sip:34249@193.110.78.12:8484 SIP/2.0
Via: SIP/2.0/UDP 69.70.173.195;branch=z9hG4bK1b1b.3c42cea6.0
From: "Unknown" <sip:Unknown@69.70.173.195 <sip%3AUnknown(a)69.70.173.195>
>;tag=as6075df60
Call-ID: 4d784fa972c4e9c9795032417f46cb26(a)voip1.bravotelecom.com
To: <sip:34249@192.168.2.170 <sip%3A34249(a)192.168.2.170>>
CSeq: 102 CANCEL
Max-Forwards: 70
asterisk
Content-Length: 0
--
Merkulov Alexander
I just spend a lot of time to fix a trouble with Cisco AS5300 (AS5350)
BYE message disapearing.
The same not resolved case here:
http://lists.iptel.org/pipermail/serusers/2005-July/021698.html
The source of trouble was in the nat_uac_test parameter 16:
Here is the part of cisco log:
Jul 31 12:16:00.726 UKR: CCSIP-SPI-CONTROL:
act_idle_connection_created: Connid(1) created to 193.28.184.13:5060,
local_port 50058
--Skipped---
Jul 31 12:16:00.738 UKR: Sent:
INVITE sip:3039100@193.28.184.13:5060 SIP/2.0
Via: SIP/2.0/UDP 193.28.184.21:5060
From: <sip:2308228@193.28.184.21>;tag=12E601F8-10C7
To: <sip:3039100@193.28.184.13>
Via header the same in the all availible IOS-es.
As the result openser considerate the Cisco is out of the nat box.
The question is: Can someone show me the case when this parameter is
necessary, before I'll switch it of on the production server?
Thanks in advance.
Andrew O. Zhukov.
Hello
I need to get the value of a header using a dynamic variable. I have
the name of the header in an avp and I get the value using
$hdr($avp(s:headername))). This worked in kamailio 1.4.0, I am sure of
it because I tried it now on 1.4.0. But now in kamailio 1.5.1 I get an
error when trying to retrieve the value:
/usr/sbin/kamailio[32761]: ERROR:core:pv_get_spec_name: name type is
PV_NAME_OTHER - cannot resolve
/usr/sbin/kamailio[32761]: ERROR:pv:pv_get_hdr: invalid name
Does anybody have any idea what the problem might be?
Thanks
A brief look at the IPTel pages show pretty much nothing but comment
spam for pages and pages. Does anyone even bother to maintain the pages
anymore?
I'm looking for more relevant documentation to SER 2.0 (or even the SIP
Router project). The docs in the doc subtree of the source for both of
these projects is outdated and no longer valid with respect to any
information stored in the database.
It still references subscriber tables and the like. All 0.9.X format DB
data.
Is there an update somewhere?
N.
Hi!
I have problem compiling the OSP-module in Kamailio 1.5.x
OS: Ubuntu Server 8.04LTS
Compiling and installing OSPToolkit is OK.
The problem occures when it comes to compiling the OSP-module in Kamailio:
make[1]: Entering directory `/usr/src/kamailio/modules/osp'
make[1]: Leaving directory `/usr/src/kamailio/modules/osp'
make[1]: Entering directory `/usr/src/kamailio/modules/osp'
Compiling destination.c
Compiling globals.c
Compiling orig_transaction.c
In file included from orig_transaction.c:40:
sipheader.h:48: error: expected declaration specifiers or '...' before 'OSPTCALLID'
orig_transaction.c: In function 'ospLoadRoutes':
orig_transaction.c:84: error: 'OSPE_DEST_PROT' undeclared (first use in this function)
orig_transaction.c:84: error: (Each undeclared identifier is reported only once
orig_transaction.c:84: error: for each function it appears in.)
orig_transaction.c:84: error: expected ';' before 'protocol'
orig_transaction.c:85: error: 'OSPE_DEST_OSP_ENABLED' undeclared (first use in this function)
orig_transaction.c:85: error: expected ';' before 'enabled'
orig_transaction.c:150: error: 'protocol' undeclared (first use in this function)
orig_transaction.c:154: error: 'OSPE_DEST_PROT_SIP' undeclared (first use in this function)
orig_transaction.c:157: error: 'OSPE_DEST_PROT_H323_LRQ' undeclared (first use in this function)
orig_transaction.c:158: error: 'OSPE_DEST_PROT_H323_SETUP' undeclared (first use in this function)
orig_transaction.c:159: error: 'OSPE_DEST_PROT_IAX' undeclared (first use in this function)
orig_transaction.c:163: error: 'OSPE_DEST_PROT_UNDEFINED' undeclared (first use in this function)
orig_transaction.c:164: error: 'OSPE_DEST_PROT_UNKNOWN' undeclared (first use in this function)
orig_transaction.c:170: error: 'enabled' undeclared (first use in this function)
orig_transaction.c:174: error: 'OSPE_OSP_FALSE' undeclared (first use in this function)
orig_transaction.c:189: error: 'OSPC_SOURCE' undeclared (first use in this function)
orig_transaction.c: In function 'ospRequestRouting':
orig_transaction.c:260: error: 'OSPTCALLID' undeclared (first use in this function)
orig_transaction.c:260: error: 'callids' undeclared (first use in this function)
orig_transaction.c:282: error: too many arguments to function 'ospGetCallId'
orig_transaction.c:325: error: 'OSPC_E164' undeclared (first use in this function)
make[1]: *** [orig_transaction.o] Error 1
make[1]: Leaving directory `/usr/src/kamailio/modules/osp'
make: *** [modules] Error 2
Has tried with both OSPToolkit 3.5.2 and 3.3.6.
And with both Kamailio 1.5.1 and 1.5.2
Same problem.
Does anyone know what is the problem?
Regards,
Martin
Hi all
In kamailio 1.5.2, I used dlg_isflagset inside a ONREPLY_ROUTE.
////////////////scripts//////////////////
Route[1]{
...
Dlg_manage();
Dlg_setflag("1");
...
}
onreply_route[1] {
#dlg_get("$ci", "$ft", "$tt");
#xlog("L_INFO", " Dialog: $dlg(h_id) . $dlg(h_entry)\n");
if (dlg_isflagset("1")) {
xlog("L_INFO", " here is it \n");
}
}
/////////////////////////////////////////
The dlg_isflagset seems do not match anything until there is
dlg_get("$ci", "$ft", "$tt");
before it.
Questions are:
(1) Is it the correct usage or a pontential bug.
(2) How dialog is cheched/matched in the onreply_route internally?
Kind Regards
Min Wang
Hi all,
could you please give me suggestions how to simultaneously send call to
PSTN destination for UAC that is logged in. So, when call comes for
sip:bob@example.com it must also go to its PSTN destination
1234(a)10.0.0.2 (avp in mysql) and ring both destinations simultaneously.
Example below doesn't work and I keep ending up with two INVITEs to
PSTN GW and proxy doesn't fork call to UAC. in this case, if I understand
correctly, this is proper behavior because append_branch() has its function only if UAC
isn't logged in or on 480,486... And how to handle this when user is logged in?
if (!lookup("location")) {
...
}
if(...) {
avp_pushto("$ru", "$avp(s:PSTN_fwd)");
append_branch();
}
Thanks a lot
/dubravko
For those interested in building SIP and SIMPLE rich presence applications in
Ruby language:
http://xcapclient.rubyforge.org/http://dev.sipdoc.net/projects/ruby-xcapclient/wiki/
Ruby XCAPClient
--------------------------------------------------
A XCAP client library written in Ruby language.
XCAP (RFC 4825) is a protocol on top of HTTP which allows a client (usually a
VoIP/SIP device) to manipulate the contents of Presence Information Data
Format (PIDF) based presence documents. These documents are stored in a server
in XML format.
Ruby xcapclient library implements the XCAP protocol in client side, allowing
the applications to get, store, modify and delete XML documents in the server.
== Features
* Fetch, create/replace and delete a document.
* Fetch, create/replace and delete a document element (XML node).
* Fetch, create/replace and delete an element attribute.
* Full configurable parameters allowing customized fields for each XCAP
application, such auid, XML namespace, MIME-Type, scope (:user or :global) and
default document name ("index" if not set).
* Fetch the namespaces and prefixes of a document node as they are used in the
server.
* Manage of multiple documents per XCAP application.
* Fetch the XCAP server auids, extensions and namespaces ("xcap-caps"
application).
* SSL.
* Digest and Basic HTTP authentication.
* Raise custom Ruby exception for each HTTP error response.
--------------------------------------------------
Enjoy.
--
Iñaki Baz Castillo <ibc(a)aliax.net>
Hello,
some time ago I created a new branch in GIT named 'daniel/xavp' that
includes code for a new pseudo-variable class 'xavp' - name being a
shortcut to 'extended attribute value pair'. I collected some design
details in wiki:
http://sip-router.org/wiki/devel/xavp
It is not a replacement for current AVP api implementation, although in
the future can replace it. In the past we had couple of discussions
about the limitations of avps which I tried to overcome. Here are some
highlights of xavp design:
- string names only - various tests showed that having the complex
addressing scheme with integer id and string name does not pay off
performance gains. XAVP computes and integer id for each name that is
used to speed up comparison
- possibility to store more data types - AVP allow string and integer
data types. More can be handled by XAVP, including a generic data type
where you can build your own structure and store it in the list. This is
good for example to store custom structures for transaction lifetine --
right now dialog module needs to store reference to dialog structure.
Optimizations can be done for any case of serial forking -- uri, dst
uri, q, etc can be stored in a structure without a need to parse and
build it from an encoded value stored in one or many avps
- possibility to group XAVPs inside another XAVP - practically is
building lists of XAVPs. This should overcome issues with naming
conflicts between modules - e.g., dispatacher module can group its avps
in a list named "dispatacher", lcr module in a list named 'lcrl, then
there can be XAVP with name 'uri' in both lists, without the risk of
misusage. Another benefit would be reducing the number of parameters,
right now each module exports a parameter to set the name for each AVP,
with xavp there is need for one parameter to set the name of the list,
then inside that list the module is free to use predefined names without
the risk of overlapping.
- xavp having value integer or string can be used directly in config,
whether they are in a sublist or not
Check the wiki (link above) for more. Looking forward for comments,
suggestions and improvements.
Cheers,
Daniel
--
Daniel-Constantin Mierla
* SIP Router Bootcamp
* Kamailio (OpenSER) and Asterisk Training
* Berlin, Germany, Sep 1-4, 2009
* http://www.asipto.com/index.php/sip-router-bootcamp/