Re: [SR-Users] Authentication on Kamailio with MySQL

2017-04-10 Thread SamyGo
Maybe a restart on kamailio service wasn't done. Or maybe you're editing a
different config file while kamailio is using something else !
Otherwise I dont see anything missing.

--
Sammy


On Mon, Apr 10, 2017 at 4:08 PM, Nicolas Pace  wrote:

> Hi everyone,
>
> I'm having some trouble setting up a simple Kamailio installation with
> user authentication.
> I've installed a kamailio (4.3.4) base install on an ubuntu server
> 16.04 (x86/64) on virtualbox, and added this lines at the beginning of
> the file:
>
> ```
> #!KAMAILIO
>
> #! define WITH_MYSQL
> #! define WITH_AUTH
> #! define WITH_USRLOCDB
> ```
>
> Also configured the db name, host, user and pass for RO and RW and run
> `kamdbctl create`.
>
> Everything I do was following this tutorial:
> http://www.kamailio.org/wiki/tutorials/getting-started/main
>
>
> Based on what the tutorial says, I should have a server that only
> allows users that have been authenticated against the DB.
>
> The thing is that now Kamailio allows me to access, no matter what
> credentials I gave him (replies 200 OK to my REGISTER requests, and
> whows the user on the `kamctl monitor` view).
>
> I've added to this gist:
> * My current kamailio config
> * the kamailio grepped syslog
> * the pjsua output from when I register with an unexistent user
> https://gist.github.com/nicopace/9d44bf813fe309df69ff4cd0affe8324
>
> I've already checked out some of the wiki documentation, namely:
> * http://www.kamailio.org/wiki/tutorials/auth/auth_db
> * http://www.kamailio.org/wiki/tutorials/getting-started/main
>
> Am I missing something?
>
> Thanks
> ___
> SIP Express Router (SER) and Kamailio (OpenSER) - sr-users mailing list
> sr-users@lists.sip-router.org
> http://lists.sip-router.org/cgi-bin/mailman/listinfo/sr-users
>
>
___
SIP Express Router (SER) and Kamailio (OpenSER) - sr-users mailing list
sr-users@lists.sip-router.org
http://lists.sip-router.org/cgi-bin/mailman/listinfo/sr-users


Re: [SR-Users] Kamailio Registration load Issue

2017-03-28 Thread SamyGo
Hi,
Interesting to know that AWS has PPS limitation.

Found this article to be useful :
http://techblog.cloudperf.net/2016/05/2-million-packets-per-second-on-public.html

Regards,
Sammy


On Tue, Mar 28, 2017 at 3:37 AM, Daniel-Constantin Mierla  wrote:

> Hello,
>
> besides Alex' suggestion to look at AWS PPS limits, few things to take in
> consideration in such case:
>
>   - if CPU usage is low, then if you use DNS for routing, be sure that DNS
> server is very responsive
>   - if you do auth with database, be sure that database is very responsive
>   - if you print extensive log messages, be sure syslog is configured
> asynchronous
>   - check the received queue on sip port with netstat, if it is high
> value, then kamailio is stuck in some operations (like those above) and
> doesn't read as fast as the end point transmits
>   - if sipp runs on a low capacity system, I noticed that it cannot handle
> the responses at high throughput even when they are sent to it and it
> actually thinks it hasn't received them and do retransmissions
>
> Cheers,
> Daniel
>
> On 27/03/2017 21:09, Jade SZ wrote:
>
> Hi Guys,
>
> I am running a simple REGISTER load test on:
>
> 1) Kamailio sever with 2 cores - mem 5G
> 2) Kamailio server with 4 cores - mem 16G
>
> Both are EC2 instances.
>
> At -r = 500 i.e. 500 reg/sec sipP test works fine with very few re-trans.
> But when i increase it to 800 reg/sec it starts retransmissions in bulk.
>
> I don't see server's CPU, load-avg or memory shooting. Running everything
> by default, even using kamctl to start the instance. So I have not tuned
> any params yet.
>
> My main concern is how can I make server choke and get its actual
> capacity, and avoid these retransmissions as apparently kamailio is not
> even utilizing 2 cores and CPU usage is under 10 always.
>
> Results of both server is same i.e. 500 reg/sec max so I am sure there is
> some problem that needs a fix, but need some hints here.
>
> Also used multiple SIPp's to rule out if it is SIPp issue, but after 500 I
> see same problem.
>
>
> Regards,
> JSZ
>
>
>
> ___
> SIP Express Router (SER) and Kamailio (OpenSER) - sr-users mailing 
> listsr-us...@lists.sip-router.orghttp://lists.sip-router.org/cgi-bin/mailman/listinfo/sr-users
>
>
> --
> Daniel-Constantin Mierlawww.twitter.com/miconda -- www.linkedin.com/in/miconda
> Kamailio Advanced Training - May 22-24 (USA) - www.asipto.com
> Kamailio World Conference - May 8-10, 2017 - www.kamailioworld.com
>
>
> ___
> SIP Express Router (SER) and Kamailio (OpenSER) - sr-users mailing list
> sr-users@lists.sip-router.org
> http://lists.sip-router.org/cgi-bin/mailman/listinfo/sr-users
>
>
___
SIP Express Router (SER) and Kamailio (OpenSER) - sr-users mailing list
sr-users@lists.sip-router.org
http://lists.sip-router.org/cgi-bin/mailman/listinfo/sr-users


Re: [SR-Users] Kamailio Presence help required.

2017-03-08 Thread SamyGo
Hi Phil,
That did help improve the situation; but I've noticed that now when a phone
boots up and sends for SUBSCRIBE its gets a NOTIFY for the request with
state 'terminated' even if the other side is Online/Active.

Here is a sample of the Immediate NOTIFY:

To: <sip:1...@presence.voipguy.ca <sip%3a...@presence.voipguy.ca>
>;tag=2731947019
From: <sip:2...@presence.voipguy.ca <sip%3a...@presence.voipguy.ca>
>;tag=5d081ad8df67fd2b232f5240ec63c6ff-f422
CSeq: 2 NOTIFY
Call-ID: 0_1231439266@192.168.1.19
Content-Length: 267
User-Agent: kamailio (4.4.4 (x86_64/linux))
Max-Forwards: 70
Event: dialog
Contact: 
Subscription-State: active;expires=1800
Content-Type: application/dialog-info+xml



  
terminated
  


In above case the 201 device was Registered but its state is set as
terminated. Same signal goes for offline users as well. Is this a standard
reply or something is missing ?

Thanks for your time Phil.

Regards,
Sammy


On Tue, Mar 7, 2017 at 1:54 PM, Phil Lavin <phil.la...@cloudcall.com> wrote:

> Looks fairly sane. Try setting “pua” db_mode to 0. db_mode 2 takes a very
> different path through the code of the pua module and we have found it to
> be somewhat broken beyond repair. Our config is as follows. You may not
> have some of the stuff highlighted in yellow as I recently added those
> features to Kamailio. Depends which version you’re running. They’re not
> necessary for normal operation, however.
>
>
>
> modparam("presence", "db_url", DBURL)
>
> modparam("presence", "db_update_period", 20)
>
> modparam("presence", "clean_period", 60)
>
> modparam("presence", "local_log_facility", "LOG_LOCAL3")
>
> modparam("presence", "max_expires", 14430)
>
>
>
> modparam("presence_xml", "db_url", DBURL)
>
> modparam("presence_xml", "force_active", 1)
>
>
>
> modparam("pua", "db_url", DBURL)
>
> modparam("pua", "db_mode", 0) # Memory only. Required due to the "multiple
> states for a single dialog" bug
>
> modparam("pua", "update_period", 20)
>
> modparam("pua", "outbound_proxy", MY_SIP_URL)
>
>
>
> modparam("pua_dialoginfo", "send_publish_flag", FLT_DLGINFO)
>
> modparam("pua_dialoginfo", "override_lifetime", 14420)
>
> modparam("pua_dialoginfo", "callee_trying", 1)
>
> modparam("pua_dialoginfo", "disable_caller_publish_flag",
> FLT_DISABLE_CALLER_PUBLISH)
>
> modparam("pua_dialoginfo", "disable_callee_publish_flag",
> FLT_DISABLE_CALLEE_PUBLISH)
>
>
>
>
>
> *From:* sr-users [mailto:sr-users-boun...@lists.sip-router.org] *On
> Behalf Of *SamyGo
> *Sent:* 06 March 2017 22:51
> *To:* Kamailio (SER) - Users Mailing List <sr-users@lists.sip-router.org>
>
> *Subject:* Re: [SR-Users] Kamailio Presence help required.
>
>
>
>
>
> Phil, here are all the Presence related modules and their params.
>
> Igor, I go clearly understand that difference and I accept it. However, Im
> finding it difficult to digest that FreeSWITCH sends back initial NOTIFY
> and phone light works while Kamailio is unable to do the same.
>
>
>
>
>
> #!ifdef WITH_PRESENCE
>
> loadmodule "presence.so"
>
> loadmodule "presence_xml.so"
>
> loadmodule "presence_dialoginfo.so"
>
> loadmodule "presence_reginfo.so"
>
> loadmodule "pua.so"
>
> loadmodule "pua_dialoginfo.so"
>
> loadmodule "pua_reginfo.so"
>
> loadmodule "pua_usrloc.so"
>
> #!endif
>
>
>
>
>
> #!ifdef WITH_PRESENCE
>
> # - presence params -
>
> modparam("presence", "db_url", DBURL)
>
> modparam("presence", "server_address", "sip:ServerIP:5060" )
>
> modparam("presence", "send_fast_notify", 0)
>
> modparam("presence", "db_update_period", 20)
>
> modparam("presence", "clean_period", 40)
>
> modparam("presence", "subs_db_mode", 2)
>
> modparam("presence", "fetch_rows", 1000)
>
>
>
> # - presence_xml params -
>
> modparam("presence_xml", "db_url", DBURL)
>
> modparam("presence_xml", "force_active", 1)
>
> modparam("presence_xml", "force_dummy_presence", 1)
>
>
>
>
>
> # - presence_dialoginfo params -
>
&

Re: [SR-Users] Kamailio Presence help required.

2017-03-06 Thread SamyGo
Phil, here are all the Presence related modules and their params.

Igor, I go clearly understand that difference and I accept it. However, Im
finding it difficult to digest that FreeSWITCH sends back initial NOTIFY
and phone light works while Kamailio is unable to do the same.


#!ifdef WITH_PRESENCE
loadmodule "presence.so"
loadmodule "presence_xml.so"
loadmodule "presence_dialoginfo.so"
loadmodule "presence_reginfo.so"
loadmodule "pua.so"
loadmodule "pua_dialoginfo.so"
loadmodule "pua_reginfo.so"
loadmodule "pua_usrloc.so"
#!endif


#!ifdef WITH_PRESENCE
# - presence params -
modparam("presence", "db_url", DBURL)
modparam("presence", "server_address", "sip:ServerIP:5060" )
modparam("presence", "send_fast_notify", 0)
modparam("presence", "db_update_period", 20)
modparam("presence", "clean_period", 40)
modparam("presence", "subs_db_mode", 2)
modparam("presence", "fetch_rows", 1000)

# - presence_xml params -
modparam("presence_xml", "db_url", DBURL)
modparam("presence_xml", "force_active", 1)
modparam("presence_xml", "force_dummy_presence", 1)


# - presence_dialoginfo params -
modparam("presence_dialoginfo", "force_single_dialog", 1)
modparam("presence_dialoginfo", "force_dummy_dialog", 0)

# - pua params -
modparam("pua", "db_url", DBURL)
modparam("pua", "db_mode", 2)
modparam("pua", "update_period", 60)
modparam("pua", "dlginfo_increase_version", 0)
modparam("pua", "reginfo_increase_version", 0)
modparam("pua", "check_remote_contact", 1)
modparam("pua", "fetch_rows", 1000)

# - pua_dialoginfo params -
modparam("pua_dialoginfo", "include_callid", 1)
modparam("pua_dialoginfo", "send_publish_flag", FLT_DLGINFO)
modparam("pua_dialoginfo", "caller_confirmed", 0)
modparam("pua_dialoginfo", "include_tags", 1)
modparam("pua_dialoginfo", "override_lifetime", 124)

modparam("pua_reginfo|pua_usrloc", "default_domain", "voipguy.ca")
modparam("pua_reginfo", "server_address", "sip:REGINFO@ServerIP")
modparam("pua_usrloc", "branch_flag", FLT_DLGINFO)

#!endif


Thanks for helping me out on this.

Regards,
Sammy


On Mon, Mar 6, 2017 at 4:31 PM, Igor Olhovskiy <igorolhovs...@gmail.com>
wrote:

> Hi, Samy.
>
> Point, there is 2 modes of presence. Based on 'presence' and 'dialog'.
> Only 'presence' indicates states like online/offline, 'dialog' indicates
> only different call states, but also hold more info about a call. In
> 'dialog' case XML does not even has an option to indicate, that phone is
> online or offline.
>
> Refer to *https://tools.ietf.org/html/rfc3856*
> <https://tools.ietf.org/html/rfc3856> and
> *https://tools.ietf.org/html/rfc4235*
> <https://tools.ietf.org/html/rfc4235>
> So, when phone subscribes to 'dialog', according to rfc, they just want to
> know active states and not care about online/offline.
>
> Regards, Igor
>
> 6 марта 2017 г., 18:00 +0200, Phil Lavin <phil.la...@cloudcall.com>,
> писал:
>
> You should get an initial NOTIFY when you subscribe. Can you share the
> parts of your config that are relevant to presence/pua/etc.?
>
>
>
>
>
> *From:* sr-users [mailto:sr-users-boun...@lists.sip-router.org] *On
> Behalf Of* SamyGo
> *Sent:* 06 March 2017 15:50
> *To:* Daniel-Constantin Mierla <mico...@gmail.com>; Kamailio (SER) -
> Users Mailing List <sr-users@lists.sip-router.org>
> *Subject:* Re: [SR-Users] Kamailio Presence help required.
>
>
>
> Thanks Daniel for replying,
>
> Yes the BLF/Callstates are working fine. Problem arise when a phone
> reboots and initially has no Lights indication.
>
>
>
> These are the traces from a Working old-box(not-kamailio) - Kindly guide
> why my Kamailio is unable to send the "immediate NOTIFY" regarding the
> current state of the subscribed extension. If it can do that then I don't
> need to write anything.
>
>
>
>
>
>
>
> SUBSCRIBE sip:3...@presence.voipguy.ca SIP/2.0.
>
> Via: SIP/2.0/UDP 10.0.2.95:5060;branch=z9hG4bK-5ef31b0b.
>
> From: "299" <sip:2...@presence.voipguy.ca>;tag=40ab701f5717f5e9.
>
> To: <sip:3...@presence.voipguy.ca>.
>
> Call-ID: 7f166cd7-a89e6091@10.0.2.95.
>
> CSeq: 7888 SUBSCRIBE.
>
> Max

Re: [SR-Users] Kamailio Presence help required.

2017-03-06 Thread SamyGo
Thanks Daniel for replying,
Yes the BLF/Callstates are working fine. Problem arise when a phone reboots
and initially has no Lights indication.

These are the traces from a Working old-box(not-kamailio) - Kindly guide
why my Kamailio is unable to send the "immediate NOTIFY" regarding the
current state of the subscribed extension. If it can do that then I don't
need to write anything.



SUBSCRIBE sip:3...@presence.voipguy.ca SIP/2.0.
Via: SIP/2.0/UDP 10.0.2.95:5060;branch=z9hG4bK-5ef31b0b.
From: "299" <sip:2...@presence.voipguy.ca>;tag=40ab701f5717f5e9.
To: <sip:3...@presence.voipguy.ca>.
Call-ID: 7f166cd7-a89e6091@10.0.2.95.
CSeq: 7888 SUBSCRIBE.
Max-Forwards: 70.
Contact: "299" <sip:299@10.0.2.95:5060>.
Accept: application/dialog-info+xml.
Accept: application/x-broadworks-hoteling+xml.
Expires: 1800.
Event: dialog.
User-Agent: Cisco/SPA504G-7.5.6.
Content-Length: 0.
.


Server_IP:5060 -> Client_IP:1042

SIP/2.0 202 Accepted.
v:SIP/2.0/UDP 10.0.2.95:5060
;branch=z9hG4bK-5ef31b0b;received=Server_IP;rport=1042.
f:"299"<sip:2...@presence.voipguy.ca>;tag=40ab701f5717f5e9.
t:<sip:3...@presence.voipguy.ca>;tag=jYj0rSoBG7KA.
i:7f166cd7-a89e6091@10.0.2.95.
CSeq:7888 SUBSCRIBE.
m:<sip:314@Client_IP:5060>.
Expires:1800.
User-Agent:HV.
Allow:INVITE,ACK,BYE,CANCEL,OPTIONS,MESSAGE,INFO,UPDATE,REGISTER,REFER,NOTIFY,PUBLISH,SUBSCRIBE.
k:timer,path,replaces.
u:talk,hold,conference,presence,as-feature-event,dialog,line-seize,call-info,sla,include-session-description,presence.winfo,message-summary,refer.
Subscription-State:active;expires=1800.
l:0.
.


Server_IP:5060 -> Client_IP:1042

NOTIFY sip:299@10.0.2.95:5060 SIP/2.0.
v:SIP/2.0/UDP Client_IP;rport;branch=z9hG4bKUQ5v41FcK0Bvm.
Route:;transport=udp.
Max-Forwards:70.
f:<sip:3...@presence.voipguy.ca>;tag=jYj0rSoBG7KA.
t:"299"<sip:2...@presence.voipguy.ca>;tag=40ab701f5717f5e9.
i:7f166cd7-a89e6091@10.0.2.95.
CSeq:261575252 NOTIFY.
m:sip:314@Client_IP:5060.
User-Agent:HV.
Allow:INVITE,ACK,BYE,CANCEL,OPTIONS,MESSAGE,INFO,UPDATE,REGISTER,REFER,NOTIFY,PUBLISH,SUBSCRIBE.
k:timer,path,replaces.
o:dialog.
u:talk,hold,conference,presence,as-feature-event,dialog,line-seize,call-info,sla,include-session-description,presence.winfo,message-summary,refer.
Subscription-State:active;expires=1800.
c:application/dialog-info+xml.
l:166.
.





Client_IP:1042 -> Server_IP:5060

SIP/2.0 200 OK.
t:"299"<sip:2...@presence.voipguy.ca>;tag=40ab701f5717f5e9.
f:<sip:3...@presence.voipguy.ca>;tag=jYj0rSoBG7KA.
i:7f166cd7-a89e6091@10.0.2.95.
CSeq:261575252 NOTIFY.
v:SIP/2.0/UDP Client_IP;branch=z9hG4bKUQ5v41FcK0Bvm.
Server: Cisco/SPA504G-7.5.6.
Content-Length: 0.
.




Regards,
Sammy


On Mon, Mar 6, 2017 at 2:22 AM, Daniel-Constantin Mierla <mico...@gmail.com>
wrote:

> Hello,
>
> from your description, I don't see a problem from the specs point of view,
> but more like something that you would like to have.
>
> If UA subscribers only for dialog event, then it gets NOTIFY requests only
> for dialog states (new call, ..., termintated call). When it subscribers
> for presence, then it gets UA availability states.
>
> And I think this is what you also get based on description. Am I wright?
>
> Mixing the states of presence for dialog notifications is not possible,
> not in the specs, but eventually you can write a module yourself and map as
> you want/need presence states over dialog states.
>
> Cheers,
> Daniel
> On 03/03/2017 19:13, SamyGo wrote:
>
> Hi,
> I'm in need of making/tweak an existing Kamailio Presence setup which is
> giving some tough time.
>
> *Whats already working:*
> BLF dialog states changes are already sent across the users. SCA is
> working as well.
>
> *What isn't working:*
> When a User comes online then it sends SUBSCRIBE with *Event: dialog* and
> don't get notified of its subscribers state right then unless the monitored
> extensions make a call (BLF works)
>
>
>
> *Why is it not working: *
> As evident from wireshark traces, the user IP phones (Test sets: Polycoms,
> Yealink, CISCO, Grandstream) don't send our *Event: presence* rather only
> *Event:dialog* and Kamailio do not send NOTIFY out to everyone. Though
> yes there is an internally generated PUBLISH seen and handled properly upon
> registration state changes.
>
> Jitsi has been tested and Kamailio send out these registration state
> change info to jitsi, somce jitsi sends *Event:presence *in SUBSCRIBE.
>
> I need dialog based NOTIFY to be sent out on registration state-change.
>
> Need pointers and help on the topic, looking forward to some feedback.
>
> Regards,
> Sammy
>
>
> ___
> SIP Express Router (SER) and Kamailio (OpenSER) - sr-users mailing 
> listsr-us...@list

[SR-Users] Kamailio Presence help required.

2017-03-03 Thread SamyGo
Hi,
I'm in need of making/tweak an existing Kamailio Presence setup which is
giving some tough time.

*Whats already working:*
BLF dialog states changes are already sent across the users. SCA is working
as well.

*What isn't working:*
When a User comes online then it sends SUBSCRIBE with *Event: dialog* and
don't get notified of its subscribers state right then unless the monitored
extensions make a call (BLF works)



*Why is it not working:*
As evident from wireshark traces, the user IP phones (Test sets: Polycoms,
Yealink, CISCO, Grandstream) don't send our *Event: presence* rather only
*Event:dialog* and Kamailio do not send NOTIFY out to everyone. Though yes
there is an internally generated PUBLISH seen and handled properly upon
registration state changes.

Jitsi has been tested and Kamailio send out these registration state change
info to jitsi, somce jitsi sends *Event:presence *in SUBSCRIBE.

I need dialog based NOTIFY to be sent out on registration state-change.

Need pointers and help on the topic, looking forward to some feedback.

Regards,
Sammy
___
SIP Express Router (SER) and Kamailio (OpenSER) - sr-users mailing list
sr-users@lists.sip-router.org
http://lists.sip-router.org/cgi-bin/mailman/listinfo/sr-users


Re: [SR-Users] Kamailio LB: how to get Asterisk to do the RTP

2016-07-26 Thread SamyGo
Hi Again,

You need to enable NAT handling in your Kamailio (#!define WITH_NAT), then
depending upon how your clients will interact with asterisk you may or may
not need a media proxy, like RTPproxy. If asterisks can send/receive media
directly from the internet then its ok for now, else you definitely need to
have rtpproxy/rtpengine in there.


Regards,
Sammy


On Tue, Jul 26, 2016 at 10:29 PM, Tickling Contest <
tickling.cont...@gmail.com> wrote:

> With the help of members from this mailing list (many thanks!), I finally
> got Asterisk fronted by Kamailio for LB and REGISTERs and I am able to make
> a call using the setup that looks like this:
>
> [Kamailio 4.4.2]<->[Asterisk 13.7.2]
>
> Kamailio manages REGISTERs, but also forwarding them to Asterisk.
>
> I am able to make a call, but I get only one way audio or no audio
> depending on which client made the call (SipDroid->Zoiper I hear one way
> audio on Zoiper, but no audio if the call is made the other way). I noticed
> that Kamailio forced direct media between the endpoints in this situation,
> but my application really needs Asterisk to handle it.
>
> How do I do this? Should I start by forwarding INVITEs to Asterisk? How do
> I do that?
>
> Any help is appreciated.
>
> Thanks!
>
>
>
> ___
> SIP Express Router (SER) and Kamailio (OpenSER) - sr-users mailing list
> sr-users@lists.sip-router.org
> http://lists.sip-router.org/cgi-bin/mailman/listinfo/sr-users
>
>
___
SIP Express Router (SER) and Kamailio (OpenSER) - sr-users mailing list
sr-users@lists.sip-router.org
http://lists.sip-router.org/cgi-bin/mailman/listinfo/sr-users


Re: [SR-Users] How to forward REGISTERs to Asterisk in kamailio with dispatcher module with several Asterisk PBXs?

2016-07-24 Thread SamyGo
I asked for "kamctl dispatcher dump". 'show' only prints the table.

On Jul 24, 2016 18:38, "Tickling Contest" <tickling.cont...@gmail.com>
wrote:

> Thanks, Sammy. I fixed the error re: transport on Kamailio, but now
> nothing is sent as the dispatcher doesn't seem to work as expected by me.
> Here's the output you requested, any help is appreciated:
>
> root@kamailio:/etc/kamailio# kamctl dispatcher show
> dispatcher gateways
>
> ++---+--+---+--++-+
> | id | setid | destination  | flags | priority |
> attrs  | description |
>
> ++---+--+---+--++-+
> |  1 | 1 | sip:192.168.1.102:5060;transport=tcp | 0 |0 |
> weight=100 | Asterisk A  |
>
> ++---+--+---+--++-+
>
> root@kamailio:/etc/kamailio# netstat -pln | grep kamailio
> tcp0  0 0.0.0.0:50600.0.0.0:*
> LISTEN  4453/kamailio
> unix  2  [ ACC ] STREAM LISTENING 789407   4447/kamailio
> /tmp/kamailio_ctl
> root@opensipsA:/etc/kamailio#
>
>
> And on the Asterisk server:
>
> root@asterisk:~# netstat -pln | grep asterisk
> tcp0  0 0.0.0.0:50600.0.0.0:*
> LISTEN  2826/asterisk
> tcp0  0 0.0.0.0:20000.0.0.0:*
> LISTEN  2826/asterisk
> udp0  0 0.0.0.0:50000.0.0.0:*
>   2826/asterisk
> udp0  0 0.0.0.0:45200.0.0.0:*
>   2826/asterisk
> udp0  0 0.0.0.0:45690.0.0.0:*
>   2826/asterisk
> udp0  0 0.0.0.0:49207   0.0.0.0:*
>   2826/asterisk
> udp0  0 0.0.0.0:54857   0.0.0.0:*
>   2826/asterisk
> udp0  0 0.0.0.0:27270.0.0.0:*
>   2826/asterisk
> unix  2  [ ACC ] STREAM LISTENING 310872826/asterisk
> /var/run/asterisk/asterisk.ctl
>
>
> Now, the ds_select in the REGFWD does not seem to select anything (and so
> nothing is forwarded).
>
> My complete, current kamailio.cfg is here:
> https://gist.github.com/ticklingcontest/0b46e8e53bf50aa3875395c8fb86ff66
>
> BTW, I moved away from dispatcher.list file as I could not get it to work
> (the DB values always registered, but the list file didn't take).
>
> Any insight is appreciated.
>
> Thanks!
>
>
>
> On Sun, Jul 24, 2016 at 5:34 PM, SamyGo <govoi...@gmail.com> wrote:
>
>> Hey,
>> Can you show whats the output of the following commands on Kamailio
>> server:
>> "kamctl dispatcher dump"
>> "netstat -pln | grep kamailio"
>>
>> Send the output of the second command from asterisk server as well i.e
>> "netstat -pln | grep asterisk"
>>
>> Looking at the error it seems like you are trying to reach asterisk on a
>> protocol which kamailio is not listening on.
>>
>> Regards,
>> Sammy
>>
>> On Jul 24, 2016 14:38, "Tickling Contest" <tickling.cont...@gmail.com>
>> wrote:
>>
>>> Hey guys,
>>>
>>> I dug a little deeper and I found these logs in /var/log/kamailio where
>>> 192.168.1.102 is my asterisk server:
>>>
>>> ul 24 14:25:32 kamailio /usr/sbin/kamailio[3726]: ERROR: tm [ut.h:343]:
>>> uri2dst2(): no corresponding socket for af 2
>>> Jul 24 14:25:32 kamailio /usr/sbin/kamailio[3726]: ERROR: tm
>>> [uac.c:266]: t_uac_prepare(): t_uac: no socket found
>>> Jul 24 14:25:32 kamailio /usr/sbin/kamailio[3726]: ERROR: dispatcher
>>> [dispatch.c:2436]: ds_check_timer(): unable to ping [sip:
>>> 192.168.1.102:5060]
>>>
>>> I can broadly tell that the message was not even sent, but the asterisk
>>> server VM is alive and well (and indeed on the same physical machine as
>>> kamailio VM).
>>>
>>> What am I missing? Why is this failing? I am running kamailio 4.0.4.
>>>
>>> On Sat, Jul 23, 2016 at 8:07 PM, Tickling Contest <
>>> tickling.cont...@gmail.com> wrote:
>>>
>>>> I corrected an error with my dispatcher configuration and now, I do hit
>>>> the code where
>>>>
>>>> ds_select_dst ("1", "4")
>>>>
>>>> is no longer null.
>>>>
>>>> However, while the xlog I added says uac_req_send () is called, nothing
>>>> is sent. The xlog prints out the value of $uac_req(hdrs) as
&

Re: [SR-Users] How to forward REGISTERs to Asterisk in kamailio with dispatcher module with several Asterisk PBXs?

2016-07-24 Thread SamyGo
terisk box like so:
>>>
>>> root@asterisk:~# more /etc/asterisk/pjsip_wizard.conf
>>> [kamailio]
>>> type = wizard
>>> sends_auth = no
>>> sends_registrations = no
>>> remote_hosts = 192.168.1.101
>>> server_uri_pattern = sip:${REMOTE_HOST}\;transport=tcp
>>> client_uri_pattern = sip:${REMOTE_HOST}\;transport=tcp
>>> contact_pattern = sip:${REMOTE_HOST}\;transport=tcp
>>> outbound_auth/username = dispatcher
>>> aor/qualify_frequency = 0
>>> endpoint/context = from-external ;;; change later
>>> endpoint/disallow = all ;;; change later
>>> endpoint/allow = ulaw ;;; change later
>>> endpoint/dtmf_mode=rfc4733
>>> endpoint/media_address=192.168.1.101 ;;
>>> aor/qualify_frequency = 15
>>>
>>> BTW, my intention is to store the registrations on the Asterisk servers
>>> as well as my ARI code depends on it. As soon I get the single Asterisk
>>> situation working, I intend adding more servers to check the load balancing
>>> and REGISTER forwarding, and to Colin's point, the business of just using
>>> Kamailio as an outbound proxy.
>>>
>>> Again, any insight wrt why no REGISTERs are forwarding to Asterisk is
>>> appreciated. Why is ds_select_dst("1", "4") evaluating to false for me?
>>>
>>> My dispatcher info:
>>>
>>> root@kamailio:/etc/kamailio# kamctl dispatcher show
>>> dispatcher gateways
>>>
>>> ++---+---+---+--+---+-+
>>> | id | setid | destination   | flags | priority | attrs |
>>> description |
>>>
>>> ++---+---+---+--+---+-+
>>> |  1 | 1 | sip:192.168.1.102 | 1 |0 |   | AsteriskA
>>>   |
>>> |  2 | 1 | sip:192.168.1.102 | 1 |0 |   | AsteriskA
>>>   |
>>>
>>> ++---+---+---+--+---+-+
>>>
>>>
>>> Thanks!
>>>
>>> On Fri, Jul 22, 2016 at 11:01 AM, Colin Morelli <colin.more...@gmail.com
>>> > wrote:
>>>
>>>> If you're using Kamailio as a registrar, then it would make the most
>>>> sense to also use it as your outbound proxy for Asterisk.
>>>>
>>>> This would mean whenever Asterisk needs to dial an extension, it would
>>>> instead make a SIP call to your Kamailio instance which would then perform
>>>> the lookup, forking, and forwarding.
>>>>
>>>> Is there a reason this wouldn't work in your infrastructure? If for
>>>> some reason it can't - though I can't imagine how - then I don't see the
>>>> purpose in using Kamailio as a registrar at all. You should just forward
>>>> everything to Asterisk since it needs to be there anyway.
>>>>
>>>> Best,
>>>> Colin
>>>>
>>>> On Fri, Jul 22, 2016 at 9:58 AM SamyGo <govoi...@gmail.com> wrote:
>>>>
>>>>> Hi Tickles,
>>>>>
>>>>> a) Have you tried doing this on Asterisk realtime ? for any regular
>>>>> direct registering extension w/o kamailio(even before kamailio) ? If an
>>>>> extension registers to one asterisk the rest of the boxes would know where
>>>>> to contact this extension via realtime-db ? I'd say give that a try and it
>>>>> may solve your problem, else using this REGFWD block you can parallel fork
>>>>> this register request to ALL of your boxes and everybox would think it is
>>>>> registered locally ! (not a recommended option I must say)
>>>>>
>>>>> b) If you ignore my previous comment of parallel forking registers,
>>>>> using this  REGFWD block you can use dispatcher module to replace the
>>>>> $var(rip) and $sel(cfg_get.asterisk.bindport) by changing your REGFWD
>>>>> block like this:
>>>>>
>>>>> route[REGFWD] {
>>>>> if(!is_method("REGISTER"))
>>>>> {
>>>>> return;
>>>>> }
>>>>> if(!ds_select_dst("1", "4")){
>>>>>$var(rip) = $(du{s.select,1,:});
>>>>>$var(rport) = $(du{s.select,2,:});
>>>>>$uac_req(method)="REGISTER";
>>>>>$uac_req(ruri)="sip:" + $var(rip) 

Re: [SR-Users] kamailio starts looping invites(some) back to itself.

2016-07-22 Thread SamyGo
Hi Aqs,
How about putting a loop protection of some sort additionally like $si !=
myself.
Is there any chance the API http call is getting skipped to relay w/o
getting any reply back and hence looping back to itself ?

Regards,
Sammy

On Jul 22, 2016 14:17, "Aqs Younas"  wrote:

Hi,

I am using http_async_client and dispatcher modules of Kamailio.
Here is scenario!

http_async_client makes calls to an API to get groupid upon which
dispatcher sends calls.

I am using SIPp to generate calls with 100 cps. I see some calls being
failed with an error cause, 483 Too Many Hops.
Taking the trace shows Kamailio routing some calls to itself.

I think this is not a configuration issue since all calls are same(follow
same logic) and some calls get failed.

Any pointer is much appreciated.

Best Regards.




___
SIP Express Router (SER) and Kamailio (OpenSER) - sr-users mailing list
sr-users@lists.sip-router.org
http://lists.sip-router.org/cgi-bin/mailman/listinfo/sr-users
___
SIP Express Router (SER) and Kamailio (OpenSER) - sr-users mailing list
sr-users@lists.sip-router.org
http://lists.sip-router.org/cgi-bin/mailman/listinfo/sr-users


Re: [SR-Users] How to forward REGISTERs to Asterisk in kamailio with dispatcher module with several Asterisk PBXs?

2016-07-22 Thread SamyGo
Hi Tickles,

a) Have you tried doing this on Asterisk realtime ? for any regular direct
registering extension w/o kamailio(even before kamailio) ? If an extension
registers to one asterisk the rest of the boxes would know where to contact
this extension via realtime-db ? I'd say give that a try and it may solve
your problem, else using this REGFWD block you can parallel fork this
register request to ALL of your boxes and everybox would think it is
registered locally ! (not a recommended option I must say)

b) If you ignore my previous comment of parallel forking registers, using
this  REGFWD block you can use dispatcher module to replace the $var(rip)
and $sel(cfg_get.asterisk.bindport) by changing your REGFWD block like this:

route[REGFWD] {
if(!is_method("REGISTER"))
{
return;
}
if(!ds_select_dst("1", "4")){
   $var(rip) = $(du{s.select,1,:});
   $var(rport) = $(du{s.select,2,:});
   $uac_req(method)="REGISTER";
   $uac_req(ruri)="sip:" + $var(rip) + ":" + $var(rport) +
";transport=tcp";
   $uac_req(furi)="sip:" + $au + "@" + $var(rip);
   $uac_req(turi)="sip:" + $au + "@" + $var(rip);
   $uac_req(hdrs)="Contact: \r\n";
   if($sel(contact.expires) != $null)
$uac_req(hdrs)= $uac_req(hdrs) + "Expires: " +
$sel(contact.expires) + "\r\n";
else
$uac_req(hdrs)= $uac_req(hdrs) + "Expires: " +
$hdr(Expires) + "\r\n";
uac_req_send();
}

}


In summary, depending upon your business logic/use case there could be
other ways to make this work as well.

Regards,
Sammy


On Fri, Jul 22, 2016 at 8:53 AM, Tickling Contest <
tickling.cont...@gmail.com> wrote:

> Hello,
>
> When using Kamailio with the dispatcher module for Asterisk load
> balancing, I am offloading REGISTERs to Kamailio (works fine), but would
> like to forward the REGISTERs to Asterisk so that outgoing calls from
> Asterisk will be possible. I know this is not strictly necessary (e.g.,
> just use Kamailio to forward everything), but I have a lot of application
> logic behind my Asterisk boxes (using ARI) and so I don't want that to
> break. Thereby, I do need this information in Asterisk as soon as possible
> from Kamailio.
>
> Let's say I have three boxes Asterisk_1, Asterisk_2 and Asterisk_3 in the
> dispatcher module like so:
>
> 1 sip:192.168.1.201:5060;transport=tcp
> 1 sip:192.168.1.202:5060;transport=tcp
> 1 sip:192.168.1.203:5060;transport=tcp
>
> My system has endpoints as numerical extensions, from 101 to 110. When a
> new endpoint registers with kamailio (and authenticates), I would like to
> send the REGISTER to Asterisk. But I have the following questions:
>
> (a) Which Asterisk? I could send it to a round-robinned Asterisk (say,
> Asterisk_2), but that Asterisk may not be the one responsible for handling
> calls outbound for the endpoint that just registered. Even if I use "hash
> over auth username" instead of round-robin (In
> http://www.kamailio.org/docs/modules/4.0.x/modules/dispatcher.html#idp16940048,
> choose 5 for "alg", for example) that wont solve this problem as an
> outbound request may come from another Asterisk box which won't have the
> requisite registration information. Should I forward REGISTERs to all
> Asterisk boxes? Maybe I won't have to deal with this issue as I use
> realtime and so the REGISTER information, sent to one Asterisk box, is
> available to all Asterisk boxes after the write to the realtime DB. Is my
> understanding correct?
>
> (b) How do I do this in kamailio.cfg? With some examples on the Internet
> for WITH_ASTERISK directive, I see that you do
>
> route[REGFWD] {
> if(!is_method("REGISTER"))
> {
> return;
> }
> $var(rip) = $sel(cfg_get.asterisk.bindip);
> $uac_req(method)="REGISTER";
> $uac_req(ruri)="sip:" + $var(rip) + ":" +
> $sel(cfg_get.asterisk.bindport) + ";transport=tcp";
> $uac_req(furi)="sip:" + $au + "@" + $var(rip);
> $uac_req(turi)="sip:" + $au + "@" + $var(rip);
> $uac_req(hdrs)="Contact:  + $sel(cfg_get.kamailio.bindip)
> + ":" + $sel(cfg_get.kamailio.bindport) +
> ">\r\n";
> if($sel(contact.expires) != $null)
> $uac_req(hdrs)= $uac_req(hdrs) + "Expires: " +
> $sel(contact.expires) + "\r\n";
> else
> $uac_req(hdrs)= $uac_req(hdrs) + "Expires: " +
> $hdr(Expires) + "\r\n";
> uac_req_send();
> }
>
> What is the equivalent for when you are using the dispatcher module and
> the kamailio.bindip and asterisk.bindip etc. are not set in the
> configuration, but instead 

Re: [SR-Users] kamcmd & route[REMOTE_TEST]

2016-07-14 Thread SamyGo
Hi Marino,

How do you mean execute a route !? like enable a route for all calls
onwards after the RPC command execution ? or for a specific call engage
that route ?

If this is to enable/disable a particular route for ALL calls based on a
RPC command I'd make use of some DB or memcache variable to trigger this
route i.e

if(redis_cmd("srvN", "GET toggle_route", "r")){
  $avp(signal) =   $redis(r=>value);
  if($avp(signal) =~ 'true') {
   route(REMOTE_TEST);
  }
}

I used Redis, you can see if any RPC command can let you modify value of an
AVP directly.

For your second question check RPC commands uac.reg_refresh

.

Regards,
Sammy

On Thu, Jul 14, 2016 at 5:02 AM, Marino Mileti 
wrote:

> Hi guys,
>
>
>
> I've two question regarding rpc command.
>
>
>
> Is it possible to "execute" a specific route (for example my
> route[REMOTE_TEST]) using a rpc command by kamcmd?
>
>
>
> If not exist some other tricks to do this?
>
>
>
> Another question...regarding uac module...
>
> When Kamailio starts the UAC module makes a REGISTER according to
> database...and periodically refresh this registration. Is it possible to
> "force" a refresh with rpc command by kamcmd?
>
>
>
> Many thanks!
>
>
>
> *Marino Maria Mileti*
>
> *marino.mil...@alice.it *
>
>
>
> *[image: cid:006a01cb6b0e$67eecdae$_CDOSYS2.0]**Reduce your energy
> consumption and keep polar bears on ice!*
>
>
>
>
> --
> [image: Avast logo]
> 
>
> Questa e-mail è stata controllata per individuare virus con Avast
> antivirus.
> www.avast.com
> 
>
>
> ___
> SIP Express Router (SER) and Kamailio (OpenSER) - sr-users mailing list
> sr-users@lists.sip-router.org
> http://lists.sip-router.org/cgi-bin/mailman/listinfo/sr-users
>
>
___
SIP Express Router (SER) and Kamailio (OpenSER) - sr-users mailing list
sr-users@lists.sip-router.org
http://lists.sip-router.org/cgi-bin/mailman/listinfo/sr-users


Re: [SR-Users] Kamailio know which Interface Packet would route out

2016-07-13 Thread SamyGo
Thanks Loic,
Yes, thats correct Kernel decides the interface to take. That is why I want
to figure out if we have any way to foresee that decision !

I got to know a new thing: onsend_route:
http://www.kamailio.org/dokuwiki/doku.php/features:new-in-3.0.x#onsend_route

I will try and make use of this route and see if it helps me select the
rtp-proxy instance to use.

Here is how it looks like:
[image: Inline image 2]
For Inbound leg all is fine, but for outbound call leg, if I know which
Interface it is taking I can engage the rtpproxy instance for this.

Regards,
Sammy


On Wed, Jul 13, 2016 at 11:08 AM, Loic Chabert <chabert.loic...@gmail.com>
wrote:

> Hi,
> Interface selection is done by kernel when routing lookup is done, no ?
> If you have the same destination and multiple interface to reach it,
> kernel will chose the best one (according metric values).
>
> If you want to force trafic to go through an interface, interface must be
> attached to different routing table (rt_table), and with ip rule command,
> you can select  routing table for this packet (using packet marking).
>
> Another recent kernel feature is VRF:
> https://www.kernel.org/doc/Documentation/networking/vrf.txt
>
> Regards.
>
> Le 12 juil. 2016 19:45, "SamyGo" <govoi...@gmail.com> a écrit :
>
>> Hi,
>>
>> Question:
>> Is there a function in kamailio to get the interface/listen IP kamailio
>> would use to route a packet out for a domain / ip ?
>>
>> Example:
>>
>> $avp(interface_ip) = find_interface_for_request("192.168.12.123");
>>
>> And it gives me the Kamailio's Listen address that would be used for
>> sending call out to this IP/Domain !
>>
>> I've a weird situation where a multi-homed kamailio with about 7
>> different interfaces needs to send call out, I've so many RTProxy instances
>> to engage but I can't decide which instance to engage since I do not know
>> which Interface the Packet would route out from.
>>
>> Regards,
>> Sammy
>>
>>
>>
>> ___
>> SIP Express Router (SER) and Kamailio (OpenSER) - sr-users mailing list
>> sr-users@lists.sip-router.org
>> http://lists.sip-router.org/cgi-bin/mailman/listinfo/sr-users
>>
>>
> ___
> SIP Express Router (SER) and Kamailio (OpenSER) - sr-users mailing list
> sr-users@lists.sip-router.org
> http://lists.sip-router.org/cgi-bin/mailman/listinfo/sr-users
>
>
___
SIP Express Router (SER) and Kamailio (OpenSER) - sr-users mailing list
sr-users@lists.sip-router.org
http://lists.sip-router.org/cgi-bin/mailman/listinfo/sr-users


[SR-Users] Kamailio know which Interface Packet would route out

2016-07-12 Thread SamyGo
Hi,

Question:
Is there a function in kamailio to get the interface/listen IP kamailio
would use to route a packet out for a domain / ip ?

Example:

$avp(interface_ip) = find_interface_for_request("192.168.12.123");

And it gives me the Kamailio's Listen address that would be used for
sending call out to this IP/Domain !

I've a weird situation where a multi-homed kamailio with about 7 different
interfaces needs to send call out, I've so many RTProxy instances to engage
but I can't decide which instance to engage since I do not know which
Interface the Packet would route out from.

Regards,
Sammy
___
SIP Express Router (SER) and Kamailio (OpenSER) - sr-users mailing list
sr-users@lists.sip-router.org
http://lists.sip-router.org/cgi-bin/mailman/listinfo/sr-users


Re: [SR-Users] Parallel Forking with Different Call-Id

2016-07-06 Thread SamyGo
Thanks Daniel,
Both are  good ideas and I will try and see how it goes. I just wanted to
confirm that there is no way we can modify CallID of branches via script.
This is fine too.
Thanks again,

Best Regards,
Sammy
On Jul 6, 2016 06:11, "Daniel-Constantin Mierla" <mico...@gmail.com> wrote:

> Hello,
>
> maybe you can loop through a 2nd instance of kamailio (can be same server,
> different port) that has topoh enabled.
>
> Otherwise, if the gateway is matching on full r-uri, you can try to add
> some extra uri params, which are not relevant for target number.
>
> Cheers,
> Daniel
>
> On 05/07/16 21:54, SamyGo wrote:
>
> Hi,
>
> I've a very strange scenario to work on which requires me to parallel fork
> the call to the same Destination provider. The only problem here is that
> they think that the second INVITE with different branch tag is a
> re-transmission and hence only take one call forward.
>
> I do not have to modify any R-URI or any headers, hence just
> 'append_branch() before t_relay() is in the code.
>
> ...
> $ru = "sip:" + $rU + "@" + $avp(carrier_ip) + ":" + $avp(carrier_port);
> append_branch();
> route(RELAY);
> ...
>
> *Question:* Is there anyway possible I can change the CallID of the
> forked INVITEs ?
>
> I have tried using Topoh module, but it still puts the same CallID before
> sending out. Different from the A-leg but the Sent out INVITEs have same
> Call-ID value.
>
> In other weird scenario, I've also tried branching, and looping call
> within Kamailio before sending out to carrier hoping that Kamailio would
> treat the two different calls and Topoh would change the Call-ID on both
> INVITEs before sending out..
>
> ...
> if(is_present_hf("X-FORKED")) {
> $ru = "sip:" + $rU + "@" + $avp(carrier_ip) + ":" + $avp(carrier_port);
> route(RELAY);
> }else {
> append_hf("X-FORKED: 1\r\n");
> append_branch();
> route(RELAY);
> }
> ...
>
> Still I get same Call-ID on outgoing branched call.
>
> I could branch out one INVITE to a MediaServer, say FreeSWITCH/Asterisk
> but again I don't want to have that component bottleneck the throughput.
> That could be my very last option.
>
>
> Looking for some ideas.
>
> Regards,
> Sammy
>
>
>
> ___
> SIP Express Router (SER) and Kamailio (OpenSER) - sr-users mailing 
> listsr-us...@lists.sip-router.orghttp://lists.sip-router.org/cgi-bin/mailman/listinfo/sr-users
>
>
> --
> Daniel-Constantin Mierlahttp://www.asipto.com - 
> http://www.kamailio.orghttp://twitter.com/#!/miconda - 
> http://www.linkedin.com/in/miconda
>
>
> ___
> SIP Express Router (SER) and Kamailio (OpenSER) - sr-users mailing list
> sr-users@lists.sip-router.org
> http://lists.sip-router.org/cgi-bin/mailman/listinfo/sr-users
>
>
___
SIP Express Router (SER) and Kamailio (OpenSER) - sr-users mailing list
sr-users@lists.sip-router.org
http://lists.sip-router.org/cgi-bin/mailman/listinfo/sr-users


[SR-Users] Parallel Forking with Different Call-Id

2016-07-05 Thread SamyGo
Hi,

I've a very strange scenario to work on which requires me to parallel fork
the call to the same Destination provider. The only problem here is that
they think that the second INVITE with different branch tag is a
re-transmission and hence only take one call forward.

I do not have to modify any R-URI or any headers, hence just
'append_branch() before t_relay() is in the code.

...
$ru = "sip:" + $rU + "@" + $avp(carrier_ip) + ":" + $avp(carrier_port);
append_branch();
route(RELAY);
...

*Question:* Is there anyway possible I can change the CallID of the forked
INVITEs ?

I have tried using Topoh module, but it still puts the same CallID before
sending out. Different from the A-leg but the Sent out INVITEs have same
Call-ID value.

In other weird scenario, I've also tried branching, and looping call within
Kamailio before sending out to carrier hoping that Kamailio would treat the
two different calls and Topoh would change the Call-ID on both INVITEs
before sending out..

...
if(is_present_hf("X-FORKED")) {
$ru = "sip:" + $rU + "@" + $avp(carrier_ip) + ":" + $avp(carrier_port);
route(RELAY);
}else {
append_hf("X-FORKED: 1\r\n");
append_branch();
route(RELAY);
}
...

Still I get same Call-ID on outgoing branched call.

I could branch out one INVITE to a MediaServer, say FreeSWITCH/Asterisk but
again I don't want to have that component bottleneck the throughput. That
could be my very last option.


Looking for some ideas.

Regards,
Sammy
___
SIP Express Router (SER) and Kamailio (OpenSER) - sr-users mailing list
sr-users@lists.sip-router.org
http://lists.sip-router.org/cgi-bin/mailman/listinfo/sr-users


Re: [SR-Users] Distributed Authentication

2016-07-01 Thread SamyGo
Hi Collin,

I can only think that by doing this saving of nonce, and accessible by rest
of the boxes in cluster, isnt it going to put the authentication mechsnism
at risk ? Even if not, that means all the servers in your cluster supposed
to behave predictably same ! Hence again security concern !

Take a look at secret param for auth module:
http://www.kamailio.org/docs/modules/3.4.x/modules/auth.html

Regards,
Sammy
On Jul 1, 2016 18:10, "Colin Morelli"  wrote:

> Hey all,
>
> I'm running a cluster of Kamailio instances as a proxy/registrar for
> another cluster of Freeswitch instances. I'm using http_async_client to
> make HTTP queries to my API to fetch credentials on auth challenges.
> Kamailio performs generating the header, and validating the result based on
> the data provided from my API.
>
> I'm fairly sure the answer is no, but I was wondering if Kamailio has any
> mechanism for getting access to the nonce/nc values in the challenges and
> responses so I can store them somewhere accessible to the whole cluster.
> Because my instances are transaction stateful, the request that is
> challenged and the subsequent request with the response may be routed to
> different instances and I want to validate the nonce correctly.
>
> I can move all of this into the API (the digest auth and verification),
> but my next question would be whether or not there are any APIs for getting
> access to this information in a structured format, or if I should just
> shove the whole digest auth header in the request to my API and
> parse/verify there.
>
> Thanks in advance.
>
> Best,
> Colin
>
> ___
> SIP Express Router (SER) and Kamailio (OpenSER) - sr-users mailing list
> sr-users@lists.sip-router.org
> http://lists.sip-router.org/cgi-bin/mailman/listinfo/sr-users
>
>
___
SIP Express Router (SER) and Kamailio (OpenSER) - sr-users mailing list
sr-users@lists.sip-router.org
http://lists.sip-router.org/cgi-bin/mailman/listinfo/sr-users


Re: [SR-Users] kamailio & redis

2016-06-29 Thread SamyGo
Can you do the same with either reids on DB=1 or remove db=1 string from
the ndb_redis url.

redis-cli
127.0.0.1:6379> select 1
127.0.0.1:6379[1]> GHET usuario:2001 status

OR

*modparam("ndb_redis", "server", "name=srvN;addr=127.0.0.1;port=6379")*

If that doesn't help I'll be happy to share the relevant configs which I
assure you are the same.

Thanks,
Sammy



On Tue, Jun 28, 2016 at 9:33 AM, Fabian Pignataro <
fabian.pignatar...@gmail.com> wrote:

> Thanks Sammy !
>
> I tried that, but it's doesn't work.
> Here below, both options:
>
> *redis-cli*
> 127.0.0.1:6379> HGET usuario:2001 status
> "online"
>
> *kamailio.cfg*
> if(redis_cmd("srvN", "HGET usuario:2001 status", "res")) {
> xlog("L_INFO","array size: $redis(res=>size) - type:
> $redis(res=>type) - value: $redis(res=>value)\n");
> }
> *output /var/log/syslog*
> Jun 28 10:20:50 kamailio-fts /usr/sbin/kamailio[4665]: INFO: 

Re: [SR-Users] kamailio & redis

2016-06-28 Thread SamyGo
Hi,
I dont have my config at cell will share mine later. Meanwhile can you try
HGET only to pull that 1 value plus use
$redis(res=>value) with that.
Regards,
Sammy
On Jun 28, 2016 02:25, "Fabian Pignataro" 
wrote:

> Hello Community,
>
> I'm trying to read data (hash) stored in redis database, from kamailio
> script.
>
> I read the module documentation ndb_redis:
>
> http://www.kamailio.org/docs/modules/4.4.x/modules/ndb_redis.html#idp26300788
> But I'but I don't understand what I'm doing wrong :/
>
> With someone has had experience this?
>
> *My platform:*
>
> *root@kamailio-fts:~# cat /etc/issue*
> *Ubuntu 14.04.4 LTS \n \l*
>
> *root@kamailio-fts:~# kamailio  -V*
> *version: kamailio 4.4.1 (x86_64/linux) *
> *flags: STATS: Off, USE_TCP, USE_TLS, USE_SCTP, TLS_HOOKS, USE_RAW_SOCKS,
> DISABLE_NAGLE, USE_MCAST, DNS_IP_HACK, SHM_MEM, SHM_MMAP, PKG_MALLOC,
> Q_MALLOC, F_MALLOC, TLSF_MALLOC, DBG_SR_MEMORY, USE_FUTEX,
> FAST_LOCK-ADAPTIVE_WAIT, USE_DNS_CACHE, USE_DNS_FAILOVER, USE_NAPTR,
> USE_DST_BLACKLIST, HAVE_RESOLV_RES*
> *ADAPTIVE_WAIT_LOOPS=1024, MAX_RECV_BUFFER_SIZE 262144, MAX_LISTEN 16,
> MAX_URI_SIZE 1024, BUF_SIZE 65535, DEFAULT PKG_SIZE 8MB*
> *poll method support: poll, epoll_lt, epoll_et, sigio_rt, select.*
> *id: unknown *
> *compiled with gcc 4.8.2*
>
> *My script:*
>
> *modparam("ndb_redis", "server",
> "name=srvN;addr=127.0.0.1;port=6379;db=1")*
> *modparam("ndb_redis", "init_without_redis", 1)*
>
> *if(redis_cmd("srvN", "HMGET usuario:2002 status", "res")) {*
> *xlog("L_INFO","array size: $redis(res=>size) - type: $redis(res=>type) -
> value: $redis(res=>value[0]) $redis(res=>value[1]) \n"); *
> * }*
>
> *The output of syslog (I don't see errors): *
>
> *Jun 27 11:48:12 kamailio-fts /usr/sbin/kamailio[31615]: DEBUG: 
> [db_row.c:95]: db_free_row(): freeing row values at 0x7fc2fd008a30*
> *Jun 27 11:48:12 kamailio-fts /usr/sbin/kamailio[31615]: DEBUG: 
> [db_res.c:60]: db_free_rows(): freeing rows at 0x7fc2fd007020*
> *Jun 27 11:48:12 kamailio-fts /usr/sbin/kamailio[31615]: DEBUG: 
> [db_res.c:134]: db_free_result(): freeing result set at 0x7fc2fd008a98*
> *Jun 27 11:48:12 kamailio-fts /usr/sbin/kamailio[31615]: DEBUG:
> db_postgres [km_dbase.c:433]: db_postgres_free_query(): PQclear(0xcc9060)
> result set*
> *Jun 27 11:48:12 kamailio-fts /usr/sbin/kamailio[31615]: DEBUG: 
> [socket_info.c:564]: grep_sock_info(): checking if host==us: 13==13 &&
> [172.16.20.219] == [172.16.20.219]*
> *Jun 27 11:48:12 kamailio-fts /usr/sbin/kamailio[31615]: DEBUG: 
> [socket_info.c:567]: grep_sock_info(): checking if port 5060 (advertise 0)
> matches port 5060*
> *Jun 27 11:48:12 kamailio-fts /usr/sbin/kamailio[31615]: DEBUG: 
> [select.c:412]: run_select(): Calling SELECT 0x7fc2fcfc09a0*
> *Jun 27 11:48:12 kamailio-fts /usr/sbin/kamailio[31615]: DEBUG: registrar
> [lookup.c:240]: lookup_helper(): contact for [2004] found by address*
> *Jun 27 11:48:12 kamailio-fts /usr/sbin/kamailio[31615]: INFO: 

Re: [SR-Users] Equivalent of OpenSIP's binary interface in Kamailio

2016-06-20 Thread SamyGo
Hi,
What kind of design you've in mind when thinking about BIN interface ? What
are the things that you want to replicate ? Just call dialog states ?

Given some more usage clarification, someone might be able to guide further
on what can be used.

Regards,
Sammy



On Sat, Jun 18, 2016 at 2:15 AM, Gholamreza Sabery 
wrote:

> In OpenSIPS binary interface (
> https://www.opensips.org/Documentation/Interface-Binary-2-2) provides a
> more efficient way of replicating state between multiple OpenSIPs
> instances. What is the equivalent feature in Kamailio?
>
>
> Regards
>
> ___
> SIP Express Router (SER) and Kamailio (OpenSER) - sr-users mailing list
> sr-users@lists.sip-router.org
> http://lists.sip-router.org/cgi-bin/mailman/listinfo/sr-users
>
>
___
SIP Express Router (SER) and Kamailio (OpenSER) - sr-users mailing list
sr-users@lists.sip-router.org
http://lists.sip-router.org/cgi-bin/mailman/listinfo/sr-users


Re: [SR-Users] How to understad that user is de-registrating

2016-06-19 Thread SamyGo
Hi Alexandru,

The Expire header in Register can be your clue here. if it is greater than
0 means its a registration attempt. If the value is 0 then it is
un-register request.

This is how you can catch this.

if(is_method("REGISTER")  ) {
 if($hdr(Expire) == 0) {
 // Un-Registering User $fU
 } else {
 // Register request
 }
}

I'd say put it somewhere just before the save("lcoation"); line.

The event for contact-expired will work for a user when its expires timer
exceeds and there is no registration refresh from the device and hence
Kamailio removes the contact from usrloc records.


Regards,
Sammy





On Sun, Jun 19, 2016 at 1:41 PM, Alexandru Covalschi <568...@gmail.com>
wrote:

> Hello list,
>
> I need to send to an external API events when user is registrated and
> de-registrated.
> As far as I understand standart behaviour is as follows:
>
> If user is not registered, he sends REGISTER and he is registrated (I can
> catch that because I make the auth).
> If user is registered and sends REGISTER he is de-register.
> (Please correct me if I'm wrong.)
> How can I catch that?
> Can I use event_route[usrloc:contact-expired]?
>
> Thanks in advance!
>
> --
> Alexandru Covalschi
> ABRISS-Solutions
> VoIP engineer and system administrator
> tel: +37367398493
> web: http://abriss.solutions/ 
>
> ___
> SIP Express Router (SER) and Kamailio (OpenSER) - sr-users mailing list
> sr-users@lists.sip-router.org
> http://lists.sip-router.org/cgi-bin/mailman/listinfo/sr-users
>
>
___
SIP Express Router (SER) and Kamailio (OpenSER) - sr-users mailing list
sr-users@lists.sip-router.org
http://lists.sip-router.org/cgi-bin/mailman/listinfo/sr-users


Re: [SR-Users] High availability

2016-06-05 Thread SamyGo
Hi,
Since DBs for both are replicated and I assume user location table is
teplicated as well. In this case yes the secondary server will be able to
detect and find the called number as online.

The only exception would be the received socket. You might have to force
local socket to send INVITE to called number on each Kamailio.

Also for industrial scale designing you can use combination of DNS SRV,
keepalived or similar, and other techniques. One project that I am aware of
might come very Handy is SIPThor
http://ag-projects.com/sip-thor/

Regards,
Sammy
On Jun 5, 2016 20:21, "Fred Posner"  wrote:

> If it's just 2 servers, consider as Juha said, corosync/pacemaker with
> drbd.
>
> Fred Posner
> direct: +1 (224) 334-FRED (3733)
>
> On Jun 5, 2016, at 5:26 PM, Moacir Ferreira 
> wrote:
>
> Hi,
>
> Sorry... I should have mentioned before. You guys are thinking on the
> standard Internet SIP calls' behavior while I am trying to use Kamailio on
> a large "industrial" project. This said:
>
> Assuming that the end-point is "smart", the DNS method is functional but
> it would take quite a while before the UA (phone) recovers from the
> previous name/IP binding it has in cache;
> SRV is good for a "smart" UA that, unfortunately, is not the case;
> Same for the phone units as they are industrial "Help Points" and so quite
> "dummy".
>
> While I never tested it, I thought I could use two Kamailio servers with a
> mysql cluster like mariadb-galera where, for Kamailio functions, one server
> would be "active" and another "passive" server. Then use keepalived for
> monitoring the "active" Kamailio and starting the "passive" server if the
> active Kamailio fails. Without any testing, tests that I think I should
> have done before putting questions in here, my questions are:
>
> Suppose that  I have two Kamailio servers, one "active" and another one
> "passive" (not running) where the mysql databases are synchronized in
> between two servers using MySQL Galera. Using keepalived I would monitor
> the active Kamailio instance. Should it fails, start the "passive" Kamailio
> instance using the same MySQL database that were supposed to be
> synchronized. Would this new Kamailio instance be able to find a called
> number? Why this question? As long as I understand, Kamailio will always
> challenge the UA for authentication before making a call, so if this second
> server gets a call request it would just challenge and authenticate the
> caller. The "key point" would be having this new Kamailio instance aware
> about the called destinations. So, delivering a MySQL database, with the
> latest data the active Kamailio had, to this new Kamailio instance would be
> enough to allow it find the called party?
>
> Anyway, can you guys comment on my "thoughts"? Is it possible? Am I
> missing something? Would you suggest another approach for such scenario?
>
> Cheers!
> Moacir
>
> --
> Date: Sun, 5 Jun 2016 21:07:41 +0200
> From: chabert.loic...@gmail.com
> To: sr-users@lists.sip-router.org
> Subject: Re: [SR-Users] High availability
>
> Hello Bill,
>
> I have made kamailio ha using exabgp with loopbacks.
>
> Check https://github.com/Exa-Networks/exabgp
>
> With bgp, kamailio cluster can be splited on severals datacenters.
>
> Regards.
> Le 5 juin 2016 20:53, "Bill"  a écrit :
>
> Hi Moacir
>
> We have only found three ways to handle failover.
> 1. Change the DNS entry whenever a failure is detected.
> 2. Use SRV records to display an alternate route.
> 3. Use the failover mechanism in the phone itself
>
> 1. works, but it may take some time for your ua's to become aware of the
> change
> 2. never have been able to get this to work as advertised.
> 3. Works pretty well depending on the phone. (We use mostly Yealink's and
> they seem to handle the failover pretty well.)
>
> Hope this helps
>
> On 06/05/2016 07:41 AM, Moacir Ferreira wrote:
>
> Hi,
>
> I got two questions regarding high availability:
>
> 1 - Should my Kamailio server fail, I would like another Kamailio
> "box/server" to take over with minimum services disruption. What is the
> "community" advice for such environment?
>
> 2 - Should my main PSTN gateway fail, what would be the best mechanism to
> redirect calls to a second PSTN gateway?
>
> Cheers!
> Moacir
>
>
> ___
> SIP Express Router (SER) and Kamailio (OpenSER) - sr-users mailing 
> listsr-us...@lists.sip-router.orghttp://lists.sip-router.org/cgi-bin/mailman/listinfo/sr-users
>
>
>
> ___
> SIP Express Router (SER) and Kamailio (OpenSER) - sr-users mailing list
> sr-users@lists.sip-router.org
> http://lists.sip-router.org/cgi-bin/mailman/listinfo/sr-users
>
>
> ___ SIP Express Router (SER)
> and Kamailio (OpenSER) - sr-users mailing list
> sr-users@lists.sip-router.org
> 

Re: [SR-Users] Blacklists and DB_Cassandra

2016-05-13 Thread SamyGo
Thanks again, I guess its equally easy to use cassandra or redis for this,
and who knows this maybe a good experiment to test which one of the two
performs better and how to improve etc.

Best Regards,
Sammy


On Fri, May 13, 2016 at 2:07 AM, Daniel-Constantin Mierla <mico...@gmail.com
> wrote:

> Hello,
>
> redis is capable for sure of handling that size of records. If you just
> keep (key, value) pairs, redis is probably the best to choose because is
> know to be very fast for looking up on a key.
>
> Cheers,
> Daniel
>
> On 12/05/16 22:54, SamyGo wrote:
>
> Hi Daniel,
>
> I highly appreciate your share on this, I can make use of the
> ndb_cassandra too, or for the matter mongodb, or redis as well.
>
> May I ask how huge whitelists in redis is manageable, I'm looking for
> about 5~10 million records.
>
>
> Best Regards,
> Sammy
>
>
>
> On Thu, May 12, 2016 at 4:48 PM, Daniel-Constantin Mierla <
> <mico...@gmail.com>mico...@gmail.com> wrote:
>
>> Hello,
>>
>> the userblacklist module does caching in kamailio memory, so actually it
>> doesn't seem to help much the type of the backend (apart of data
>> distribution and loading from it).
>>
>> If you want to interact with cassandra records always, maybe
>> ndb_cassandra module can help -- iirc, it also uses newer versions of
>> cassandra libs that db_cassandra.
>> I don't have experience with cassandra at all, most of the deployments I
>> dealt with use redis for matching white/black listed numbers. Also mongdb
>> should have some operations allowing matching by key or prefix.
>>
>> Cheers,
>> Daniel
>>
>>
>> On 11/05/16 15:22, SamyGo wrote:
>>
>> Hi,
>>
>> I am tasked to make use of blacklist module for about 4 to 6 million
>> numbers. I am thinking of using Cassandra for the purpose but reading
>> through the documentatiom of module and recent mailing list discussion made
>> me a bit hesitant.
>>
>> I am looking for advise on this whether this is going to perform as
>> expected or is not even going to work with the BlackListing module !
>>
>> I am using Cassandra 33x and Kamailio 4.4 over Ubuntu 14.04.
>>
>> Looking for suggestions here.
>>
>> Regards,
>> Sammy
>>
>>
>> ___
>> SIP Express Router (SER) and Kamailio (OpenSER) - sr-users mailing 
>> listsr-us...@lists.sip-router.orghttp://lists.sip-router.org/cgi-bin/mailman/listinfo/sr-users
>>
>>
>> --
>> Daniel-Constantin Mierlahttp://www.asipto.comhttp://twitter.com/#!/miconda - 
>> http://www.linkedin.com/in/miconda
>> Kamailio World Conference, Berlin, May 18-20, 2016 - 
>> http://www.kamailioworld.com
>>
>>
>> ___
>> SIP Express Router (SER) and Kamailio (OpenSER) - sr-users mailing list
>> sr-users@lists.sip-router.org
>> http://lists.sip-router.org/cgi-bin/mailman/listinfo/sr-users
>>
>>
>
> --
> Daniel-Constantin Mierlahttp://www.asipto.comhttp://twitter.com/#!/miconda - 
> http://www.linkedin.com/in/miconda
> Kamailio World Conference, Berlin, May 18-20, 2016 - 
> http://www.kamailioworld.com
>
>
___
SIP Express Router (SER) and Kamailio (OpenSER) - sr-users mailing list
sr-users@lists.sip-router.org
http://lists.sip-router.org/cgi-bin/mailman/listinfo/sr-users


Re: [SR-Users] DB_Cassandra + UserBlacklist = ERROR

2016-05-12 Thread SamyGo
Hi again,

Yes read that thread from 1&1 guy as well. I believe yes I have thrift
0.6.1 -  Lets see of upgrading the thrift has any impact. I opened a bug
with github since the error seems to be coming from inside the
dbcassa_table.c file entirely irrelevant to the other libraries.


Regards,
Sammy






On Thu, May 12, 2016 at 4:41 PM, Daniel-Constantin Mierla <mico...@gmail.com
> wrote:

> Hello,
>
> perhaps someone needs to dive in the code of db_cassandra. Not long ago,
> there was a discussion saying that the module is using an old lib version
> and may not actually work. There were exposed plans to eventually update it.
>
> Are you using the old cassandra lib version?
>
> Cheers,
> Daniel
> On 12/05/16 18:17, SamyGo wrote:
>
> Hi List,
>
> I'm trying to hook up userblacklist module with db_cassandra. I've
> kamailio keyspace configured with tables for userblacklist ,
> globalblacklist, and version are created with some data in there.
>
> Here is setup info:
>
> version: kamailio 4.4.1
>
> *kamailio.cfg*
> ...
> loadmodule "db_cassandra.so"
> modparam("db_cassandra", "schema_path","/etc/kamailio/kamailio")
>
> loadmodule "userblacklist.so"
> modparam("userblacklist", "db_url", "cassandra://:@127.0.0.1:9160/kamailio
> ")
> modparam("userblacklist", "userblacklist_table", "userblacklist")
> modparam("userblacklist", "globalblacklist_table", "globalblacklist")
>
> *SCHEMA PATH:*
> root@whit-list:/etc/kamailio/kamailio# ls
> userblacklist  version
> root@whit-list:/etc/kamailio/kamailio# cat version/version
> table_name(string) table_version(int)
> table_name
>
> root@whit-list:/etc/kamailio/kamailio# cat userblacklist/userblacklist
> id(int) username(string) domain(string) prefix(string) whitelist(int)
> id username
>
> *CASSANDRA DB*
>
> root@whit-list:/etc/kamailio/kamailio# cqlsh
> Connected to Test Cluster at 127.0.0.1:9042.
> [cqlsh 5.0.1 | Cassandra 3.5 | CQL spec 3.4.0 | Native protocol v4]
> Use HELP for help.
> cqlsh> use kamailio
>... ;
> cqlsh:kamailio> describe tables;
>
> globalblacklist  version  userblacklist
>
> cqlsh:kamailio> select * from version;
>
>  table_name  | table_version
> -+---
>   uacreg | 2
>  version | 1
>  globalblacklist | 1
>userblacklist | 1
>
> (4 rows)
>
>
> Every time I start up Kamailio I see the following debug logs:
>
>  0(13877) DEBUG: db_cassandra [dbcassa_table.c:572]:
> dbcassa_read_table_schemas(): Full name= /etc/kamailio/kamailio/
>  0(13877) DEBUG: db_cassandra [dbcassa_table.c:589]:
> dbcassa_read_table_schemas(): Full dir name= /etc/kamailio/kamailio/version
>  0(13877) DEBUG: db_cassandra [dbcassa_table.c:609]:
> dbcassa_read_table_schemas(): Found database version
>  0(13877) DEBUG: db_cassandra [dbcassa_table.c:620]:
> dbcassa_read_table_schemas(): database table version
>  0(13877) DEBUG: db_cassandra [dbcassa_table.c:630]:
> dbcassa_read_table_schemas(): File path=
> /etc/kamailio/kamailio/version/version
>  0(13877) DEBUG: db_cassandra [dbcassa_table.c:200]: dbcassa_load_file():
> loading file [/etc/kamailio/kamailio/version/version]
>  0(13877) DEBUG: db_cassandra [dbcassa_table.c:122]: dbcassa_table_new():
> mtime is 1463068672
>  0(13877) DEBUG: db_cassandra [dbcassa_table.c:240]: dbcassa_load_file():
> new col [table_name]
>  0(13877) DEBUG: db_cassandra [dbcassa_table.c:253]: dbcassa_load_file():
> column[0] is STR!
>  0(13877) DEBUG: db_cassandra [dbcassa_table.c:283]: dbcassa_load_file():
> column[0] is actually STRING!
>  0(13877) DEBUG: db_cassandra [dbcassa_table.c:240]: dbcassa_load_file():
> new col [table_version]
>  0(13877) DEBUG: db_cassandra [dbcassa_table.c:253]: dbcassa_load_file():
> column[1] is STR!
>  0(13877) DEBUG: db_cassandra [dbcassa_table.c:283]: dbcassa_load_file():
> column[1] is actually STRING!
>  0(13877) DEBUG: db_cassandra [dbcassa_table.c:350]: dbcassa_load_file():
> col [table_name] in primary key
>  0(13877) DEBUG: db_cassandra [dbcassa_table.c:589]:
> dbcassa_read_table_schemas(): Full dir name=
> /etc/kamailio/kamailio/userblacklist
>  0(13877) DEBUG: db_cassandra [dbcassa_table.c:609]:
> dbcassa_read_table_schemas(): Found database userblacklist
>  0(13877) DEBUG: db_cassandra [dbcassa_table.c:620]:
> dbcassa_read_table_schemas(): database table userblacklist
>  0(13877) DEBUG: db_cassandra [dbcassa_table.c:630]:
> dbcassa_read_table_schemas(): File path=
> /etc/kamailio/kamailio/userblacklist/userblacklist
>  0(13877) 

Re: [SR-Users] Blacklists and DB_Cassandra

2016-05-12 Thread SamyGo
Hi Daniel,

I highly appreciate your share on this, I can make use of the ndb_cassandra
too, or for the matter mongodb, or redis as well.

May I ask how huge whitelists in redis is manageable, I'm looking for about
5~10 million records.


Best Regards,
Sammy



On Thu, May 12, 2016 at 4:48 PM, Daniel-Constantin Mierla <mico...@gmail.com
> wrote:

> Hello,
>
> the userblacklist module does caching in kamailio memory, so actually it
> doesn't seem to help much the type of the backend (apart of data
> distribution and loading from it).
>
> If you want to interact with cassandra records always, maybe ndb_cassandra
> module can help -- iirc, it also uses newer versions of cassandra libs that
> db_cassandra.
> I don't have experience with cassandra at all, most of the deployments I
> dealt with use redis for matching white/black listed numbers. Also mongdb
> should have some operations allowing matching by key or prefix.
>
> Cheers,
> Daniel
>
>
> On 11/05/16 15:22, SamyGo wrote:
>
> Hi,
>
> I am tasked to make use of blacklist module for about 4 to 6 million
> numbers. I am thinking of using Cassandra for the purpose but reading
> through the documentatiom of module and recent mailing list discussion made
> me a bit hesitant.
>
> I am looking for advise on this whether this is going to perform as
> expected or is not even going to work with the BlackListing module !
>
> I am using Cassandra 33x and Kamailio 4.4 over Ubuntu 14.04.
>
> Looking for suggestions here.
>
> Regards,
> Sammy
>
>
> ___
> SIP Express Router (SER) and Kamailio (OpenSER) - sr-users mailing 
> listsr-us...@lists.sip-router.orghttp://lists.sip-router.org/cgi-bin/mailman/listinfo/sr-users
>
>
> --
> Daniel-Constantin Mierlahttp://www.asipto.comhttp://twitter.com/#!/miconda - 
> http://www.linkedin.com/in/miconda
> Kamailio World Conference, Berlin, May 18-20, 2016 - 
> http://www.kamailioworld.com
>
>
> ___
> SIP Express Router (SER) and Kamailio (OpenSER) - sr-users mailing list
> sr-users@lists.sip-router.org
> http://lists.sip-router.org/cgi-bin/mailman/listinfo/sr-users
>
>
___
SIP Express Router (SER) and Kamailio (OpenSER) - sr-users mailing list
sr-users@lists.sip-router.org
http://lists.sip-router.org/cgi-bin/mailman/listinfo/sr-users


[SR-Users] DB_Cassandra + UserBlacklist = ERROR

2016-05-12 Thread SamyGo
Hi List,

I'm trying to hook up userblacklist module with db_cassandra. I've kamailio
keyspace configured with tables for userblacklist , globalblacklist, and
version are created with some data in there.

Here is setup info:

version: kamailio 4.4.1

*kamailio.cfg*
...
loadmodule "db_cassandra.so"
modparam("db_cassandra", "schema_path","/etc/kamailio/kamailio")

loadmodule "userblacklist.so"
modparam("userblacklist", "db_url", "cassandra://:@127.0.0.1:9160/kamailio")
modparam("userblacklist", "userblacklist_table", "userblacklist")
modparam("userblacklist", "globalblacklist_table", "globalblacklist")

*SCHEMA PATH:*
root@whit-list:/etc/kamailio/kamailio# ls
userblacklist  version
root@whit-list:/etc/kamailio/kamailio# cat version/version
table_name(string) table_version(int)
table_name

root@whit-list:/etc/kamailio/kamailio# cat userblacklist/userblacklist
id(int) username(string) domain(string) prefix(string) whitelist(int)
id username

*CASSANDRA DB*

root@whit-list:/etc/kamailio/kamailio# cqlsh
Connected to Test Cluster at 127.0.0.1:9042.
[cqlsh 5.0.1 | Cassandra 3.5 | CQL spec 3.4.0 | Native protocol v4]
Use HELP for help.
cqlsh> use kamailio
   ... ;
cqlsh:kamailio> describe tables;

globalblacklist  version  userblacklist

cqlsh:kamailio> select * from version;

 table_name  | table_version
-+---
  uacreg | 2
 version | 1
 globalblacklist | 1
   userblacklist | 1

(4 rows)


Every time I start up Kamailio I see the following debug logs:

 0(13877) DEBUG: db_cassandra [dbcassa_table.c:572]:
dbcassa_read_table_schemas(): Full name= /etc/kamailio/kamailio/
 0(13877) DEBUG: db_cassandra [dbcassa_table.c:589]:
dbcassa_read_table_schemas(): Full dir name= /etc/kamailio/kamailio/version
 0(13877) DEBUG: db_cassandra [dbcassa_table.c:609]:
dbcassa_read_table_schemas(): Found database version
 0(13877) DEBUG: db_cassandra [dbcassa_table.c:620]:
dbcassa_read_table_schemas(): database table version
 0(13877) DEBUG: db_cassandra [dbcassa_table.c:630]:
dbcassa_read_table_schemas(): File path=
/etc/kamailio/kamailio/version/version
 0(13877) DEBUG: db_cassandra [dbcassa_table.c:200]: dbcassa_load_file():
loading file [/etc/kamailio/kamailio/version/version]
 0(13877) DEBUG: db_cassandra [dbcassa_table.c:122]: dbcassa_table_new():
mtime is 1463068672
 0(13877) DEBUG: db_cassandra [dbcassa_table.c:240]: dbcassa_load_file():
new col [table_name]
 0(13877) DEBUG: db_cassandra [dbcassa_table.c:253]: dbcassa_load_file():
column[0] is STR!
 0(13877) DEBUG: db_cassandra [dbcassa_table.c:283]: dbcassa_load_file():
column[0] is actually STRING!
 0(13877) DEBUG: db_cassandra [dbcassa_table.c:240]: dbcassa_load_file():
new col [table_version]
 0(13877) DEBUG: db_cassandra [dbcassa_table.c:253]: dbcassa_load_file():
column[1] is STR!
 0(13877) DEBUG: db_cassandra [dbcassa_table.c:283]: dbcassa_load_file():
column[1] is actually STRING!
 0(13877) DEBUG: db_cassandra [dbcassa_table.c:350]: dbcassa_load_file():
col [table_name] in primary key
 0(13877) DEBUG: db_cassandra [dbcassa_table.c:589]:
dbcassa_read_table_schemas(): Full dir name=
/etc/kamailio/kamailio/userblacklist
 0(13877) DEBUG: db_cassandra [dbcassa_table.c:609]:
dbcassa_read_table_schemas(): Found database userblacklist
 0(13877) DEBUG: db_cassandra [dbcassa_table.c:620]:
dbcassa_read_table_schemas(): database table userblacklist
 0(13877) DEBUG: db_cassandra [dbcassa_table.c:630]:
dbcassa_read_table_schemas(): File path=
/etc/kamailio/kamailio/userblacklist/userblacklist
 0(13877) DEBUG: db_cassandra [dbcassa_table.c:200]: dbcassa_load_file():
loading file [/etc/kamailio/kamailio/userblacklist/userblacklist]
 0(13877) DEBUG: db_cassandra [dbcassa_table.c:122]: dbcassa_table_new():
mtime is 1462985556
 0(13877) DEBUG: db_cassandra [dbcassa_table.c:240]: dbcassa_load_file():
new col [id]
 0(13877) DEBUG: db_cassandra [dbcassa_table.c:258]: dbcassa_load_file():
column[0] is INT!
 0(13877) DEBUG: db_cassandra [dbcassa_table.c:240]: dbcassa_load_file():
new col [username]
 0(13877) DEBUG: db_cassandra [dbcassa_table.c:253]: dbcassa_load_file():
column[1] is STR!
 0(13877) DEBUG: db_cassandra [dbcassa_table.c:283]: dbcassa_load_file():
column[1] is actually STRING!
 0(13877) DEBUG: db_cassandra [dbcassa_table.c:240]: dbcassa_load_file():
new col [domain]
 0(13877) DEBUG: db_cassandra [dbcassa_table.c:253]: dbcassa_load_file():
column[2] is STR!
 0(13877) DEBUG: db_cassandra [dbcassa_table.c:283]: dbcassa_load_file():
column[2] is actually STRING!
 0(13877) DEBUG: db_cassandra [dbcassa_table.c:240]: dbcassa_load_file():
new col [prefix]
 0(13877) DEBUG: db_cassandra [dbcassa_table.c:253]: dbcassa_load_file():
column[3] is STR!
 0(13877) DEBUG: db_cassandra [dbcassa_table.c:283]: dbcassa_load_file():
column[3] is actually STRING!
 0(13877) DEBUG: db_cassandra [dbcassa_table.c:240]: dbcassa_load_file():
new col [whitelist]
 0(13877) DEBUG: db_cassandra [dbcassa_table.c:258]: 

[SR-Users] Blacklists and DB_Cassandra

2016-05-11 Thread SamyGo
Hi,

I am tasked to make use of blacklist module for about 4 to 6 million
numbers. I am thinking of using Cassandra for the purpose but reading
through the documentatiom of module and recent mailing list discussion made
me a bit hesitant.

I am looking for advise on this whether this is going to perform as
expected or is not even going to work with the BlackListing module !

I am using Cassandra 33x and Kamailio 4.4 over Ubuntu 14.04.

Looking for suggestions here.

Regards,
Sammy
___
SIP Express Router (SER) and Kamailio (OpenSER) - sr-users mailing list
sr-users@lists.sip-router.org
http://lists.sip-router.org/cgi-bin/mailman/listinfo/sr-users


Re: [SR-Users] How to run MySQL queries in Kamailio

2016-04-28 Thread SamyGo
Hi Fuad,
I think you should put the db return value in am avp before using it in the
sl_send_reply.
$avp(ip) = $avp(ra=>ip)
Or whatever the syntax is. Make sure that the DB query is returning the
required value.

Also I guess just using a 302 is not enough and you need to set the proper
contact header in the reply so the calling party make use of it.

Regards,
Sammy
On Apr 28, 2016 1:18 PM, "Ahmad Fuad"  wrote:

> Dear Support,
>
> Kindly find below my Database Table (kamailio.ext). Column names are "ext"
> and "ip"
>
> mysql> select * from ext
> -> ;
> +--++
> | ext  | ip |
> +--++
> |  202 | 192.168.55.157 |
> |  203 | 192.168.55.158 |
> |  204 | 192.168.55.159 |
> +--++
> 3 rows in set (0.00 sec)
>
> I want to run this type of queries in kamailio. I have tried following
> command but no luck so far. Although I have added following line in the
> configuration file as well. Thanks
>
> modparam("sqlops", "sqlcon", "cb=>mysql://root:123456@localhost/kamailio")
>
>
> sql_query("cb", "select ip from ext where ext=$rU", "ra");
> sl_send_reply("302","$ra");
>
>
> PLEASE HELP !!! when we see the traces using wireshark it shows internal
> error. Thanks
>
> 275.733635441 192.168.55.144 -> 192.168.55.157 SIP 431 Status: 302
> Internal Server Error |
>
> --
> Best Regards,
>
> Ahmad Fuad
>
> ___
> SIP Express Router (SER) and Kamailio (OpenSER) - sr-users mailing list
> sr-users@lists.sip-router.org
> http://lists.sip-router.org/cgi-bin/mailman/listinfo/sr-users
>
>
___
SIP Express Router (SER) and Kamailio (OpenSER) - sr-users mailing list
sr-users@lists.sip-router.org
http://lists.sip-router.org/cgi-bin/mailman/listinfo/sr-users


Re: [SR-Users] Kamailio as a presence server

2016-04-04 Thread SamyGo
Hi Igor,
If Im understanding this correctly you have a separate Kamailio just to
handle Presence.
In this case you mention that a SUBscribe has been acknowledged by this
Presence Kamailio but it does not do anything further!!
What are the chances that this new Presence kamailio is separate from the
main environment and probably has no dialog info in it and hence it is not
releasing any NOTIFY or PUBLishes?

Question: sharing a common database with dialog and registrations in their
tables...this new Presence kamailio is supposed to work as it is ? Right ?
Or does OP need to do some registrations and dialog replication via DMQ or
some other module?

Regards,
Sammy
On Apr 4, 2016 07:12, "Igor Olhovskiy"  wrote:

> Hi!
>
> Thanks, but actually with debug=3(4) in syslog last message I get is
> messages about hash tables in tm module.
>
> 2016-04-04 8:45 GMT+03:00 Daniel-Constantin Mierla :
>
>> Hello,
>>
>> can you run with debug=3 in config file and see if you get some hints
>> from syslog messages about what happens ?
>>
>> Cheers,
>> Daniel
>>
>>
>> On 01/04/16 17:17, Igor Olhovskiy wrote:
>>
>> Hi!
>> I want to create custom Presence server. Main idea - phones subscribes to
>> it (for ex, extension 100@domain). This subscription actually lit BLF
>> button on a phone.
>> But main idea - change status of BLF can arrive from different locations
>> via PUBLISH, I assume.
>> Problem - phones has different type of SUBSCRIBE, like
>> dialog(application/dialog-info+xml) or presence(application/pidf+xml). Some
>> of phones are not fully follow RFC (Like using in SUBSCRIBE R-URI not
>> domain, but IP, but in From or To - domains are used)
>> Phones are registered elsewhere, not on Kamailio. After reading RFC
>> (especially event:dialog part) I’ve found about SIP-If-Match part, but
>> problem about sync this data across multiple PUBLISH locations.
>> Can be Kamailio be a presence server in this scenario?
>>
>> For ex, SUBSCRIBE
>>
>> SUBSCRIBE sip:212.232.26.232:5060;transport=udp SIP/2.0
>> Via: SIP/2.0/UDP 192.168.88.60:5060;branch=z9hG4bK1656003104;rport
>> From: ;tag=521811605
>> To: ;tag=05ea6038656678bd0198b8977f3c0221.4e93
>> Call-ID: 805970257-506...@bjc.bgi.ii.ga
>> CSeq: 20202 SUBSCRIBE
>> Contact: 
>> X-Grandstream-PBX: true
>> Max-Forwards: 70
>> User-Agent: Grandstream GXP2160 1.0.5.33
>> Expires: 180
>> Supported: replaces, path, timer, eventlist
>> Event: dialog
>> Accept: application/dialog-info+xml,multipart/related,application/rlmi+xml
>> Allow: INVITE, ACK, OPTIONS, CANCEL, BYE, SUBSCRIBE, NOTIFY, INFO, REFER,
>> UPDATE, MESSAGE
>> Content-Length: 0
>>
>>
>> I’ve tried send to Kamailio this PUBLISH
>>
>> PUBLISH sip:*5...@master.rufan.at:5060 SIP/2.0
>> Via: SIP/2.0/UDP 10.0.20.71:5060;branch=z9hG4bK-6930-1-0
>> Max-Forwards: 70
>> To: 
>> From: ;tag=1
>> Call-ID: 1-6930@127.0.1.1
>> CSeq: 1 PUBLISH
>> Contact: 
>> Event: presence
>> Expires: 3600
>> Content-Type: application/pidf+xml
>> Content-Length:  486
>>
>> 
>> > xmlns:dm='urn:ietf:params:xml:ns:pidf:data-model'
>> xmlns:rpid='urn:ietf:params:xml:ns:pidf:rpid'
>> xmlns:c='urn:ietf:params:xml:ns:pidf:cipid' entity='sip:*
>> 5...@master.rufan.at'>
>> 
>> 
>> open
>> 
>> 
>> 
>> 
>> 
>> 
>> Night
>> 
>> 
>>
>> Kamailio answers with 200OK, but after this - no NOTIFY to subscribed
>> clients.
>>
>> --
>> Best regards,
>> Igor
>>
>>
>> ___
>> SIP Express Router (SER) and Kamailio (OpenSER) - sr-users mailing 
>> listsr-us...@lists.sip-router.orghttp://lists.sip-router.org/cgi-bin/mailman/listinfo/sr-users
>>
>>
>> --
>> Daniel-Constantin Mierlahttp://www.asipto.comhttp://twitter.com/#!/miconda - 
>> http://www.linkedin.com/in/miconda
>> Kamailio World Conference, Berlin, May 18-20, 2016 - 
>> http://www.kamailioworld.com
>>
>>
>> ___
>> SIP Express Router (SER) and Kamailio (OpenSER) - sr-users mailing list
>> sr-users@lists.sip-router.org
>> http://lists.sip-router.org/cgi-bin/mailman/listinfo/sr-users
>>
>>
>
>
> --
> Best regards,
> Igor
>
> ___
> SIP Express Router (SER) and Kamailio (OpenSER) - sr-users mailing list
> sr-users@lists.sip-router.org
> http://lists.sip-router.org/cgi-bin/mailman/listinfo/sr-users
>
>
___
SIP Express Router (SER) and Kamailio (OpenSER) - sr-users mailing list
sr-users@lists.sip-router.org
http://lists.sip-router.org/cgi-bin/mailman/listinfo/sr-users


Re: [SR-Users] Make Kamailio Great Again!

2016-04-01 Thread SamyGo
I just took a printout of it and will be framing it in my office. :D

My vote for Alex B.
On Apr 1, 2016 07:27, "Alex Balashov"  wrote:

> For immediate release:
>
> ATLANTA, GA (1 April 2016)--Alex J. Balashov, a self-styled
> businessman based in Atlanta, Georgia, USA, has a plan to "Make
> Kamailio Great Again".
>
> "Evariste Systems is huge. My name is on the building," said
> Balashov of his iconic VoIP consulting brand.
>
> "And you know what, I have been very successful. Everybody loves me."
>
> Balashov has capitalised on a contentious election cycle marked by
> deep political polarisation, growing income inequality and geopolitical
> challenges such as global terrorism. And his sharp message of alarm
> about the declining influence of the Kamailio SIP server project has
> resonated with increasing numbers in the CxO suite, vaulting him to
> the lead in the race for the IETF SIP Working Group nomination,
> according to recent polls of primary voters.
>
> He has been quick to tout his competitive credentials in a tough
> global open-source ecosystem. At a recent colloqium on unified
> communications, he asked:
>
> "When was the last time anybody saw us beating, let's say, OpenSIPS
> in Git commits? They kill us. I beat OpenSIPS all the time. All the
> time."
>
> As Balashov sees it, a major cause of the beleaguered Kamailio
> project's woes lies in its liberal patch acceptance policy and
> lax scrutiny of third-party contributions:
>
> "When GitHub sends its people, they're not sending their best.
> They're not sending you. They're not sending you. They're sending
> people that have lots of problems, and they're bringing those
> problems. They're bringing drugs. They're bringing crime. They're
> rapists. And some, I assume, are good people."
>
> He has proposed a controversial solution that has drawn ire from
> liberal ranks in the open-source community, but has also attracted
> applause and standing ovations at his speaking engagements:
>
> "We have to have a firewall around the Kamailio source code. We
> have to have an access control list. And in that firewall, we're
> going to have a big fat door where commits and pull requests can
> come into the master branch, but they have to come in legally.
> The firewall will go up, and GitHub will start behaving."
>
> Balashov's firewall proposal has been met with scorn from critics who
> deride it as impractical and quixotic. In particular, commentators
> have raised questions about funding and resources as well as GitHub's
> willingness to entertain a boundary around a project in its vicinity.
> Balashov isn't concerned, however:
>
> "I will build a great firewall--and nobody builds firewalls better
> than me, believe me--and I'll build them very inexpensively. I will
> build a great, great stateful packet inspection wall on our border
> with GitHub, and I will make GitHub pay for that wall. Mark my words."
>
> He has also been rebuked by rival IETF leadership candidates for his
> often acerbic Twitter remarks directed at Lennart Poettering and the
> developers of "firewalld". As he sees it, however, the network effects
> of social media are a strength:  "My Twitter has become so powerful
> that I can actually make my enemies tell the truth." He scoffed at
> the suggestion that his characterisations of industry actors behind
> the RedHat-led "systemd" movement are misleading:
>
> "RedHat was the worst Steward of Linux in the history of the kernel.
> There has never been a Steward so bad as RedHat. The source code
> blew up around us. We lost everything, including all synergies.
> There wasn't one good thing that came out of that administration or
> them being Stewards of Linux."
>
> Balashov's idiosyncratic campaign is not standing still. He has proven
> to be a capable populist, adapting rapidly to an evolving sense of the
> kinds of pronouncements that activate his swelling crowds of devotees.
> Along the way, he has deftly deflected calls to subject his policy
> proposals to expert review.
>
> "I know what I'm doing, and I listen to a lot of people, I talk to
> a lot of people, and at the appropriate time I'll tell you who
> the people are. But I speak to a lot of people, but my primary
> consultant is myself, and I have a good instinct for this stuff."
>
> At a recent gathering of SIP stack interoperability specialists,
> Balashov the latest pillar of his platform to "Make Kamailio Great
> Again", in view of growing security vulnerabilities in the latest
> Kamailio modules:
>
> "Alex J. Balashov is calling for a total and complete shutdown of
> commits entering the master branch from the territory of the European
> Union until our project's representatives can figure out what's going
> on. According to Netcraft, among others, there are a lot of buffer
> overflows in Kamailio by large segments of the EU population."
>
> ___
> SIP Express Router (SER) and Kamailio (OpenSER) - 

Re: [SR-Users] Kamailio PostgreSQL Asking Password Everytime

2016-03-26 Thread SamyGo
Yes

On Sat, Mar 26, 2016 at 2:47 AM, Barış Şekerciler <
baris.sekerci...@outlook.com> wrote:

> Hello Sammy,
> Thanks your for reply.
>
> I could not find the */root/.pgpass. *Both Kamailio and PGS server.
> Should I manually create it?
>
> Regards,
> Barış.
>
> --
> Date: Fri, 25 Mar 2016 12:00:35 -0400
> From: govoi...@gmail.com
> To: sr-users@lists.sip-router.org
>
> Subject: Re: [SR-Users] Kamailio PostgreSQL Asking Password Everytime
>
> Hi,
> I've experienced the same in past couple of weeks, apparently if you've
> the file */root/.pgpass* with the pgsql user/password in it something like
>
> *:*:*:kamailio:kamailiopass
>
> Then it should not ask you over and over again. I kept pasting password
> until it was done doing it's DB stuff, so I can only assume that it keeps
> asking for password for each new table/schema creation.
>
> Although not a big probelm but I too would like to get a fix for this
> situation.
>
> Regards,
> Sammy
>
>
>
>
> On Fri, Mar 25, 2016 at 9:47 AM, Barış Şekerciler <
> baris.sekerci...@outlook.com> wrote:
>
> Hello Daniel,
> Thanks for your reply.
>
> So I can't see any password for root user option in the kamctlrc file by
> default.
> How can I add?
>
> Regards.
> Barış.
>
> --
> To: sr-users@lists.sip-router.org
> From: mico...@gmail.com
> Date: Wed, 23 Mar 2016 08:26:58 +0100
> Subject: Re: [SR-Users] Kamailio PostgreSQL Asking Password Everytime
>
>
> Hello,
>
> I haven't used the postgres in a long while, but I think it should ask
> only once.
>
> Can you try by setting the password inside the kamctlrc file and see if
> works straight away?
>
> Cheers,
> Daniel
>
> On 22/03/16 11:52, Barış Şekerciler wrote:
>
> Hello,
> I have one postgres server at one server and Kamailio at another server.
> So I believe I did true configuration to the Kamailio. Actually I made
> some tests and I could create user and authenticated etc.
>
> But I have a problem. When I tried to present "kamdbctl create" Kamailio
> asks password 50 times (almost, much or less idk certainly).
> After 50 times Db created successfully and works.
>
> And it looks like this:
>
> root@bs-kamailio:/home/bs-kamailio# kamdbctl create
> INFO: creating database kamailio ...
> Password for user postgres:
> Password for user postgres:
> Password for user postgres:
> Password for user postgres:
> Password for user postgres:
> Password for user postgres:
> Password for user postgres:
> Password for user postgres:
> Password for user postgres:
> Password for user postgres:
> Password for user postgres:
> Password for user postgres:
> Password for user postgres:
> Password for user postgres:
> Password for user postgres:
> Password for user postgres:
> Password for user postgres:
>
>
> So how can I solve this situation? I want Kamailio to asks password one
> time and handle it's job.
>
>
> Regards.
>
>
>
>
> ___
> SIP Express Router (SER) and Kamailio (OpenSER) - sr-users mailing 
> listsr-us...@lists.sip-router.orghttp://lists.sip-router.org/cgi-bin/mailman/listinfo/sr-users
>
>
> --
> Daniel-Constantin Mierlahttp://www.asipto.comhttp://twitter.com/#!/miconda - 
> http://www.linkedin.com/in/miconda
> Kamailio World Conference, Berlin, May 18-20, 2016 - 
> http://www.kamailioworld.com
>
>
> ___ SIP Express Router (SER)
> and Kamailio (OpenSER) - sr-users mailing list
> sr-users@lists.sip-router.org
> http://lists.sip-router.org/cgi-bin/mailman/listinfo/sr-users
>
> ___
> SIP Express Router (SER) and Kamailio (OpenSER) - sr-users mailing list
> sr-users@lists.sip-router.org
> http://lists.sip-router.org/cgi-bin/mailman/listinfo/sr-users
>
>
>
> ___ SIP Express Router (SER)
> and Kamailio (OpenSER) - sr-users mailing list
> sr-users@lists.sip-router.org
> http://lists.sip-router.org/cgi-bin/mailman/listinfo/sr-users
>
> ___
> SIP Express Router (SER) and Kamailio (OpenSER) - sr-users mailing list
> sr-users@lists.sip-router.org
> http://lists.sip-router.org/cgi-bin/mailman/listinfo/sr-users
>
>
___
SIP Express Router (SER) and Kamailio (OpenSER) - sr-users mailing list
sr-users@lists.sip-router.org
http://lists.sip-router.org/cgi-bin/mailman/listinfo/sr-users


Re: [SR-Users] Kamailio PostgreSQL Asking Password Everytime

2016-03-25 Thread SamyGo
Hi,
I've experienced the same in past couple of weeks, apparently if you've the
file */root/.pgpass* with the pgsql user/password in it something like

*:*:*:kamailio:kamailiopass

Then it should not ask you over and over again. I kept pasting password
until it was done doing it's DB stuff, so I can only assume that it keeps
asking for password for each new table/schema creation.

Although not a big probelm but I too would like to get a fix for this
situation.

Regards,
Sammy




On Fri, Mar 25, 2016 at 9:47 AM, Barış Şekerciler <
baris.sekerci...@outlook.com> wrote:

> Hello Daniel,
> Thanks for your reply.
>
> So I can't see any password for root user option in the kamctlrc file by
> default.
> How can I add?
>
> Regards.
> Barış.
>
> --
> To: sr-users@lists.sip-router.org
> From: mico...@gmail.com
> Date: Wed, 23 Mar 2016 08:26:58 +0100
> Subject: Re: [SR-Users] Kamailio PostgreSQL Asking Password Everytime
>
>
> Hello,
>
> I haven't used the postgres in a long while, but I think it should ask
> only once.
>
> Can you try by setting the password inside the kamctlrc file and see if
> works straight away?
>
> Cheers,
> Daniel
>
> On 22/03/16 11:52, Barış Şekerciler wrote:
>
> Hello,
> I have one postgres server at one server and Kamailio at another server.
> So I believe I did true configuration to the Kamailio. Actually I made
> some tests and I could create user and authenticated etc.
>
> But I have a problem. When I tried to present "kamdbctl create" Kamailio
> asks password 50 times (almost, much or less idk certainly).
> After 50 times Db created successfully and works.
>
> And it looks like this:
>
> root@bs-kamailio:/home/bs-kamailio# kamdbctl create
>
> INFO: creating database kamailio ...
>
> Password for user postgres:
>
> Password for user postgres:
>
> Password for user postgres:
>
> Password for user postgres:
>
> Password for user postgres:
>
> Password for user postgres:
>
> Password for user postgres:
>
> Password for user postgres:
>
> Password for user postgres:
>
> Password for user postgres:
>
> Password for user postgres:
>
> Password for user postgres:
>
> Password for user postgres:
>
> Password for user postgres:
>
> Password for user postgres:
>
> Password for user postgres:
>
> Password for user postgres:
>
>
> So how can I solve this situation? I want Kamailio to asks password one
> time and handle it's job.
>
>
> Regards.
>
>
>
>
> ___
> SIP Express Router (SER) and Kamailio (OpenSER) - sr-users mailing 
> listsr-us...@lists.sip-router.orghttp://lists.sip-router.org/cgi-bin/mailman/listinfo/sr-users
>
>
> --
> Daniel-Constantin Mierlahttp://www.asipto.comhttp://twitter.com/#!/miconda - 
> http://www.linkedin.com/in/miconda
> Kamailio World Conference, Berlin, May 18-20, 2016 - 
> http://www.kamailioworld.com
>
>
> ___ SIP Express Router (SER)
> and Kamailio (OpenSER) - sr-users mailing list
> sr-users@lists.sip-router.org
> http://lists.sip-router.org/cgi-bin/mailman/listinfo/sr-users
>
> ___
> SIP Express Router (SER) and Kamailio (OpenSER) - sr-users mailing list
> sr-users@lists.sip-router.org
> http://lists.sip-router.org/cgi-bin/mailman/listinfo/sr-users
>
>
___
SIP Express Router (SER) and Kamailio (OpenSER) - sr-users mailing list
sr-users@lists.sip-router.org
http://lists.sip-router.org/cgi-bin/mailman/listinfo/sr-users


Re: [SR-Users] Dispatching Registrations to Weight based servers

2016-03-24 Thread SamyGo
Hi All,

I think I got the answer from reading the dispatcher.c source code:
https://github.com/kamailio/kamailio/blob/master/modules/dispatcher/dispatch.c
Line: 577

Says:


*/* if the array was not completely filled (i.e., the sum of weights is*
less than 100), then use last address to fill the rest */*
So clearly I was initializing two destinations with weight=20 and hence
code was doing what it is supposed to do, send everything to the last
address.

Now I've modified the two destinations weight = 50 and now REGISTRATIONS
get load-balanced as I desired.

Thing to remember for future reference, For algo 9 always sum up weights
for destinations to equal 100.


Thanks again for reading, and replying Brooks.

Regards,
Sammy






On Thu, Mar 24, 2016 at 2:08 PM, SamyGo <govoi...@gmail.com> wrote:

> Hi Brooks,
>
> Well no I'm using algo 9, with weights assigned to each IP in the set.
>
> The reason why I suspect that is because the load set and unset load
> related functions are mentioned to work only with INVITE.
> With the weights defined its only logical to assume that dispatcher will
> count the stuff thrown to a particular destination. Question is if Kamailio
> counts Registrations as stuff(*load*) or not..
>
> Now here is my dispatcher set
>
> SET:: 1
> URI:: sip:1.2.33.4:5060 flags=AP priority=1
> attrs=weight=10,registrations=500
> URI:: sip:2.3.4.9:5060 flags=AP priority=1
> attrs=weight=10,registrations=500
>
> Here is my code snippet where registrations are dispatched:
>
> if ( !ds_select_dst("1","9") ) {
>  send_reply("500","Service full");
>  exit;
> }
> xlog("L_NOTICE", "[$fU@$si:$sp]{$rm@$rU}  DISPATCHER: Selected PBX IP:$du
> Capacity Attr:$avp(pbx_attr) Total PBXs: $avp(dst_group) are
> $avp(dst_count)-\n");
>
>
> Thanks for taking out time to understand and reply.
>
> Regards,
> Sammy
>
>
>
> On Thu, Mar 24, 2016 at 1:31 PM, Brooks Bridges <bbrid...@o1.com> wrote:
>
>> Your reference to “dispatcher is not considering registrations as load at
>> all and only counts INVITES as load.” leads me to believe that you are
>> trying to use algorithm 10 since that’s the only mechanism that cares about
>> call loading.
>>
>>
>>
>> Working from that assumption, the documentation clearly states “This
>> algorithm can be used only for dispatching INVITE requests as it is the
>> only SIP method creating a SIP call.”
>>
>>
>>
>>
>> http://kamailio.org/docs/modules/stable/modules/dispatcher.html#dispatcher.f.ds_select_dst
>>
>>
>>
>> *Brooks Bridges | *Sr. Voice Services Engineer
>>
>> *O1 Communications*
>>
>> 5190 Golden Foothill Pkwy
>>
>> El Dorado Hills, CA 95762
>>
>> *office:* 916.235.2097 | *main:* 888.444., Option 2
>>
>> *email:* bbrid...@o1.com | *web:* www.o1.com
>>
>>
>>
>> *From:* sr-users [mailto:sr-users-boun...@lists.sip-router.org] *On
>> Behalf Of *SamyGo
>> *Sent:* Thursday, March 24, 2016 10:17 AM
>> *To:* SIP Router - Kamailio (OpenSER) and SIP Express Router (SER) -
>> Users Mailing List
>> *Subject:* [SR-Users] Dispatching Registrations to Weight based servers
>>
>>
>>
>> Hi All,
>>
>>
>>
>> I'm having a wee little bit of difficulty in trying to load-balance
>> registrations to multiple servers based on their weights.
>>
>>
>>
>> Kind of similar scenario as discussed in this thread:
>> http://lists.sip-router.org/pipermail/sr-users/2014-December/086235.html
>>
>> The problem I'm facing is that dispatcher is always choosing the first
>> destination from the group.
>>
>> I do suspect that dispatcher is not considering registrations as load at
>> all and only counts INVITES as load.
>>
>> If above is correct then is there a way to use dispatcher to count
>> registrations as load ?
>>
>>
>>
>> Thanks,
>>
>> Sammy
>>
>>
>>
>>
>>
>> ___
>> SIP Express Router (SER) and Kamailio (OpenSER) - sr-users mailing list
>> sr-users@lists.sip-router.org
>> http://lists.sip-router.org/cgi-bin/mailman/listinfo/sr-users
>>
>>
>
___
SIP Express Router (SER) and Kamailio (OpenSER) - sr-users mailing list
sr-users@lists.sip-router.org
http://lists.sip-router.org/cgi-bin/mailman/listinfo/sr-users


Re: [SR-Users] Dispatching Registrations to Weight based servers

2016-03-24 Thread SamyGo
Hi Brooks,

Well no I'm using algo 9, with weights assigned to each IP in the set.

The reason why I suspect that is because the load set and unset load
related functions are mentioned to work only with INVITE.
With the weights defined its only logical to assume that dispatcher will
count the stuff thrown to a particular destination. Question is if Kamailio
counts Registrations as stuff(*load*) or not..

Now here is my dispatcher set

SET:: 1
URI:: sip:1.2.33.4:5060 flags=AP priority=1
attrs=weight=10,registrations=500
URI:: sip:2.3.4.9:5060 flags=AP priority=1
attrs=weight=10,registrations=500

Here is my code snippet where registrations are dispatched:

if ( !ds_select_dst("1","9") ) {
 send_reply("500","Service full");
 exit;
}
xlog("L_NOTICE", "[$fU@$si:$sp]{$rm@$rU}  DISPATCHER: Selected PBX IP:$du
Capacity Attr:$avp(pbx_attr) Total PBXs: $avp(dst_group) are
$avp(dst_count)-\n");


Thanks for taking out time to understand and reply.

Regards,
Sammy



On Thu, Mar 24, 2016 at 1:31 PM, Brooks Bridges <bbrid...@o1.com> wrote:

> Your reference to “dispatcher is not considering registrations as load at
> all and only counts INVITES as load.” leads me to believe that you are
> trying to use algorithm 10 since that’s the only mechanism that cares about
> call loading.
>
>
>
> Working from that assumption, the documentation clearly states “This
> algorithm can be used only for dispatching INVITE requests as it is the
> only SIP method creating a SIP call.”
>
>
>
>
> http://kamailio.org/docs/modules/stable/modules/dispatcher.html#dispatcher.f.ds_select_dst
>
>
>
> *Brooks Bridges | *Sr. Voice Services Engineer
>
> *O1 Communications*
>
> 5190 Golden Foothill Pkwy
>
> El Dorado Hills, CA 95762
>
> *office:* 916.235.2097 | *main:* 888.444., Option 2
>
> *email:* bbrid...@o1.com | *web:* www.o1.com
>
>
>
> *From:* sr-users [mailto:sr-users-boun...@lists.sip-router.org] *On
> Behalf Of *SamyGo
> *Sent:* Thursday, March 24, 2016 10:17 AM
> *To:* SIP Router - Kamailio (OpenSER) and SIP Express Router (SER) -
> Users Mailing List
> *Subject:* [SR-Users] Dispatching Registrations to Weight based servers
>
>
>
> Hi All,
>
>
>
> I'm having a wee little bit of difficulty in trying to load-balance
> registrations to multiple servers based on their weights.
>
>
>
> Kind of similar scenario as discussed in this thread:
> http://lists.sip-router.org/pipermail/sr-users/2014-December/086235.html
>
> The problem I'm facing is that dispatcher is always choosing the first
> destination from the group.
>
> I do suspect that dispatcher is not considering registrations as load at
> all and only counts INVITES as load.
>
> If above is correct then is there a way to use dispatcher to count
> registrations as load ?
>
>
>
> Thanks,
>
> Sammy
>
>
>
>
>
> ___
> SIP Express Router (SER) and Kamailio (OpenSER) - sr-users mailing list
> sr-users@lists.sip-router.org
> http://lists.sip-router.org/cgi-bin/mailman/listinfo/sr-users
>
>
___
SIP Express Router (SER) and Kamailio (OpenSER) - sr-users mailing list
sr-users@lists.sip-router.org
http://lists.sip-router.org/cgi-bin/mailman/listinfo/sr-users


[SR-Users] Dispatching Registrations to Weight based servers

2016-03-24 Thread SamyGo
Hi All,

I'm having a wee little bit of difficulty in trying to load-balance
registrations to multiple servers based on their weights.

Kind of similar scenario as discussed in this thread:
http://lists.sip-router.org/pipermail/sr-users/2014-December/086235.html

The problem I'm facing is that dispatcher is always choosing the first
destination from the group.

I do suspect that dispatcher is not considering registrations as load at
all and only counts INVITES as load.

If above is correct then is there a way to use dispatcher to count
registrations as load ?

Thanks,
Sammy
___
SIP Express Router (SER) and Kamailio (OpenSER) - sr-users mailing list
sr-users@lists.sip-router.org
http://lists.sip-router.org/cgi-bin/mailman/listinfo/sr-users


Re: [SR-Users] What to read after RFC 3261 to get started with Kamailio.

2016-03-09 Thread SamyGo
Hi,
Well reading might be a very good idea but trying things and scenarios will
be an even better thing.
There are very amazing blogs, more like How to for kamailio written by
Daniel himself available over asipto knowledge base. Kb.asipto.com
Just go through those installation steps, copy over configurations add
users make calls, and at anytime you face any error check older emails of
users who face similar issues or ask mailing list right away.

Regards,
Sammy
On Mar 9, 2016 10:31, "Oivvio Polite"  wrote:

> I want to get started with Kamailio. So far I've understood that I
> really need to grok SIP before tackling Kamailio so I'm reading the book
> "SIP demystified" as the starting point of my Kamailio journey. After
> that I will read RFC 3261. After that I think it's time to read
> something that will give me good understanding of how to actually
> implement applications with Kamailio.  Searching Amazon for Kamailio
> returns "Building Telephony Systems with OpenSER" as the results that
> seems to be most specific to Kamailio. This book is from 2008. Is it
> still relevant or is it better to go with the online docs?
>
> regards, Oivvio
>
>
> ___
> SIP Express Router (SER) and Kamailio (OpenSER) - sr-users mailing list
> sr-users@lists.sip-router.org
> http://lists.sip-router.org/cgi-bin/mailman/listinfo/sr-users
>
___
SIP Express Router (SER) and Kamailio (OpenSER) - sr-users mailing list
sr-users@lists.sip-router.org
http://lists.sip-router.org/cgi-bin/mailman/listinfo/sr-users


Re: [SR-Users] How to comunicate two different server voip

2016-03-06 Thread SamyGo
Hello Dadang,

...inside route[LOCATION]

*Server1:*
if(!lookup("location") {
  xlog("Failed to Find user online in this server, maybe try Second
server\n")
  $ru = "sip:" + $rU + "@192.168.15.30";
  route(RELAY);
}


*Server2:*
if(!lookup("location") {
  xlog("Failed to Find user online in this server, maybe try First
server\n")
  $ru = "sip:" + $rU + "@192.168.10.57";
  route(RELAY);
}



For online users this will work as you require but may cause an infinite
loop between the servers if you try dialling a user which is offline.
Try adding SIP Headers and make sure you don't get into infinite loop
condition.



*Server1:*
if(!lookup("location") {
  xlog("Failed to Find user online in this server, maybe try Second
server\n")
  if(!is_present_hf("X-FROM-SERVER")) {
 append_hf("X-FROM-SERVER: 192.168.10.57\r\n");
 $ru = "sip:" + $rU + "@192.168.15.30";
 route(RELAY);
  }
}


*Server2:*
if(!lookup("location") {
  xlog("Failed to Find user online in this server, maybe try First
server\n")
  if(!is_present_hf("X-FROM-SERVER")) {
 append_hf("X-FROM-SERVER: 192.168.15.30\r\n");
 $ru = "sip:" + $rU + "@192.168.10.57";
 route(RELAY);
  }

}

I hope you understand the logic. Pretty easy isn't it ?

Regards,
Sammy

On Sat, Mar 5, 2016 at 4:45 AM, Raihan Satya 
wrote:

> Halo, my name dadang setiawan
>
> sample case
>
>  VOIP Server  A
> IP Address : 192.168.10.57
> voip number Jon 100
>
>
> Voip server B
> IP Address : 192.168.15.30
> voip number Brian  200
>
> i am using linphone video for comunication jon & brian
> the question is
>
> How to solution comunication jon with brian
> withhout  200@192.168.15.30
>
> but direct 200 without using @
>
>
>
>
> ___
> SIP Express Router (SER) and Kamailio (OpenSER) - sr-users mailing list
> sr-users@lists.sip-router.org
> http://lists.sip-router.org/cgi-bin/mailman/listinfo/sr-users
>
>
___
SIP Express Router (SER) and Kamailio (OpenSER) - sr-users mailing list
sr-users@lists.sip-router.org
http://lists.sip-router.org/cgi-bin/mailman/listinfo/sr-users


Re: [SR-Users] Fwd: [kamailio]: Querie on ratelimit module

2016-03-01 Thread SamyGo
Hi Prashant,
If I were to do it the lazy way and if I have understood your requirement
completely. I might've ended up using snmp monitoring of the CPU and set a
memcache/redis variable to be 0 or 1 in case CPU goes above or below 70.
In my kamailio.cfg I would just check that redis variable and decide
whether to drop requests or continue with the config.

Isn't that something that can help you ?

Thanks,
Sammy
On Mar 1, 2016 09:00, "Prashant Desai"  wrote:

>
> Hi Kamailio,
>
> We are using Kamailio V4.2.3 for our project and we are
> trying to address the performance requirement. We have following queries
>
> and need some inputs from Kamailio.
>
>
>
> *Requirement :* CPU Utilization Limit to 70%, If the limit is crossed
> Kamailio has to reject the Request.
>
> And If it is within the limit Kamailio has to Process the Requests. (i.e.
> Kamailio has to dynamically set and reset the policy based on CPU Load).
>
>
>
> *Our Findings* : We have come across ratelimit module in Kamailio, we
> tried using the same to address the requirement
>
> but we see it is not  dynamically setting and resetting the policy (once
> if it starts rejecting then every time it rejects it, only if we restart
> the kamailo it works)
>
>
>
> *What we Need*: We need to know
>
> 1.   Are we using the right module to address the above requirement ?
>
> 2.   We are only using ratelimit, module, do we have to include any
> other module along with ratelimit?
>
> 3.   We are using FEEDBACK algorithm, is that OK ?
>
> 4.   Setting  “ modparam("ratelimit", "pipe", "3:FEEDBACK:70") “ , is
> this correct ?
>
> 5.   In ratelimit.c , function
>
>  static int pipe_push(struct sip_msg * msg, int id) {
>
>   *case* *PIPE_ALGO_FEEDBACK*:
>
>  *LM_DBG(**"drop_rate
> [%d],hash[*pipes[id].counter][%d]\n"**,*drop_rate, hash[*pipes[id].*
> *counter**])*;
>
>  ret = (hash[*pipes[id].counter % 100] < *drop_rate)
> ? -1 : 1;
>
> }
>
> We are not able to understand the above line (
> hash[*pipes[id].counter % 100]). Could you please elaborate.
>
>
>
> 6.   Where are we lagging ?
>
>
>
>
>
> Regards,
>
> Prashanth
>
>
>
> --
>
> 
> Disclaimer: This message and the information contained herein is
> proprietary and confidential and subject to the Tech Mahindra policy
> statement, you may review the policy at
> http://www.techmahindra.com/Disclaimer.html externally
> http://tim.techmahindra.com/tim/disclaimer.html internally within
> TechMahindra.
>
> 
>
>
>
> ___
> SIP Express Router (SER) and Kamailio (OpenSER) - sr-users mailing list
> sr-users@lists.sip-router.org
> http://lists.sip-router.org/cgi-bin/mailman/listinfo/sr-users
>
>
___
SIP Express Router (SER) and Kamailio (OpenSER) - sr-users mailing list
sr-users@lists.sip-router.org
http://lists.sip-router.org/cgi-bin/mailman/listinfo/sr-users


Re: [SR-Users] Help

2016-02-28 Thread SamyGo
Hi,

I think the best guide closest to your description is here :
http://kb.asipto.com/asterisk:realtime:kamailio-4.0.x-asterisk-11.3.0-astdb

Here is what you need to do. (*Besides mentioning what you tried and what
problems were faced*).

1 - Configure kamailio to use the DB schema where your users are stored
with their password and PBX to use info.
2 - Point Phones to REGISTER to your kamailio.
3 - When a User makes a call execute query in Kamailio to find what client
this user belongs to  and what Asterisk it should be routed to.
4 - Send Calls to the selected Asterisk.

You can further add Memcache to save your DB query in step-3.

Good Part:
1 - Kamailio Authenticates all users and calls.
2 - One Public IP to point all domains/PBX tenants to.
3 - Use RTPproxy to bridge media to Asterisks and you can shift your
Asterisks on Private Subnet too.(depends on your design)
4 - Sending a hand crafted REGISTER to Asterisk makes asterisk aware of the
device state and hence BLF/MWI are handled by Asterisk.

Less Good Part: (As I see it)

Kamailio sends REGISTER packet to just one Asterisk ! thereby only one
server out of pool is aware of the device states. It can be resolved by
extra effort required as following:

  a) Yes we can use Dispatcher and send to failover/loadbalanced
asterisks in the pool
  b) A script of some sorts can be written and started in asterisk
servers to share device states/hints and \
  hence all asterisk servers in pool know whats going on. (I
haven't tried it myself)
  c) REGFWD route can be blocked and BLF, MWI are handled solely by
Kamailio.  (* I personally had rough time with this mostly due to different
standards *from IP Phones)

I'd love to hear other valuable suggestions and experiences.

Regards,
Sammy
Hello Kevin,
If I understood properly you want to build a system which authenticates
users and routes the Asterisk servers for communication.

First, Kamailio supports the routing, balancing and authentication. For
example we use Kamailio and Freeswitch. Here the how its work:
We have 1 Kamailio server that makes routes and balancing issues.
First client goes to our Kamailio servers:

*Client -> Internet -> Kamailio (authentication) (address, asked for
communication)*

After that, Kamailio looks the Freeswitch servers, which is free for
routing.

*  (sending)*
*Kamailio -> Freeswitch Server*
*  (user req)*

After routing proccess, Kamailio fade from the scene and clients start
communicate with themselves via Freeswitch servers.

BTW, our Freeswitch servers and Kamailio servers stay on different servers.
Of course you can serve on same server too.
If I understood properly, you can do it like this. If I did not, you can
give more details for understanding :)

Regards.

Barış.
--
From: kfpellet...@connextek.ca
To: sr-users@lists.sip-router.org; sr-...@lists.sip-router.org;
buisn...@lists.kamailio.org
Date: Fri, 26 Feb 2016 15:35:50 -0500
Subject: [SR-Users] Help

Hi,



I work for a VOIP service provider, and have been tasked with optimizing
our infrastructure.  We have been providing VOIP services to our clients
via Asterisk VM’s (PIAF) in an ESXi environment, hosted in a datacenter.
We are looking for some kind of SIP Router, which would authenticate
clients and route their SIP traffic to the appropriate server.  By doing
so, we are hoping to further secure our infrastructure and to possibly have
only one Public IP (which would resolve to the Private IP of the SIP
router).  The Asterisk servers serve
IVR/RINGGROUPS/OUTBOUNDTRUNKS/INBOUNDROUTES/OUTBOUNDROUTES.  The Sip Router
would therefore route all SIP traffic between the phones and the Asterisk
servers, ad the phones would register to the SIP Router.  I have tried many
solutions (Kamailio, OpenSER, siproxd, Brekeke), but have not been able to
configure these services to work the way we want them to.  I am including a
chart along with this email to outline what we would like to accomplish.



Any suggestions or guides would be immensely appreciated.



Thank you all for your time.









*Kevin Farrell Pelletier - Technicien informatique*





TI* //* Réseautique // Téléphonie IP *//* Programmation
IT // Networking // VoIP // Application development

9060, boul Parkway, Anjou, Québec, Canada H1J1N5
* Téléphone / Phone :* 514.907.2000 Ext.203
* F :* 1.888.582.4001  -  *SF/TF :* 1.855.907.2001* Web : *www.connextek.ca

* Pensez ENVIRONNEMENT, c'est important: n'imprimez que si nécessaire *
*Consider the ENVIRONMENT before printing*





___ SIP Express Router (SER)
and Kamailio (OpenSER) - sr-users mailing list sr-users@lists.sip-router.org
http://lists.sip-router.org/cgi-bin/mailman/listinfo/sr-users

___
SIP Express Router (SER) and Kamailio (OpenSER) - sr-users mailing list
sr-users@lists.sip-router.org

Re: [SR-Users] [TOPOH] Contact header for 302 Moved Temporarily

2016-02-17 Thread SamyGo
Hi Daniel,

There is nothing in $rU for this appearing in Kamailio. That is same
according to the Packet capture there is not $rU in my INVITE coming from
FS.

This is where in kamailio.cfg I'm getting a 484 Address Incomplete from
Kamailio back to FS.

   if (!is_method("REGISTER") && $rU==$null) {
# request with no Username in RURI
   sl_send_reply("484","Address Incomplete");
   exit;
   }

So Like I mentioned, if only the $rU part is maintained in the Contact
header by TOPOH this would start working as I've experimented by disabling
TOPOH and repeated the scenario and it worked.

Thanks for looking into this,
Regards,
Sammy


On Feb 17, 2016 08:31, "Igor Olhovskiy" <igorolhovs...@gmail.com> wrote:

> Just a quick question, if possible.
> I can’t get $ru in reply, cause in reply_route it gives me $ru from
> original INVITE. In OpenSIPS I’m using $(hdr(contact)), but how to
> do this on Kamailio?
> Anyway, contact Header from reply was got from tcpdump capture on Kamailio
> server.
>
> 2016-02-17 10:06 GMT+02:00 Daniel-Constantin Mierla <mico...@gmail.com>:
>
>> Hello,
>>
>> isn't the username then decoded from the value of
>>
>>
>> sip:TOPOH.KAMAILIO.IP;line=sr-N6IAzBy6WBy6MxFwW.qwPSW5ohWINhaYNLu4g9W4OhWI3wKLgRsIpUg5kGs7g9P-W.y6My**
>>
>> In other words, when the follow up invite in Kamailio comes, can you
>> print the value of $ru with xlog and see if it has username?
>>
>> Cheers,
>> Daniel
>>
>>
>> On 16/02/16 22:54, Igor Olhovskiy wrote:
>>
>> Yep, got same problem.
>> Not sure it’s a bug, but seems to be topoh module is really lack some
>> configuration.
>>
>> 2016-02-12 21:13 GMT+02:00 SamyGo <govoi...@gmail.com>:
>>
>>> Hi All,
>>> I've recently stumbled upon this little hitch while using kamailio with
>>> topoh module that the Contact header do not contains the User part for the
>>> 302 Moved temporarily packet.
>>>
>>> *My topology:*
>>> UserA<\
>>> ->Kamailio<===>FreeSwitch
>>> UserB</
>>>
>>> The B party has set Call forwarding on their phone hence phone sends a
>>> 302 Moved Temporarily to Kamailio.
>>>
>>>
>>> Via: SIP/2.0/UDP
>>> TOPOH.KAMAILIO.IP:5060;branch=z9hG4bK0767.4e4e57deca89da5c5f5ae97228325f85.0
>>> Via: SIP/2.0/UDP
>>> TOPOH.KAMAILIO.IP;branch=z9hG4bKsr-j4IPOlV7MGQKatycM.y7MGZLMGZwM.1LgRWIC9gIgx4fMGZAOBVAOBNfzuaVHRaYpB1LNSQLpx4uMx3Az6eL3RsBCxu-zRrUWSeOgjeBk.IVm4ds34aONc**
>>> From: "+4319714111" <sip:+4319714111
>>> @FREESWITCH.IP.HERE>;tag=yUr5UZ7eF794K
>>> To: <sip:5...@user.b.ip.here:5060>;tag=105223296
>>> Call-ID: cd811276-4b4d-1234-66ae-005056867dbc
>>> CSeq: 87257355 INVITE
>>> Contact: <sip:06606017...@freeswitch.ip.here:5060>
>>> User-Agent: Yealink SIP-T46G 28.80.0.70
>>> Diversion: <sip:5...@user.b.ip.here:5060>;reason=unconditional
>>> Content-Length: 0
>>>
>>> This is modified in Kamailio TOPOH and sent to FreeSwitch as following
>>>
>>>
>>> SIP/2.0 302 Moved Temporarily
>>> Via: SIP/2.0/UDP
>>> 10.0.20.71;received=10.0.20.71;rport=5060;branch=z9hG4bKeBcy9HKK9cDKr
>>> From: "+4319714111" <sip:+4319714111
>>> @FREESWITCH.IP.HERE>;tag=yUr5UZ7eF794K
>>> To: <sip:5...@user.b.ip.here:5060>;tag=105223296
>>> Call-ID: cd811276-4b4d-1234-66ae-005056867dbc
>>> CSeq: 87257355 INVITE
>>> Contact: <*sip:TOPOH.KAMAILIO.IP*
>>> ;line=sr-N6IAzBy6WBy6MxFwW.qwPSW5ohWINhaYNLu4g9W4OhWI3wKLgRsIpUg5kGs7g9P-W.y6My**>
>>> User-Agent: Yealink SIP-T46G 28.80.0.70
>>> Diversion: <sip:5...@user.b.ip.here:5060>;reason=unconditional
>>> Content-Length: 0
>>>
>>>
>>> Which results in a Call Originate from FreeSwitch with RURI as this:
>>>
>>> INVITE 
>>> *sip:TOPOH.KAMAILIO.IP*;line=sr-N6IAzBy6WBy6MxFwW.qwPSW5ohWINhaYNLu4g9W4OhWI3wKLgRsIpUg5kGs7g9P-W.y6My**
>>> SIP/2.0
>>>
>>>
>>> I am thinking that in TOPOH Module some patch is required to atleast
>>> retain the $rU for 3XX replies , not sure if this will break some RFC or
>>> Kamailio stability etc !
>>>
>>>
>>> Thanks,
>>> Sammy.
>>>
>>>
>>> ___
>>> SIP Express Router (SER) and Kamailio (OpenSER) - sr-users mailing list
>>> sr-users@lists.sip-

Re: [SR-Users] db_cluster.so module and kamctlrc DBHOST= field

2016-02-16 Thread SamyGo
Hi,

I don't think that the cluster module is recognized outside the
kamailio.cfg - In order to get your two Databases to work with DBHOST
string is maybe get a MySQL proxy used between the kamctl and the two
Databases. The MySQL proxy would decide if the first DB is down hence
connect to secondary DB.

Since Kamctl is a bash script if you add two lines your kamctl might just
take either first or the second one all the time.

I hope it answered a little bit of your query.

Regards,
Sammy



On Mon, Feb 15, 2016 at 4:27 PM, Hosted Services 
wrote:

> Hi there,
>
>
>
> New user to Kamailio here. We currently have it up and running in a
> virtualized environment with 1 Kamailio sever, 1 Asterisk server and 1
> MySQL server.
>
>
>
> I’m currently writing install scripts to make deploying new nodes/servers
> easy and to keep settings the same across the board.  I’ve chosed to load
> the db_cluster.so module in kamailio.cfg, as we will have 2x MySQL servers
> in master-master replication which will contain the ‘kamailio’ and
> ‘asterisk’ tables.
>
>
>
> I’ve just hit a stumbling block – in `kamctlrc`, there is a field called
> `DBHOST=`.  How can I reference my cluster here?
>
>
>
> In kamailio.cfg, I simply define DBURL as “cluster//”.  What
> is the syntax for ‘DBHOST=’ in ‘kamctlrc’?  Can I reference the cluster?
> Can I have 2 separate DBHOST= lines?
>
>
>
> Looking for some guidance on this one.
>
>
>
> Thanks,
>
> Derek B.
>
> ___
> SIP Express Router (SER) and Kamailio (OpenSER) - sr-users mailing list
> sr-users@lists.sip-router.org
> http://lists.sip-router.org/cgi-bin/mailman/listinfo/sr-users
>
>
___
SIP Express Router (SER) and Kamailio (OpenSER) - sr-users mailing list
sr-users@lists.sip-router.org
http://lists.sip-router.org/cgi-bin/mailman/listinfo/sr-users


[SR-Users] [TOPOH] Contact header for 302 Moved Temporarily

2016-02-12 Thread SamyGo
Hi All,
I've recently stumbled upon this little hitch while using kamailio with
topoh module that the Contact header do not contains the User part for the
302 Moved temporarily packet.

*My topology:*
UserA<\
->Kamailio<===>FreeSwitch
UserB;tag=yUr5UZ7eF794K
To: ;tag=105223296
Call-ID: cd811276-4b4d-1234-66ae-005056867dbc
CSeq: 87257355 INVITE
Contact: 
User-Agent: Yealink SIP-T46G 28.80.0.70
Diversion: ;reason=unconditional
Content-Length: 0

This is modified in Kamailio TOPOH and sent to FreeSwitch as following


SIP/2.0 302 Moved Temporarily
Via: SIP/2.0/UDP
10.0.20.71;received=10.0.20.71;rport=5060;branch=z9hG4bKeBcy9HKK9cDKr
From: "+4319714111" ;tag=yUr5UZ7eF794K
To: ;tag=105223296
Call-ID: cd811276-4b4d-1234-66ae-005056867dbc
CSeq: 87257355 INVITE
Contact: <*sip:TOPOH.KAMAILIO.IP*
;line=sr-N6IAzBy6WBy6MxFwW.qwPSW5ohWINhaYNLu4g9W4OhWI3wKLgRsIpUg5kGs7g9P-W.y6My**>
User-Agent: Yealink SIP-T46G 28.80.0.70
Diversion: ;reason=unconditional
Content-Length: 0


Which results in a Call Originate from FreeSwitch with RURI as this:

INVITE 
*sip:TOPOH.KAMAILIO.IP*;line=sr-N6IAzBy6WBy6MxFwW.qwPSW5ohWINhaYNLu4g9W4OhWI3wKLgRsIpUg5kGs7g9P-W.y6My**
SIP/2.0


I am thinking that in TOPOH Module some patch is required to atleast retain
the $rU for 3XX replies , not sure if this will break some RFC or Kamailio
stability etc !


Thanks,
Sammy.
___
SIP Express Router (SER) and Kamailio (OpenSER) - sr-users mailing list
sr-users@lists.sip-router.org
http://lists.sip-router.org/cgi-bin/mailman/listinfo/sr-users


Re: [SR-Users] Fw: Kamailio and freeswitch integration for SBC

2016-02-12 Thread SamyGo
Hey Abdul,

Let me get this all done in my Virtual environment, use your cfg script.
Make this work on my environment and get back to you on how to get this
done.
Alternatively you can just share screen via teamviewer or joinme and I may
take a quick look and fix it for you.

Regards,
Sammy.


On Fri, Feb 12, 2016 at 2:33 PM, malik sherif <asheri...@hotmail.com> wrote:

> Thanks Sammy, I will use pastebin.com next as you recommended.
>
> Thanks
>
> Abdul
>
>
> --
> *From:* sr-users <sr-users-boun...@lists.sip-router.org> on behalf of
> SamyGo <govoi...@gmail.com>
> *Sent:* Thursday, February 11, 2016 11:50 PM
> *To:* SIP Router - Kamailio (OpenSER) and SIP Express Router (SER) -
> Users Mailing List
> *Subject:* Re: [SR-Users] Fw: Kamailio and freeswitch integration for SBC
>
>
> Use pastebin.com or something ?
> <http://pastebin.com/>
> Pastebin.com - #1 paste tool since 2002! <http://pastebin.com/>
> pastebin.com
> Pastebin.com is the number one paste tool since 2002. Pastebin is a
> website where you can store text online for a set period of time.
> On Feb 11, 2016 18:32, "malik sherif" <asheri...@hotmail.com> wrote:
>
>> While the full debug log is being approved, I just copy and paste some of
>> the log.
>>
>>
>> 2016-02-11 11:38:42.469315 [DEBUG] switch_core_codec.c:246 sofia/internal/
>> 1...@newkama.abdulkamailiosip.com Restore previous codec PCMU:0.
>> 2016-02-11 11:38:42.549341 [DEBUG] mod_voicemail.c:2806 Deliver VM to
>> 101@10.22.52.2
>> 2016-02-11 11:38:42.669308 [DEBUG] mod_voicemail.c:1923 Update MWI:
>> Processing for 101@10.22.52.2 in inbox
>> 2016-02-11 11:38:42.669308 [DEBUG] mod_voicemail.c:1946 Update MWI:
>> Messages Waiting yes
>> 2016-02-11 11:38:42.669308 [DEBUG] mod_voicemail.c:1947 Update MWI:
>> Update Reason NEW
>> 2016-02-11 11:38:42.669308 [DEBUG] mod_voicemail.c:1948 Update MWI:
>> Message Account 101@10.22.52.2
>> 2016-02-11 11:38:42.669308 [DEBUG] mod_voicemail.c:1949 Update MWI: Voice
>> Message 12/0
>> 2016-02-11 11:38:42.669308 [DEBUG] switch_core_session.c:2901
>> sofia/internal/1...@newkama.abdulkamailiosip.com skip receive message
>> [APPLICATION_EXEC_COMPLETE] (channel is hungup already)
>> 2016-02-11 11:38:42.669308 [DEBUG] switch_core_state_machine.c:535
>> (sofia/internal/1...@newkama.abdulkamailiosip.com) State EXECUTE going to
>> sleep
>> 2016-02-11 11:38:42.669308 [DEBUG] switch_core_state_machine.c:472
>> (sofia/internal/1...@newkama.abdulkamailiosip.com) Running State Change
>> CS_HANGUP
>> 2016-02-11 11:38:42.669308 [DEBUG] switch_core_state_machine.c:735
>> (sofia/internal/1...@newkama.abdulkamailiosip.com) Callstate Change
>> ACTIVE -> HANGUP
>> 2016-02-11 11:38:42.669308 [DEBUG] switch_core_state_machine.c:737
>> (sofia/internal/1...@newkama.abdulkamailiosip.com) State HANGUP
>> 2016-02-11 11:38:42.669308 [DEBUG] mod_sofia.c:407 sofia/internal/
>> 1...@newkama.abdulkamailiosip.com Overriding SIP cause 480 with 904 from
>> the other leg
>> 2016-02-11 11:38:42.669308 [DEBUG] mod_sofia.c:413 Channel sofia/internal/
>> 1...@newkama.abdulkamailiosip.com hanging up, cause: NORMAL_CLEARING
>> 2016-02-11 11:38:42.669308 [DEBUG] switch_core_state_machine.c:60
>> sofia/internal/1...@newkama.abdulkamailiosip.com Standard HANGUP, cause:
>> NORMAL_CLEARING
>> 2016-02-11 11:38:42.669308 [DEBUG] switch_core_state_machine.c:737
>> (sofia/internal/1...@newkama.abdulkamailiosip.com) State HANGUP going to
>> sleep
>> 2016-02-11 11:38:42.669308 [DEBUG] switch_core_state_machine.c:504
>> (sofia/internal/1...@newkama.abdulkamailiosip.com) State Change CS_HANGUP
>> -> CS_REPORTING
>> 2016-02-11 11:38:42.669308 [DEBUG] switch_core_session.c:1396 Send signal
>> sofia/internal/1...@newkama.abdulkamailiosip.com [BREAK]
>> 2016-02-11 11:38:42.669308 [DEBUG] switch_core_state_machine.c:472
>> (sofia/internal/1...@newkama.abdulkamailiosip.com) Running State Change
>> CS_REPORTING
>> 2016-02-11 11:38:42.669308 [DEBUG] switch_core_state_machine.c:823
>> (sofia/internal/1...@newkama.abdulkamailiosip.com) State REPORTING
>> 2016-02-11 11:38:42.669308 [DEBUG] switch_core_state_machine.c:104
>> sofia/internal/1...@newkama.abdulkamailiosip.com Standard REPORTING,
>> cause: NORMAL_CLEARING
>> 2016-02-11 11:38:42.669308 [DEBUG] switch_core_state_machine.c:823
>> (sofia/internal/1...@newkama.abdulkamailiosip.com) State REPORTING going
>> to sleep
>> 2016-02-11 11:38:42.669308 [DEBUG] switch_core_state_machine.c:498
>> (sofia/internal/1...@newkama.abdulkamailiosip.com) State Change
&

Re: [SR-Users] Fw: Kamailio and freeswitch integration for SBC

2016-02-11 Thread SamyGo
Use pastebin.com or something ?
On Feb 11, 2016 18:32, "malik sherif" <asheri...@hotmail.com> wrote:

> While the full debug log is being approved, I just copy and paste some of
> the log.
>
>
> 2016-02-11 11:38:42.469315 [DEBUG] switch_core_codec.c:246 sofia/internal/
> 1...@newkama.abdulkamailiosip.com Restore previous codec PCMU:0.
> 2016-02-11 11:38:42.549341 [DEBUG] mod_voicemail.c:2806 Deliver VM to
> 101@10.22.52.2
> 2016-02-11 11:38:42.669308 [DEBUG] mod_voicemail.c:1923 Update MWI:
> Processing for 101@10.22.52.2 in inbox
> 2016-02-11 11:38:42.669308 [DEBUG] mod_voicemail.c:1946 Update MWI:
> Messages Waiting yes
> 2016-02-11 11:38:42.669308 [DEBUG] mod_voicemail.c:1947 Update MWI: Update
> Reason NEW
> 2016-02-11 11:38:42.669308 [DEBUG] mod_voicemail.c:1948 Update MWI:
> Message Account 101@10.22.52.2
> 2016-02-11 11:38:42.669308 [DEBUG] mod_voicemail.c:1949 Update MWI: Voice
> Message 12/0
> 2016-02-11 11:38:42.669308 [DEBUG] switch_core_session.c:2901
> sofia/internal/1...@newkama.abdulkamailiosip.com skip receive message
> [APPLICATION_EXEC_COMPLETE] (channel is hungup already)
> 2016-02-11 11:38:42.669308 [DEBUG] switch_core_state_machine.c:535
> (sofia/internal/1...@newkama.abdulkamailiosip.com) State EXECUTE going to
> sleep
> 2016-02-11 11:38:42.669308 [DEBUG] switch_core_state_machine.c:472
> (sofia/internal/1...@newkama.abdulkamailiosip.com) Running State Change
> CS_HANGUP
> 2016-02-11 11:38:42.669308 [DEBUG] switch_core_state_machine.c:735
> (sofia/internal/1...@newkama.abdulkamailiosip.com) Callstate Change ACTIVE
> -> HANGUP
> 2016-02-11 11:38:42.669308 [DEBUG] switch_core_state_machine.c:737
> (sofia/internal/1...@newkama.abdulkamailiosip.com) State HANGUP
> 2016-02-11 11:38:42.669308 [DEBUG] mod_sofia.c:407 sofia/internal/
> 1...@newkama.abdulkamailiosip.com Overriding SIP cause 480 with 904 from
> the other leg
> 2016-02-11 11:38:42.669308 [DEBUG] mod_sofia.c:413 Channel sofia/internal/
> 1...@newkama.abdulkamailiosip.com hanging up, cause: NORMAL_CLEARING
> 2016-02-11 11:38:42.669308 [DEBUG] switch_core_state_machine.c:60
> sofia/internal/1...@newkama.abdulkamailiosip.com Standard HANGUP, cause:
> NORMAL_CLEARING
> 2016-02-11 11:38:42.669308 [DEBUG] switch_core_state_machine.c:737
> (sofia/internal/1...@newkama.abdulkamailiosip.com) State HANGUP going to
> sleep
> 2016-02-11 11:38:42.669308 [DEBUG] switch_core_state_machine.c:504
> (sofia/internal/1...@newkama.abdulkamailiosip.com) State Change CS_HANGUP
> -> CS_REPORTING
> 2016-02-11 11:38:42.669308 [DEBUG] switch_core_session.c:1396 Send signal
> sofia/internal/1...@newkama.abdulkamailiosip.com [BREAK]
> 2016-02-11 11:38:42.669308 [DEBUG] switch_core_state_machine.c:472
> (sofia/internal/1...@newkama.abdulkamailiosip.com) Running State Change
> CS_REPORTING
> 2016-02-11 11:38:42.669308 [DEBUG] switch_core_state_machine.c:823
> (sofia/internal/1...@newkama.abdulkamailiosip.com) State REPORTING
> 2016-02-11 11:38:42.669308 [DEBUG] switch_core_state_machine.c:104
> sofia/internal/1...@newkama.abdulkamailiosip.com Standard REPORTING,
> cause: NORMAL_CLEARING
> 2016-02-11 11:38:42.669308 [DEBUG] switch_core_state_machine.c:823
> (sofia/internal/1...@newkama.abdulkamailiosip.com) State REPORTING going
> to sleep
> 2016-02-11 11:38:42.669308 [DEBUG] switch_core_state_machine.c:498
> (sofia/internal/1...@newkama.abdulkamailiosip.com) State Change
> CS_REPORTING -> CS_DESTROY
> 2016-02-11 11:38:42.669308 [DEBUG] switch_core_session.c:1396 Send signal
> sofia/internal/1...@newkama.abdulkamailiosip.com [BREAK]
> 2016-02-11 11:38:42.669308 [DEBUG] switch_core_session.c:1623 Session 7
> (sofia/internal/1...@newkama.abdulkamailiosip.com) Locked, Waiting on
> external entities
> 2016-02-11 11:38:42.669308 [NOTICE] switch_core_session.c:1641 Session 7
> (sofia/internal/1...@newkama.abdulkamailiosip.com) Ended
> 2016-02-11 11:38:42.669308 [NOTICE] switch_core_session.c:1645 Close
> Channel sofia/internal/1...@newkama.abdulkamailiosip.com [CS_DESTROY]
> 2016-02-11 11:38:42.669308 [DEBUG] switch_core_state_machine.c:626
> (sofia/internal/1...@newkama.abdulkamailiosip.com) Running State Change
> CS_DESTROY
> 2016-02-11 11:38:42.669308 [DEBUG] switch_core_state_machine.c:636
> (sofia/internal/1...@newkama.abdulkamailiosip.com) State DESTROY
> 2016-02-11 11:38:42.669308 [DEBUG] mod_sofia.c:323 sofia/internal/
> 1...@newkama.abdulkamailiosip.com SOFIA DESTROY
> 2016-02-11 11:38:42.669308 [DEBUG] switch_core_state_machine.c:111
> sofia/internal/1...@newkama.abdulkamailiosip.com Standard DESTROY
> 2016-02-11 11:38:42.669308 [DEBUG] switch_core_state_machine.c:636
> (sofia/internal/1...@newkama.abdulkamailiosip.com) State DESTROY going to
> sleep
>
>
>
> 

Re: [SR-Users] Fw: Kamailio and freeswitch integration for SBC

2016-02-11 Thread SamyGo
Share logs here as well, might help update the integration guide.

Following are the major reasons why you'll fall into the voicemail
application:

1 - FS failed to Dial to Kamailio, probably unable to reach Kamailio or
syntax problem in the originate/bridge etc
2 - FS dialled to Kamailio but the route file is not properly setup to
handle calls from FS and lookup() the user.
3 - Kamailio is setup correctly but the user is not online, or the lookup()
don't have the user as FS required in uesrlocation table, or the end user
doesn't accept the codecs.

I mentioned the mismatch in domain part in RURI in one of my previous
emails looking at your  sip traces, you've already modified the packet but
I still need to take a look at the sip captures to verify this.

Thanks,
Sammy




On Thu, Feb 11, 2016 at 12:28 PM, malik sherif <asheri...@hotmail.com>
wrote:

> Hello Sammy,
>
> I used both the gateway method and external, the result is the same it
> goes the voicemail. I enabled debug on FS an should I post my question to
> FS? I followed the steps that was in kamailio to integrate kamailio and FS
> to setup SBC and that way I posted on kamailio site.
>
> Thanks
>
> Abdul
>
>
> --
> *From:* sr-users <sr-users-boun...@lists.sip-router.org> on behalf of
> SamyGo <govoi...@gmail.com>
> *Sent:* Wednesday, February 10, 2016 10:23 PM
>
> *To:* Kamailio (SER) - Users Mailing List
> *Subject:* Re: [SR-Users] Fw: Kamailio and freeswitch integration for SBC
>
> Hi Abdul,
>
> Kindly share the whole FS console logs (enable sip debug inside the logs
> too) , can you modify the bridge statement as this:
>
> 
>
> If you have saved your kamailio as a gateway then you can alternatively
> dial it as following:
>
> 
>
> Where *GOOD_GATEWAY* is the gateway name from an xml file. Here is how.
>
> FreeSWITCH:~# cd /usr/local/freeswitch/conf/sip_profiles/external/
>
> FreeSWITCH-A:~# vim kamailio.xml
>
> Insert these Lines in this file:
>
> 
>   
>   
>   
>
>   
>   
>   
>   
>   
>   
>   
>   
> 
>
> Also, if you don't use gateway approach can you make sure that from your
> FS the domain name 'AbdulKamailioSIP.com' resolves to IP of Kamailio
> Server.
>
> I've a feeling that this email should be in Freeswitch mailing list, not
> in Kamailio's/
>
> Regards,
> Sammy
>
>
>
> On Wed, Feb 10, 2016 at 5:00 PM, malik sherif <asheri...@hotmail.com>
> wrote:
>
>> Hello,
>>
>> I am using Kamailio and freeswitch to setup SBC but the I attempted to
>> make a call it just goes to the voice mail.
>>
>> Here is what freeswitch is displaying.
>>
>> Thanks for your help in advance
>>
>> Abdul
>>
>>
>>
>> freeswitch@linux-ix64> 2016-02-10 10:54:16.663387 [NOTICE]
>> switch_channel.c:1055 New Channel sofia/internal/1...@abdulkamailiosip.com
>> [12f87c10-f3be-43ee-b038-f6647e5af373]
>> 2016-02-10 10:54:16.683337 [INFO] mod_dialplan_xml.c:635 Processing 102
>> <102>->kb-102 in context public
>> 2016-02-10 10:54:16.683337 [NOTICE] switch_ivr.c:1861 Transfer
>> sofia/internal/1...@abdulkamailiosip.com to XML[kb-102@default]
>> 2016-02-10 10:54:16.683337 [INFO] mod_dialplan_xml.c:635 Processing 102
>> <102>->kb-102 in context default
>> 2016-02-10 10:54:16.683337 [NOTICE] switch_channel.c:1055 New Channel
>> sofia/internal/1...@abdulkamailiosip.com
>> [0c6c8dda-34fc-45a0-a6a2-8e82ff3a9be3]
>> 2016-02-10 10:54:18.183346 [NOTICE] sofia.c:7539 Hangup
>> sofia/internal/1...@abdulkamailiosip.com [CS_CONSUME_MEDIA]
>> [NORMAL_TEMPORARY_FAILURE]
>> 2016-02-10 10:54:18.183346 [NOTICE] switch_core_session.c:1641 Session 2
>> (sofia/internal/1...@abdulkamailiosip.com) Ended
>> 2016-02-10 10:54:18.183346 [NOTICE] switch_core_session.c:1645 Close
>> Channel sofia/internal/1...@abdulkamailiosip.com [CS_DESTROY]
>> 2016-02-10 10:54:18.183346 [INFO] mod_dptools.c:3244 Originate Failed.
>> Cause: NORMAL_TEMPORARY_FAILURE
>> 2016-02-10 10:54:18.183346 [NOTICE] sofia_media.c:92 Pre-Answer
>> sofia/internal/1...@abdulkamailiosip.com!
>> 2016-02-10 10:54:18.183346 [NOTICE] mod_dptools.c:1268 Channel
>> [sofia/internal/1...@abdulkamailiosip.com] has been answered
>> 2016-02-10 10:54:32.043345 [NOTICE] sofia.c:952 Hangup
>> sofia/internal/1...@abdulkamailiosip.com [CS_EXECUTE] [NORMAL_CLEARING]
>> 2016-02-10 10:54:32.063338 [NOTICE] switch_core_session.c:1641 Session 1
>> (sofia/internal/1...@abdulkamailiosip.com) Ended
>> 2016-02-10 10:54:32.063338 [NOTICE] switch_core_session.c:1645 Close
>> Channel sofia/internal/1...@abdu

[SR-Users] RTCWeb Breaker question

2016-02-10 Thread SamyGo
Hi All,

reference to this link:
https://www.kamailio.org/wiki/devel/rtcweb_breaker#scenarios

I want to know if the module to communicate with RTCWeb Breaker is
available or it was just a proposal and no more under consideration.

I have webrtc clients registered to Kamailio but due to lack of
(scalable/efficient) transcoding capabilities they can not make video calls
to Video IP-Phones.

I tried using webrtc2sip from doubango telecom and it actually enabled me
to achieve the goal, the problem with that case is webrtc2sip is working
with sipml5 client and there is not a big list of WebRTC clients that work
with it.

If I can achieve the referred rtc_web_breaker architecture then I believe a
lot of webRTC clients will be able to integrate with my setup.

Thanks,

Regards,
Sammy
___
SIP Express Router (SER) and Kamailio (OpenSER) - sr-users mailing list
sr-users@lists.sip-router.org
http://lists.sip-router.org/cgi-bin/mailman/listinfo/sr-users


Re: [SR-Users] RTCWeb Breaker question

2016-02-10 Thread SamyGo
Thanks for clarification Daniel. That obviously mean that I can not achieve
transcoding (VP8/H264).

Given my objective do you have any recommendations ?

Thanks for your valuable time..
Regards,
Sammy
On Feb 10, 2016 15:58, "Daniel-Constantin Mierla" <mico...@gmail.com> wrote:

> Hello,
>
> I think that page was created when RTPEngine was at the beginning with
> WebRTC features. Right now it should just work to use Kamailio+RTPEngine to
> communicate with classic SIP phone, given that there is no need to
> transcode (encryption/decryption is done by RTPEngine, as well as
> de-multiplexing streams).
>
> Cheers,
> Daniel
>
> On 10/02/16 20:49, SamyGo wrote:
>
> Hi All,
>
> reference to this link:
> https://www.kamailio.org/wiki/devel/rtcweb_breaker#scenarios
>
> I want to know if the module to communicate with RTCWeb Breaker is
> available or it was just a proposal and no more under consideration.
>
> I have webrtc clients registered to Kamailio but due to lack of
> (scalable/efficient) transcoding capabilities they can not make video calls
> to Video IP-Phones.
>
> I tried using webrtc2sip from doubango telecom and it actually enabled me
> to achieve the goal, the problem with that case is webrtc2sip is working
> with sipml5 client and there is not a big list of WebRTC clients that work
> with it.
>
> If I can achieve the referred rtc_web_breaker architecture then I believe
> a lot of webRTC clients will be able to integrate with my setup.
>
> Thanks,
>
> Regards,
> Sammy
>
>
>
>
> ___
> SIP Express Router (SER) and Kamailio (OpenSER) - sr-users mailing 
> listsr-us...@lists.sip-router.orghttp://lists.sip-router.org/cgi-bin/mailman/listinfo/sr-users
>
>
> --
> Daniel-Constantin Mierlahttp://twitter.com/#!/miconda - 
> http://www.linkedin.com/in/miconda
> Book: SIP Routing With Kamailio - http://www.asipto.comhttp://miconda.eu
>
>
> ___
> SIP Express Router (SER) and Kamailio (OpenSER) - sr-users mailing list
> sr-users@lists.sip-router.org
> http://lists.sip-router.org/cgi-bin/mailman/listinfo/sr-users
>
>
___
SIP Express Router (SER) and Kamailio (OpenSER) - sr-users mailing list
sr-users@lists.sip-router.org
http://lists.sip-router.org/cgi-bin/mailman/listinfo/sr-users


Re: [SR-Users] Fw: Kamailio and freeswitch integration for SBC

2016-02-10 Thread SamyGo
Hi Abdul,

Kindly share the whole FS console logs (enable sip debug inside the logs
too) , can you modify the bridge statement as this:



If you have saved your kamailio as a gateway then you can alternatively
dial it as following:



Where *GOOD_GATEWAY* is the gateway name from an xml file. Here is how.

FreeSWITCH:~# cd /usr/local/freeswitch/conf/sip_profiles/external/

FreeSWITCH-A:~# vim kamailio.xml

Insert these Lines in this file:


  
  
  
   
  
  
  
  
  
  
  
  


Also, if you don't use gateway approach can you make sure that from your FS
the domain name 'AbdulKamailioSIP.com' resolves to IP of Kamailio Server.

I've a feeling that this email should be in Freeswitch mailing list, not in
Kamailio's/

Regards,
Sammy



On Wed, Feb 10, 2016 at 5:00 PM, malik sherif <asheri...@hotmail.com> wrote:

> Hello,
>
> I am using Kamailio and freeswitch to setup SBC but the I attempted to
> make a call it just goes to the voice mail.
>
> Here is what freeswitch is displaying.
>
> Thanks for your help in advance
>
> Abdul
>
>
>
> freeswitch@linux-ix64> 2016-02-10 10:54:16.663387 [NOTICE]
> switch_channel.c:1055 New Channel sofia/internal/1...@abdulkamailiosip.com
> [12f87c10-f3be-43ee-b038-f6647e5af373]
> 2016-02-10 10:54:16.683337 [INFO] mod_dialplan_xml.c:635 Processing 102
> <102>->kb-102 in context public
> 2016-02-10 10:54:16.683337 [NOTICE] switch_ivr.c:1861 Transfer
> sofia/internal/1...@abdulkamailiosip.com to XML[kb-102@default]
> 2016-02-10 10:54:16.683337 [INFO] mod_dialplan_xml.c:635 Processing 102
> <102>->kb-102 in context default
> 2016-02-10 10:54:16.683337 [NOTICE] switch_channel.c:1055 New Channel
> sofia/internal/1...@abdulkamailiosip.com
> [0c6c8dda-34fc-45a0-a6a2-8e82ff3a9be3]
> 2016-02-10 10:54:18.183346 [NOTICE] sofia.c:7539 Hangup
> sofia/internal/1...@abdulkamailiosip.com [CS_CONSUME_MEDIA]
> [NORMAL_TEMPORARY_FAILURE]
> 2016-02-10 10:54:18.183346 [NOTICE] switch_core_session.c:1641 Session 2
> (sofia/internal/1...@abdulkamailiosip.com) Ended
> 2016-02-10 10:54:18.183346 [NOTICE] switch_core_session.c:1645 Close
> Channel sofia/internal/1...@abdulkamailiosip.com [CS_DESTROY]
> 2016-02-10 10:54:18.183346 [INFO] mod_dptools.c:3244 Originate Failed.
> Cause: NORMAL_TEMPORARY_FAILURE
> 2016-02-10 10:54:18.183346 [NOTICE] sofia_media.c:92 Pre-Answer
> sofia/internal/1...@abdulkamailiosip.com!
> 2016-02-10 10:54:18.183346 [NOTICE] mod_dptools.c:1268 Channel
> [sofia/internal/1...@abdulkamailiosip.com] has been answered
> 2016-02-10 10:54:32.043345 [NOTICE] sofia.c:952 Hangup
> sofia/internal/1...@abdulkamailiosip.com [CS_EXECUTE] [NORMAL_CLEARING]
> 2016-02-10 10:54:32.063338 [NOTICE] switch_core_session.c:1641 Session 1
> (sofia/internal/1...@abdulkamailiosip.com) Ended
> 2016-02-10 10:54:32.063338 [NOTICE] switch_core_session.c:1645 Close
> Channel sofia/internal/1...@abdulkamailiosip.com [CS_DESTROY]
>
>
> Any idea as to how to implement this command on freeswitch dial plan, I am
> not sure what to use for gw1
>
>  data="{sip_invite_domain=${sip_from_host}}sofia/gateway/gw1/$1...@domain.org"/>
>
>
>
>
>
> From Freeswitch dial plan
>
>
> 
> 
>   
>   
>   
>data="hangup_after_bridge=true"/>
>  data="sip_invite_domain=AbdulkamailioSIP.com"/>
>data="sip_contact_user=ufs"/>
>  data="sofia/$${domain}/$1...@abdulkamailiosip.com"/>
>   
>   
> 
>   
>
>
>
>
>
>
> --
> *From:* sr-users <sr-users-boun...@lists.sip-router.org> on behalf of
> SamyGo <govoi...@gmail.com>
> *Sent:* Friday, January 29, 2016 5:02 PM
>
> *To:* Kamailio (SER) - Users Mailing List
> *Subject:* Re: [SR-Users] Fw: Kamailio and freeswitch integration for SBC
>
> Sorry for last email:
> if (!lookup("location")) {
> $var(rc) = $rc;
> route(TOVOICEMAIL);
> t_newtran();
> switch ($var(rc)) {
> case -1:
> case -3:
> send_reply("404", "Not Found");
> exit;
> case -2:
> send_reply("405", "Method Not Allowed");
> exit;
> }
> }
> That is where you get 404 Not Found. What I see is that you're registering
> users with domain as AbdulKamailioSIP.com but when your FreeSwitch sends
> call to Kamailio the RURI becomes: *INVITE sip:7632689993@10.22.52.2
> <sip%3A7632689993@10.22.52.2> SIP/2.0* Which is definitely not matching
> any User like: INVITE sip:7632689993@*AbdulKamailioSIP.com* SIP/2.0 So,
> you need to go in your FS dialplan and make sure you set the prop

Re: [SR-Users] RTCWeb Breaker question

2016-02-10 Thread SamyGo
Hi Again,
That is really interesting, I'd like to know how since we do have our own
transcoding mechanism inside some MCU server and I might extract that and
engage it using RTPengine.

Thanks for the idea.

Regards,
Sammy.


On Wed, Feb 10, 2016 at 4:19 PM, Daniel-Constantin Mierla <mico...@gmail.com
> wrote:

> RTPBreaker as per wiki link was never intended to be a transcoder.
>
> Anyhow, you need a media server here - I know that FreeSwitch did a lot of
> video work lately, so it would be the first option I would look at.
>
> Also, if you find a classic sip video transcoder, you can use
> kamailio+rtpengine to decrypt/encrypt the leg to webrtc and get sip and
> plain rtp to this transcoder.
>
> Cheers,
> Daniel
>
>
> On 10/02/16 22:12, SamyGo wrote:
>
> Thanks for clarification Daniel. That obviously mean that I can not
> achieve transcoding (VP8/H264).
>
> Given my objective do you have any recommendations ?
>
> Thanks for your valuable time..
> Regards,
> Sammy
> On Feb 10, 2016 15:58, "Daniel-Constantin Mierla" <mico...@gmail.com>
> wrote:
>
>> Hello,
>>
>> I think that page was created when RTPEngine was at the beginning with
>> WebRTC features. Right now it should just work to use Kamailio+RTPEngine to
>> communicate with classic SIP phone, given that there is no need to
>> transcode (encryption/decryption is done by RTPEngine, as well as
>> de-multiplexing streams).
>>
>> Cheers,
>> Daniel
>>
>> On 10/02/16 20:49, SamyGo wrote:
>>
>> Hi All,
>>
>> reference to this link:
>> https://www.kamailio.org/wiki/devel/rtcweb_breaker#scenarios
>>
>> I want to know if the module to communicate with RTCWeb Breaker is
>> available or it was just a proposal and no more under consideration.
>>
>> I have webrtc clients registered to Kamailio but due to lack of
>> (scalable/efficient) transcoding capabilities they can not make video calls
>> to Video IP-Phones.
>>
>> I tried using webrtc2sip from doubango telecom and it actually enabled me
>> to achieve the goal, the problem with that case is webrtc2sip is working
>> with sipml5 client and there is not a big list of WebRTC clients that work
>> with it.
>>
>> If I can achieve the referred rtc_web_breaker architecture then I believe
>> a lot of webRTC clients will be able to integrate with my setup.
>>
>> Thanks,
>>
>> Regards,
>> Sammy
>>
>>
>>
>>
>> ___
>> SIP Express Router (SER) and Kamailio (OpenSER) - sr-users mailing 
>> listsr-us...@lists.sip-router.orghttp://lists.sip-router.org/cgi-bin/mailman/listinfo/sr-users
>>
>>
>> --
>> Daniel-Constantin Mierlahttp://twitter.com/#!/miconda - 
>> http://www.linkedin.com/in/miconda
>> Book: SIP Routing With Kamailio - http://www.asipto.comhttp://miconda.eu
>>
>>
>> ___
>> SIP Express Router (SER) and Kamailio (OpenSER) - sr-users mailing list
>> sr-users@lists.sip-router.org
>> http://lists.sip-router.org/cgi-bin/mailman/listinfo/sr-users
>>
>>
> --
> Daniel-Constantin Mierlahttp://twitter.com/#!/miconda - 
> http://www.linkedin.com/in/miconda
> Book: SIP Routing With Kamailio - http://www.asipto.comhttp://miconda.eu
>
>
___
SIP Express Router (SER) and Kamailio (OpenSER) - sr-users mailing list
sr-users@lists.sip-router.org
http://lists.sip-router.org/cgi-bin/mailman/listinfo/sr-users


Re: [SR-Users] Kamailio Cluster

2016-02-03 Thread SamyGo
Hi,
Interesting discussion going on. Ive to ask can OP use shared location
table between different kamailio servers and use db mode 3.
All he has to do is if UA B calls UA A via Kamailio2 he just needs to find
the received socket and if it is not local Kamailio2 then route to the IP
maybe attach a custom header and relay call to Kamailio1.
Kamailio1 gets call with the custom headers sends call to route(LOCATION)
or w/e he has for lookups.

Regards,
Sammy
On Feb 3, 2016 06:19, "Daniel Tryba"  wrote:

> On Wed, Feb 03, 2016 at 01:48:50PM +0330, Gholamreza Sabery wrote:
> > Actually I think something is not clear here. Suppose I want to use two
> > Kamailio servers such that a client which is registered on server A is
> able
> > to call another client registered on server B. In this case I use DB_MODE
> > 3. Both servers have access to location database but sockets are
> non-local
> > and cleints are behind symmetric NATs.Now  only the server on which the
> > client is registered and sent it's request to is able to respond(because
> of
> > symmetric NAT). Is it possible to implement this scenario using Path
> header?
>
> This is still ambigious, server B can't call the client due to nat, but
> server B can call server A. The trick might be to add a Path header on
> server A before save the register on server A. Or to use custom queries
> to find out that the registered socket isn't local so send the invite to
> the non local adress instead.
>
> I asked similar questions:
> http://lists.sip-router.org/pipermail/sr-users/2015-April/087867.html
>
> My final solution is using a really loadbalancer with static config,
> which adds Path and dispatches to individual backends. Difference is
> that server B doesn't INVITE to server A but to the loadbalancer for a
> client registered on server A.
>
> ___
> SIP Express Router (SER) and Kamailio (OpenSER) - sr-users mailing list
> sr-users@lists.sip-router.org
> http://lists.sip-router.org/cgi-bin/mailman/listinfo/sr-users
>
___
SIP Express Router (SER) and Kamailio (OpenSER) - sr-users mailing list
sr-users@lists.sip-router.org
http://lists.sip-router.org/cgi-bin/mailman/listinfo/sr-users


Re: [SR-Users] RTPPROXY issue and sip to sip calling

2016-01-31 Thread SamyGo
Hi Rehan,

No matter which mode you are running rtpproxy in that IP will always be the
IP of the machine it is running on.
That means that SDP will take that IP once routed to locally subnet A2B
servers.
As far as the A2B detecting SIP user as online or offline based on DB,  I
am not too sure about it. If it is realtime then I think it should work out
of box. You may need to try it out to know it accurately.

Regards,
Sammy
On Jan 30, 2016 02:05, "Ahmed Rehan"  wrote:

> Dear All
>
> I m trying to setup kamailio and asterisk in load balancing with a2billing
> . Currently all of my VMs, one Kamailio and two asterisks are on same
> subnet . I have started the RTPproxy like below
>
> ./rtpproxy -s udp:127.0.0.1:7722 -l X.X.X.153 -m 1 -M 5 -u root
> root -F -d INFO LOG_LOCAL0
>
> My question is if all the VMs are on same subnet with same gateway what
> should be written in the private IP X.X.X.153/
>
> Secondly i m authenticating and registering the SIP on kamailio using the
> A2B DB . all the dialplan for a2b is being run on asterisk . Now if i want
> to call SIP peer to Peer like in case of followme case ,
>
> How should i route the calls in Kamailio ? will it be using usr loc
> module? if so any help will be appreciated
>
> --
>
>
> Regards
> Ahmed Rehan
>
> ___
> SIP Express Router (SER) and Kamailio (OpenSER) - sr-users mailing list
> sr-users@lists.sip-router.org
> http://lists.sip-router.org/cgi-bin/mailman/listinfo/sr-users
>
>
___
SIP Express Router (SER) and Kamailio (OpenSER) - sr-users mailing list
sr-users@lists.sip-router.org
http://lists.sip-router.org/cgi-bin/mailman/listinfo/sr-users


Re: [SR-Users] Fw: Kamailio and freeswitch integration for SBC

2016-01-29 Thread SamyGo
Hi Abdul,

This is where you are getting your 404 NOT Found from Kamailio:



On Thu, Jan 28, 2016 at 4:30 PM, malik sherif <asheri...@hotmail.com> wrote:

> I will also run the commands that suggested.
>
>
> --
> *From:* sr-users <sr-users-boun...@lists.sip-router.org> on behalf of
> SamyGo <govoi...@gmail.com>
> *Sent:* Thursday, January 28, 2016 6:08 PM
> *To:* Kamailio (SER) - Users Mailing List
> *Subject:* Re: [SR-Users] Fw: Kamailio and freeswitch integration for SBC
>
> I believe Daniel is busy with FOSDEM ,
>
>
> Abdul can you confirm that you're still getting this output in FS console:
>
> 2016-01-13 05:37:29.572184 [INFO] mod_dialplan_xml.c:635 Processing
> 7632689991 <7632689991>->kb-7632689993 in context default
> 2016-01-13 05:37:29.572184 [CRIT] mod_dptools.c:1638 WARNING WARNING
> WARNING WARNING WARNING WARNING WARNING WARNING WARNING
> 2016-01-13 05:37:29.572184 [CRIT] mod_dptools.c:1638 Open
> /usr/local/freeswitch/conf/vars.xml and change the default_password.
> 2016-01-13 05:37:29.572184 [CRIT] mod_dptools.c:1638 Once changed type
> 'reloadxml' at the console.
> 2016-01-13 05:37:29.572184 [CRIT] mod_dptools.c:1638 WARNING WARNING
> WARNING WARNING WARNING WARNING WARNING WARNING WARNING
> 2016-01-13 05:37:39.632245 [NOTICE] switch_channel.c:1055 New Channel
> sofia/internal/7632689993@10.22.52.2
> [d52b6ef9-c4f6-4edf-aff9-8a8da3761788]
> 2016-01-13 05:37:39.632245 [NOTICE] sofia.c:7539 Hangup sofia/internal/
> 7632689993@10.22.52.2 [CS_ROUTING] [UNALLOCATED_NUMBER]
>
> Please paste your complete dialplan here as well, though this clearly
> states that the number it tried to dial is not registered or unable to dial
> to.
> please paste out the content of the following command just before dialing:
>
> * fs_cli> show registrations *
> Also, it will help you find out useful info about why it shows you
> UNALLOCATED NUMBER if you enable the sofia sip debug by using the following
> command.
>
> *fs_cli> sofia global siptrace on *
> Once you execute the above command make a call to destination and see what
> FreeeSWITCH is trying to do.
>
> Thanks,
> Sammy.
>
> On Thu, Jan 28, 2016 at 11:23 AM, malik sherif <asheri...@hotmail.com>
> wrote:
>
>>
>> Any hint?
>>
>> --
>> *From:* sr-users <sr-users-boun...@lists.sip-router.org> on behalf of
>> malik sherif <asheri...@hotmail.com>
>> *Sent:* Tuesday, January 26, 2016 11:35 PM
>> *To:* Kamailio (SER) - Users Mailing List; mico...@gmail.com
>>
>> *Subject:* Re: [SR-Users] Kamailio and freeswitch integration for SBC
>>
>>
>> Thanks again and here is the pcap file.
>>
>> Thanks
>>
>> Abdul
>>
>>
>> --
>> *From:* Daniel-Constantin Mierla <mico...@gmail.com>
>> *Sent:* Friday, January 22, 2016 8:46 AM
>> *To:* malik sherif; Kamailio (SER) - Users Mailing List
>> *Subject:* Re: [SR-Users] Kamailio and freeswitch integration for SBC
>>
>> Can you attach the pcap file - copy inline makes it imposible to
>> read and digest it with a traffic analyzer (e.g., wireshark).
>>
>> Cheers,
>> Daniel
>>
>> On 21/01/16 18:31, malik sherif wrote:
>>
>>
>>
>>
>> --
>> *From:* sr-users <sr-users-boun...@lists.sip-router.org>
>> <sr-users-boun...@lists.sip-router.org> on behalf of malik sherif
>> <asheri...@hotmail.com> <asheri...@hotmail.com>
>> *Sent:* Wednesday, January 20, 2016 9:55 PM
>> *To:* Kamailio (SER) - Users Mailing List
>> *Subject:* Re: [SR-Users] Kamailio and freeswitch integration for SBC
>>
>>
>> Copy and paste part of tcmdump and highlighted the 404. 10.22.52.2 is the
>> server IP address
>>
>> Thanks again
>>
>> Abdul
>>
>>
>> <http://kb.asipto.com/freeswitch:kamailio-3.3.x-freeswitch-1.2.x-sbc>
>>
>>
>> --
>> Daniel-Constantin Mierlahttp://twitter.com/#!/miconda - 
>> http://www.linkedin.com/in/miconda
>> Book: SIP Routing With Kamailio - http://www.asipto.comhttp://miconda.eu
>>
>>
>> ___
>> SIP Express Router (SER) and Kamailio (OpenSER) - sr-users mailing list
>> sr-users@lists.sip-router.org
>> http://lists.sip-router.org/cgi-bin/mailman/listinfo/sr-users
>>
>>
>
> ___
> SIP Express Router (SER) and Kamailio (OpenSER) - sr-users mailing list
> sr-users@lists.sip-router.org
> http://lists.sip-router.org/cgi-bin/mailman/listinfo/sr-users
>
>
___
SIP Express Router (SER) and Kamailio (OpenSER) - sr-users mailing list
sr-users@lists.sip-router.org
http://lists.sip-router.org/cgi-bin/mailman/listinfo/sr-users


Re: [SR-Users] Fw: Kamailio and freeswitch integration for SBC

2016-01-29 Thread SamyGo
Sorry for last email:
if (!lookup("location")) {
$var(rc) = $rc;
route(TOVOICEMAIL);
t_newtran();
switch ($var(rc)) {
case -1:
case -3:
send_reply("404", "Not Found");
exit;
case -2:
send_reply("405", "Method Not Allowed");
exit;
}
}
That is where you get 404 Not Found. What I see is that you're registering
users with domain as AbdulKamailioSIP.com but when your FreeSwitch sends
call to Kamailio the RURI becomes: *INVITE sip:7632689993@10.22.52.2
<sip%3A7632689993@10.22.52.2> SIP/2.0* Which is definitely not matching any
User like: INVITE sip:7632689993@*AbdulKamailioSIP.com* SIP/2.0 So, you
need to go in your FS dialplan and make sure you set the proper Domains
before sending call out, there are couple of ways to do this. *1 - *Using
FreeSWITCH to set FROM domain:
https://wiki.freeswitch.org/wiki/Variable_sip_invite_domain *2 - *Use
custom SIP header from FS to contain a domain name, and in Kamailio set
headers as you require; something like this: Attach a SIP Header in FS
dialplan before sending call out to Kamailio, say X-USER-DOMAIN:
AbdulKamailioSIP.com Next when I receive call in Kamailio.cfg I detect this
header if(is_present_hf("X-USER-DOMAIN")) { $ru = "sip:" + $rU + "@" +
$hdr(X-USER-DOMAIN); $td = $hdr(X-USER-DOMAIN); } In option 2 you must do
it before executing record_route() functions, so possibly need to do this
inside your FSINBOUND route. I prefer option 1. PS: Wireshark highlights
any custom SIP headers in sky blue, that doesn't mean there is any error in
there.

Regards,
Sammy


On Fri, Jan 29, 2016 at 11:47 AM, SamyGo <govoi...@gmail.com> wrote:

> Hi Abdul,
>
> This is where you are getting your 404 NOT Found from Kamailio:
>
>
>
> On Thu, Jan 28, 2016 at 4:30 PM, malik sherif <asheri...@hotmail.com>
> wrote:
>
>> I will also run the commands that suggested.
>>
>>
>> --
>> *From:* sr-users <sr-users-boun...@lists.sip-router.org> on behalf of
>> SamyGo <govoi...@gmail.com>
>> *Sent:* Thursday, January 28, 2016 6:08 PM
>> *To:* Kamailio (SER) - Users Mailing List
>> *Subject:* Re: [SR-Users] Fw: Kamailio and freeswitch integration for SBC
>>
>> I believe Daniel is busy with FOSDEM ,
>>
>>
>> Abdul can you confirm that you're still getting this output in FS
>> console:
>>
>> 2016-01-13 05:37:29.572184 [INFO] mod_dialplan_xml.c:635 Processing
>> 7632689991 <7632689991>->kb-7632689993 in context default
>> 2016-01-13 05:37:29.572184 [CRIT] mod_dptools.c:1638 WARNING WARNING
>> WARNING WARNING WARNING WARNING WARNING WARNING WARNING
>> 2016-01-13 05:37:29.572184 [CRIT] mod_dptools.c:1638 Open
>> /usr/local/freeswitch/conf/vars.xml and change the default_password.
>> 2016-01-13 05:37:29.572184 [CRIT] mod_dptools.c:1638 Once changed type
>> 'reloadxml' at the console.
>> 2016-01-13 05:37:29.572184 [CRIT] mod_dptools.c:1638 WARNING WARNING
>> WARNING WARNING WARNING WARNING WARNING WARNING WARNING
>> 2016-01-13 05:37:39.632245 [NOTICE] switch_channel.c:1055 New Channel
>> sofia/internal/7632689993@10.22.52.2
>> [d52b6ef9-c4f6-4edf-aff9-8a8da3761788]
>> 2016-01-13 05:37:39.632245 [NOTICE] sofia.c:7539 Hangup sofia/internal/
>> 7632689993@10.22.52.2 [CS_ROUTING] [UNALLOCATED_NUMBER]
>>
>> Please paste your complete dialplan here as well, though this clearly
>> states that the number it tried to dial is not registered or unable to dial
>> to.
>> please paste out the content of the following command just before dialing:
>>
>> * fs_cli> show registrations *
>> Also, it will help you find out useful info about why it shows you
>> UNALLOCATED NUMBER if you enable the sofia sip debug by using the following
>> command.
>>
>> *fs_cli> sofia global siptrace on *
>> Once you execute the above command make a call to destination and see
>> what FreeeSWITCH is trying to do.
>>
>> Thanks,
>> Sammy.
>>
>> On Thu, Jan 28, 2016 at 11:23 AM, malik sherif <asheri...@hotmail.com>
>> wrote:
>>
>>>
>>> Any hint?
>>>
>>> --
>>> *From:* sr-users <sr-users-boun...@lists.sip-router.org> on behalf of
>>> malik sherif <asheri...@hotmail.com>
>>> *Sent:* Tuesday, January 26, 2016 11:35 PM
>>> *To:* Kamailio (SER) - Users Mailing List; mico...@gmail.com
>>>
>>> *Subject:* Re: [SR-Users] Kamailio and freeswitch integration for SBC
>>>
>>>
>>> Thanks again and here is the pcap file.
>>>
>>> Thanks
>>>
>>> Abdul
>>>
>>>
>>>

Re: [SR-Users] Fw: Kamailio and freeswitch integration for SBC

2016-01-28 Thread SamyGo
I believe Daniel is busy with FOSDEM ,


Abdul can you confirm that you're still getting this output in FS console:

2016-01-13 05:37:29.572184 [INFO] mod_dialplan_xml.c:635 Processing
7632689991 <7632689991>->kb-7632689993 in context default
2016-01-13 05:37:29.572184 [CRIT] mod_dptools.c:1638 WARNING WARNING
WARNING WARNING WARNING WARNING WARNING WARNING WARNING
2016-01-13 05:37:29.572184 [CRIT] mod_dptools.c:1638 Open
/usr/local/freeswitch/conf/vars.xml and change the default_password.
2016-01-13 05:37:29.572184 [CRIT] mod_dptools.c:1638 Once changed type
'reloadxml' at the console.
2016-01-13 05:37:29.572184 [CRIT] mod_dptools.c:1638 WARNING WARNING
WARNING WARNING WARNING WARNING WARNING WARNING WARNING
2016-01-13 05:37:39.632245 [NOTICE] switch_channel.c:1055 New Channel
sofia/internal/7632689993@10.22.52.2 [d52b6ef9-c4f6-4edf-aff9-8a8da3761788]
2016-01-13 05:37:39.632245 [NOTICE] sofia.c:7539 Hangup sofia/internal/
7632689993@10.22.52.2 [CS_ROUTING] [UNALLOCATED_NUMBER]

Please paste your complete dialplan here as well, though this clearly
states that the number it tried to dial is not registered or unable to dial
to.
please paste out the content of the following command just before dialing:

*fs_cli> show registrations*
Also, it will help you find out useful info about why it shows you
UNALLOCATED NUMBER if you enable the sofia sip debug by using the following
command.

*fs_cli> sofia global siptrace on*
Once you execute the above command make a call to destination and see what
FreeeSWITCH is trying to do.

Thanks,
Sammy.

On Thu, Jan 28, 2016 at 11:23 AM, malik sherif 
wrote:

>
> Any hint?
>
> --
> *From:* sr-users  on behalf of
> malik sherif 
> *Sent:* Tuesday, January 26, 2016 11:35 PM
> *To:* Kamailio (SER) - Users Mailing List; mico...@gmail.com
>
> *Subject:* Re: [SR-Users] Kamailio and freeswitch integration for SBC
>
>
> Thanks again and here is the pcap file.
>
> Thanks
>
> Abdul
>
>
> --
> *From:* Daniel-Constantin Mierla 
> *Sent:* Friday, January 22, 2016 8:46 AM
> *To:* malik sherif; Kamailio (SER) - Users Mailing List
> *Subject:* Re: [SR-Users] Kamailio and freeswitch integration for SBC
>
> Can you attach the pcap file - copy inline makes it imposible to
> read and digest it with a traffic analyzer (e.g., wireshark).
>
> Cheers,
> Daniel
>
> On 21/01/16 18:31, malik sherif wrote:
>
>
>
>
> --
> *From:* sr-users 
>  on behalf of malik sherif
>  
> *Sent:* Wednesday, January 20, 2016 9:55 PM
> *To:* Kamailio (SER) - Users Mailing List
> *Subject:* Re: [SR-Users] Kamailio and freeswitch integration for SBC
>
>
> Copy and paste part of tcmdump and highlighted the 404. 10.22.52.2 is the
> server IP address
>
> Thanks again
>
> Abdul
>
>
> 
>
>
> --
> Daniel-Constantin Mierlahttp://twitter.com/#!/miconda - 
> http://www.linkedin.com/in/miconda
> Book: SIP Routing With Kamailio - http://www.asipto.comhttp://miconda.eu
>
>
> ___
> SIP Express Router (SER) and Kamailio (OpenSER) - sr-users mailing list
> sr-users@lists.sip-router.org
> http://lists.sip-router.org/cgi-bin/mailman/listinfo/sr-users
>
>
___
SIP Express Router (SER) and Kamailio (OpenSER) - sr-users mailing list
sr-users@lists.sip-router.org
http://lists.sip-router.org/cgi-bin/mailman/listinfo/sr-users


Re: [SR-Users] Different rtpproxy for different media type

2016-01-15 Thread SamyGo
Got it.

That is something that I dont think is possible with RTPproxy. Just read
the functions for nathelper as well as rtpproxy twice and it just says it
will modify the seasion level c= or media connection but nowhere it says we
can tell which specific c attrib to modify.
Im only assuming that even if multiple media types have different
connection strings rtpproxy would just go and modify all at once or just
the first one.

Its an interesting thing and I will be reading mediproxy and rtpengine and
anyother available compatible media proxy to see if they allow that.

Worst case scenario source codes would need modification on kamailio as
well as rtpproxy side to accomodate this.

Regards,
Sammy
On Jan 15, 2016 01:33, "Koray Vatansever" <koray.vatanse...@gmail.com>
wrote:

> I think I couldn't explain myself clearly.
> I want to see the following media lines in resulting SDP:
>
> m=audio 10076 RTP/AVP 97 98
> c=IN IP4 rtpproxy1.example.com
> a=rtpmap:97 speex/8000
> a=fmtp:97 vbr=on
> a=rtpmap:98 telephone-event/8000
> m=video 20007 RTP/AVP 96
> c=IN IP4 rtpproxy2.example.com
> a=rtpmap:96 VP8/90000
>
>
>
> On Thu, Jan 14, 2016 at 8:31 PM, SamyGo <govoi...@gmail.com> wrote:
>
>> Do you want to change/update the SDP once the call is established ?
>> shouldn't it just work like this:
>>
>> if(has_totag() && is_method("INVITE")) {
>>   if(search_body("video") {
>>   set_rtpproxy_set("1");
>>   unforce_rtpproxy();
>>   set_rtpproxy_set("2");
>>   offer_rtpproxy("$avp(myflags)");
>>  }
>> }
>>
>> Since it is already a ReINVITE any modification in the SDP c= part should
>> be happily accepted !?
>>
>> Regards,
>> Sammy
>>
>> On Thu, Jan 14, 2016 at 10:18 AM, Koray Vatansever <
>> koray.vatanse...@gmail.com> wrote:
>>
>>> Hi Sammy,
>>>
>>> I'm not sure it will work.
>>> Assume the following scenario:
>>> Kamailio receives INVITE with audio only SDP and selects rtpproxy-1.
>>> After a while video is enabled with REINVITE.
>>> Now SDP has video and kamailio selects rtpproxy-2 according to your
>>> solution.
>>> In this case, most probably video and audio rtp packages will flow
>>> through rtpproxy-2.
>>> However what I want to do is to keep rtpproxy-1 for audio packages and
>>> add rtpproxy-2 for video packages
>>> and release audio ports from rtpproxy-1 and video ports from rtpproxy-2
>>> when BYE received.
>>>
>>> Is there any easy way to do that in Kamailio?
>>>
>>>
>>>
>>>
>>> On Thu, Jan 14, 2016 at 3:30 PM, SamyGo <govoi...@gmail.com> wrote:
>>>
>>>> Hi,
>>>> Yes thats possible as I think you can do a search in SDP body for
>>>> "video" if found then select the rtpproxy instance else select other one.
>>>>
>>>> Regards,
>>>> Sammy
>>>> On Jan 14, 2016 06:39, "Koray Vatansever" <koray.vatanse...@gmail.com>
>>>> wrote:
>>>>
>>>>> Hi everybody,
>>>>>
>>>>> Is there a way to use different rtpproxies for different media types?
>>>>> I want to use one rtpproxy set for audio, and use another one for
>>>>> video.
>>>>> Is this possible in kamailio?
>>>>>
>>>>>
>>>>> Regards,
>>>>> Koray
>>>>>
>>>>> ___
>>>>> SIP Express Router (SER) and Kamailio (OpenSER) - sr-users mailing list
>>>>> sr-users@lists.sip-router.org
>>>>> http://lists.sip-router.org/cgi-bin/mailman/listinfo/sr-users
>>>>>
>>>>>
>>>> ___
>>>> SIP Express Router (SER) and Kamailio (OpenSER) - sr-users mailing list
>>>> sr-users@lists.sip-router.org
>>>> http://lists.sip-router.org/cgi-bin/mailman/listinfo/sr-users
>>>>
>>>>
>>>
>>> ___
>>> SIP Express Router (SER) and Kamailio (OpenSER) - sr-users mailing list
>>> sr-users@lists.sip-router.org
>>> http://lists.sip-router.org/cgi-bin/mailman/listinfo/sr-users
>>>
>>>
>>
>> ___
>> SIP Express Router (SER) and Kamailio (OpenSER) - sr-users mailing list
>> sr-users@lists.sip-router.org
>> http://lists.sip-router.org/cgi-bin/mailman/listinfo/sr-users
>>
>>
>
> ___
> SIP Express Router (SER) and Kamailio (OpenSER) - sr-users mailing list
> sr-users@lists.sip-router.org
> http://lists.sip-router.org/cgi-bin/mailman/listinfo/sr-users
>
>
___
SIP Express Router (SER) and Kamailio (OpenSER) - sr-users mailing list
sr-users@lists.sip-router.org
http://lists.sip-router.org/cgi-bin/mailman/listinfo/sr-users


Re: [SR-Users] Different rtpproxy for different media type

2016-01-14 Thread SamyGo
Hi,
Yes thats possible as I think you can do a search in SDP body for "video"
if found then select the rtpproxy instance else select other one.

Regards,
Sammy
On Jan 14, 2016 06:39, "Koray Vatansever" 
wrote:

> Hi everybody,
>
> Is there a way to use different rtpproxies for different media types?
> I want to use one rtpproxy set for audio, and use another one for video.
> Is this possible in kamailio?
>
>
> Regards,
> Koray
>
> ___
> SIP Express Router (SER) and Kamailio (OpenSER) - sr-users mailing list
> sr-users@lists.sip-router.org
> http://lists.sip-router.org/cgi-bin/mailman/listinfo/sr-users
>
>
___
SIP Express Router (SER) and Kamailio (OpenSER) - sr-users mailing list
sr-users@lists.sip-router.org
http://lists.sip-router.org/cgi-bin/mailman/listinfo/sr-users


Re: [SR-Users] Different rtpproxy for different media type

2016-01-14 Thread SamyGo
Do you want to change/update the SDP once the call is established ?
shouldn't it just work like this:

if(has_totag() && is_method("INVITE")) {
  if(search_body("video") {
  set_rtpproxy_set("1");
  unforce_rtpproxy();
  set_rtpproxy_set("2");
  offer_rtpproxy("$avp(myflags)");
 }
}

Since it is already a ReINVITE any modification in the SDP c= part should
be happily accepted !?

Regards,
Sammy

On Thu, Jan 14, 2016 at 10:18 AM, Koray Vatansever <
koray.vatanse...@gmail.com> wrote:

> Hi Sammy,
>
> I'm not sure it will work.
> Assume the following scenario:
> Kamailio receives INVITE with audio only SDP and selects rtpproxy-1.
> After a while video is enabled with REINVITE.
> Now SDP has video and kamailio selects rtpproxy-2 according to your
> solution.
> In this case, most probably video and audio rtp packages will flow through
> rtpproxy-2.
> However what I want to do is to keep rtpproxy-1 for audio packages and add
> rtpproxy-2 for video packages
> and release audio ports from rtpproxy-1 and video ports from rtpproxy-2
> when BYE received.
>
> Is there any easy way to do that in Kamailio?
>
>
>
>
> On Thu, Jan 14, 2016 at 3:30 PM, SamyGo <govoi...@gmail.com> wrote:
>
>> Hi,
>> Yes thats possible as I think you can do a search in SDP body for "video"
>> if found then select the rtpproxy instance else select other one.
>>
>> Regards,
>> Sammy
>> On Jan 14, 2016 06:39, "Koray Vatansever" <koray.vatanse...@gmail.com>
>> wrote:
>>
>>> Hi everybody,
>>>
>>> Is there a way to use different rtpproxies for different media types?
>>> I want to use one rtpproxy set for audio, and use another one for video.
>>> Is this possible in kamailio?
>>>
>>>
>>> Regards,
>>> Koray
>>>
>>> ___
>>> SIP Express Router (SER) and Kamailio (OpenSER) - sr-users mailing list
>>> sr-users@lists.sip-router.org
>>> http://lists.sip-router.org/cgi-bin/mailman/listinfo/sr-users
>>>
>>>
>> ___
>> SIP Express Router (SER) and Kamailio (OpenSER) - sr-users mailing list
>> sr-users@lists.sip-router.org
>> http://lists.sip-router.org/cgi-bin/mailman/listinfo/sr-users
>>
>>
>
> ___
> SIP Express Router (SER) and Kamailio (OpenSER) - sr-users mailing list
> sr-users@lists.sip-router.org
> http://lists.sip-router.org/cgi-bin/mailman/listinfo/sr-users
>
>
___
SIP Express Router (SER) and Kamailio (OpenSER) - sr-users mailing list
sr-users@lists.sip-router.org
http://lists.sip-router.org/cgi-bin/mailman/listinfo/sr-users


Re: [SR-Users] Presence - Subscription based NOTIFY to enable MWI

2016-01-03 Thread SamyGo
It is possible. I created a blog entry from a mailing list thread doing
this sort of stuff for Asterisk behind Kamailio and voicemail MWI .
http://saevolgo.blogspot.ca/2012/07/asterisk-behind-kamailio-voicemail-mwi.html?m=1

The scripts and everything should just give you idea. In Kamailio when you
get Subscribe create a file in temp folder with User in it. Take a cron job
that runs a sipsak based script to lookup any files in that temp folder.
Based on that username do w/e you want and create a SIP packet and send it
back to Kamailio.

I hope this may get you some ideas.
On Jan 3, 2016 02:39, "Arsen Hovhanissian"  wrote:

> I see, what i’m trying to do is actually to limit querying the DB by
> updating the MWI only when there is activity.
> In other words to send a NOTIFY when the user receives a new message in
> his voicemailbox.
>
> I am not sure if it’s possible to send the NOTIFY for example 5-30 mins
> after the initial subscribe.
> ___
> SIP Express Router (SER) and Kamailio (OpenSER) - sr-users mailing list
> sr-users@lists.sip-router.org
> http://lists.sip-router.org/cgi-bin/mailman/listinfo/sr-users
>
___
SIP Express Router (SER) and Kamailio (OpenSER) - sr-users mailing list
sr-users@lists.sip-router.org
http://lists.sip-router.org/cgi-bin/mailman/listinfo/sr-users


Re: [SR-Users] Presence - Subscription based NOTIFY to enable MWI

2016-01-02 Thread SamyGo
Hi,
You can catch this NOTIFY in kamailio and execute a script using sipsak
like perl script doing some db/file/sipsak stuff.
You might find examples of such thing in few older threads.
On Jan 2, 2016 18:55, "Arsen Hovhanissian"  wrote:

> Hi everyone, I’m trying to send a NOTIFY event using “sipsak” to enable
> the MWI
> I read up a lot of documentation and didn’t really find the information
> needed to accomplish this.
>
> So I have:
> Phone 1 -> P1
> Server 1 -> S1 (Kamailio 4.3.4)
> Server 2 -> S2 (sipsak)
>
> P1 registers to S1 and creates a new entry in the active watchers table
> with a "message-summary” event.
> At this point I am assuming that any request I would send will be out of
> dialog.
>
> Now the question is, How could I reply to that SUBSCRIPTION with a NOTIFY?
>
> Thanks in advance!
> ___
> SIP Express Router (SER) and Kamailio (OpenSER) - sr-users mailing list
> sr-users@lists.sip-router.org
> http://lists.sip-router.org/cgi-bin/mailman/listinfo/sr-users
>
___
SIP Express Router (SER) and Kamailio (OpenSER) - sr-users mailing list
sr-users@lists.sip-router.org
http://lists.sip-router.org/cgi-bin/mailman/listinfo/sr-users


Re: [SR-Users] (no subject)

2015-11-13 Thread SamyGo
Hi,
I believe you're trying to setup some MOH-Queue it can't find the MOH file.

 0(4420) ERROR: mohqueue [mohq_db.c:504]: update_mohq_lst(): Queue,Field
(test_queue,mohdir): Unable to find MOH files (/var/kamailio/MOH//test.8.*)!

Or if files exist at that location check the permissions.

Regards,
Sammy


On Fri, Nov 13, 2015 at 3:27 PM, David Villasmil Govea <
david.villas...@gmail.com> wrote:

> Hello guys,
>
> I'm trying to startup 4.3 and i'm getting the following:
>
>
>  0(4420) DEBUG:  [db_row.c:117]: db_allocate_row(): allocate 192
> bytes for row values at 0x7fe6bf6b5a48
>  0(4420) DEBUG:  [db_val.c:74]: db_str2val(): converting INT [1]
>  0(4420) DEBUG:  [db_val.c:118]: db_str2val(): converting STRING [
> sip:1234@172.16.163.130]
>  0(4420) DEBUG:  [db_val.c:118]: db_str2val(): converting STRING
> [/var/kamailio/MOH/]
>  0(4420) DEBUG:  [db_val.c:118]: db_str2val(): converting STRING
> [test.8]
>  0(4420) DEBUG:  [db_val.c:118]: db_str2val(): converting STRING
> [test_queue]
>  0(4420) DEBUG:  [db_val.c:74]: db_str2val(): converting INT [9]
>  0(4420) ERROR: mohqueue [mohq_db.c:504]: update_mohq_lst(): Queue,Field
> (test_queue,mohdir): Unable to find MOH files (/var/kamailio/MOH//test.8.*)!
>  0(4420) DEBUG:  [db_pool.c:100]: pool_remove(): removing connection
> from the pool
>  0(4420) DEBUG:  [sr_module.c:689]: find_mod_export_record():
> find_export_record: found  in module sl
> [/usr/lib/x86_64-linux-gnu/kamailio/modules/sl.so]
>  0(4420) DEBUG:  [sr_module.c:689]: find_mod_export_record():
> find_export_record: found  in module tm
> [/usr/lib/x86_64-linux-gnu/kamailio/modules/tm.so]
>  0(4420) DEBUG:  [sr_module.c:689]: find_mod_export_record():
> find_export_record: found  in module tm
> [/usr/lib/x86_64-linux-gnu/kamailio/modules/tm.so]
>  0(4420) DEBUG:  [sr_module.c:689]: find_mod_export_record():
> find_export_record: found  in module tm
> [/usr/lib/x86_64-linux-gnu/kamailio/modules/tm.so]
>  0(4420) DEBUG:  [sr_module.c:689]: find_mod_export_record():
> find_export_record: found  in module tm
> [/usr/lib/x86_64-linux-gnu/kamailio/modules/tm.so]
>  0(4420) DEBUG:  [sr_module.c:689]: find_mod_export_record():
> find_export_record: found  in module tm
> [/usr/lib/x86_64-linux-gnu/kamailio/modules/tm.so]
>  0(4420) DEBUG:  [sr_module.c:689]: find_mod_export_record():
> find_export_record: found  in module tm
> [/usr/lib/x86_64-linux-gnu/kamailio/modules/tm.so]
>  0(4420) DEBUG:  [sr_module.c:689]: find_mod_export_record():
> find_export_record: found  in module tm
> [/usr/lib/x86_64-linux-gnu/kamailio/modules/tm.so]
>  0(4420) DEBUG:  [sr_module.c:689]: find_mod_export_record():
> find_export_record: found  in module rr
> [/usr/lib/x86_64-linux-gnu/kamailio/modules/rr.so]
>  0(4420) DEBUG:  [sr_module.c:695]: find_mod_export_record():
> find_export_record:  not found
>  0(4420) ERROR: mohqueue [mohq.c:390]: mod_init(): Unable to load
> rtpproxy_answer
>  0(4420) ERROR:  [sr_module.c:962]: init_mod(): Error while
> initializing module mohqueue
> (/usr/lib/x86_64-linux-gnu/kamailio/modules/mohqueue.so)
> ERROR: error while initializing modules
>
>
> Any help is appreciated,
>
> Thanks!
>
> --
> DVG
>
> --
> Imagination is more important than knowledge
> Albert Einstein
>
> ___
> SIP Express Router (SER) and Kamailio (OpenSER) - sr-users mailing list
> sr-users@lists.sip-router.org
> http://lists.sip-router.org/cgi-bin/mailman/listinfo/sr-users
>
>
___
SIP Express Router (SER) and Kamailio (OpenSER) - sr-users mailing list
sr-users@lists.sip-router.org
http://lists.sip-router.org/cgi-bin/mailman/listinfo/sr-users


Re: [SR-Users] Examples

2015-11-06 Thread SamyGo
Hi Ryan,
Where are your trunks !?

if your provider can just send calls to your IP address then just do IP
based authentication in Kamailio and once provider is authenticated relay
the call to the Internal PBX.
so with reference to the code here:
http://kb.asipto.com/asterisk:realtime:kamailio-4.0.x-asterisk-11.3.0-astdb
I will try to guide you.

1 - allow IP AUTHENTICATION by adding line
#define WITH_IPAUTH
after the line saying "#define WITH_AUTH"

2 - Put the IP address plus port of the provider in "permission" database
table and restart Kamailio (for first time only) for next time you make
changes in that table execute this command
Linux:~#kamctl address reload

3 - Now everytime your provider sends a call it will be accepted BUT the
call still needs to be routed to the internal PBX.

4 - since WITH_ASTERISK is defined on top as well so Kamailio will check
the IP address of your internal PBX from this:

asterisk.bindip = "192.168.178.25" desc "Asterisk IP Address"
asterisk.bindport = "5080" desc "Asterisk Port"

If you want to have a different criteria to route call to internal PBX like
Load-Balancing or decide based on DID the calls goes to  a specific server,
or based on accound it routes to a specific PBX then thats your logic and
should be handled inside the route[TOASTERISK] - similarly
route[FROMASTERISK] needs changes to allow calls coming back from Internal
PBXs.


I hope it just gives you some idea of what to do next.


Regards,
Sammy





On Fri, Nov 6, 2015 at 12:25 PM, Ryan Holbein  wrote:

> Hello,
>
>
> I have everything setup and installed... Does anyone have a good link or
> could tell me the steps of how to connect my trunks to phone provider and
> then another one would be how to route the calls to the internal PBX system.
>
>
>
> Thank you
>
> ___
> SIP Express Router (SER) and Kamailio (OpenSER) - sr-users mailing list
> sr-users@lists.sip-router.org
> http://lists.sip-router.org/cgi-bin/mailman/listinfo/sr-users
>
>
___
SIP Express Router (SER) and Kamailio (OpenSER) - sr-users mailing list
sr-users@lists.sip-router.org
http://lists.sip-router.org/cgi-bin/mailman/listinfo/sr-users


Re: [SR-Users] host for pstn.gw

2015-11-02 Thread SamyGo
Hey Max,

You should know that pstn.gw_ip is not a keyword in Kamailio and it
could've been pstn.lol_gw or anything. What really matters is that you know
where this gw_ip is being used in configuration.
Somewhere in the kamailio.cfg you'll see a PSTN route which will be doing
some RURI checks and then checking is pstn.gw_ip is not empty, and after
that it just modifies the RURI to contain this variable "pstn.gw_ip" value
in the Request Domain part so when t_relay() is called the call exits out
to that IP or Host.

You should search up on kamailio about DNS hostname auto-resolution and if
your provider has DNS SRV working how Kamailio will work with it.

Regards,
Sammy


On Mon, Nov 2, 2015 at 8:05 AM, Max 
wrote:

> Hi.
>
> I'd like to use Kamailio as a SIP proxy routing calls to upstream SIP
> provider.
> As far as I've understood the parameters I should set are:
>
> pstn.gw_ip = "" desc "PSTN GW Address"
> pstn.gw_port = "" desc "PSTN GW Port"
>
> The problem is that my upstream provider uses dynamic IP for its server.
> How can I
> use hostname instead of ip.
>
> From what I see in route[PSTN] example it seems like it should just work
> if I use
> pstn.gw_ip = "sip.myprovider.lol" desc "My upstream SIP host"
>
> But if so - why the confusing name? And if not - how do I make it work? Is
> there
> pstn.gw_host or smth like that?
>
> regards,
> Max.
>
> ___
> SIP Express Router (SER) and Kamailio (OpenSER) - sr-users mailing list
> sr-users@lists.sip-router.org
> http://lists.sip-router.org/cgi-bin/mailman/listinfo/sr-users
>
___
SIP Express Router (SER) and Kamailio (OpenSER) - sr-users mailing list
sr-users@lists.sip-router.org
http://lists.sip-router.org/cgi-bin/mailman/listinfo/sr-users


Re: [SR-Users] MSILO module

2015-10-21 Thread SamyGo
That means save the psuedo variable $mb (read wiki) using the SQLops module
to save the messages using sql_query()

Msilo supports saving and retrieving for offline users and hence I couldnt
figure out how I can permanently save msg history for users and hence did
it manually as mentioned above.

Maybe an easier function exists for this somewhere or an efficient approach
exists. Thats just how I did it.

Regards,
Sam
On Oct 21, 2015 10:30 AM, "Safdar Khan" <safdarkhan.k...@gmail.com> wrote:

> Hi Sam,
>
> Will u please elaborate.Means from where to start.
>
> Safdar.
>
> On Wed, Oct 21, 2015 at 6:29 PM, SamyGo <govoi...@gmail.com> wrote:
>
>> Hi Safdar,
>>
>> The way I did was save the $mb variable in db when the Method is MESSAGE.
>>
>> Regards,
>> Sam
>> On Oct 21, 2015 8:09 AM, "Safdar Khan" <safdarkhan.k...@gmail.com> wrote:
>>
>>> How can i store messages in silo table not only offline also online.Demo
>>> code will be appreciated.waiting for response.
>>>
>>> ___
>>> SIP Express Router (SER) and Kamailio (OpenSER) - sr-users mailing list
>>> sr-users@lists.sip-router.org
>>> http://lists.sip-router.org/cgi-bin/mailman/listinfo/sr-users
>>>
>>>
>> ___
>> SIP Express Router (SER) and Kamailio (OpenSER) - sr-users mailing list
>> sr-users@lists.sip-router.org
>> http://lists.sip-router.org/cgi-bin/mailman/listinfo/sr-users
>>
>>
>
> ___
> SIP Express Router (SER) and Kamailio (OpenSER) - sr-users mailing list
> sr-users@lists.sip-router.org
> http://lists.sip-router.org/cgi-bin/mailman/listinfo/sr-users
>
>
___
SIP Express Router (SER) and Kamailio (OpenSER) - sr-users mailing list
sr-users@lists.sip-router.org
http://lists.sip-router.org/cgi-bin/mailman/listinfo/sr-users


Re: [SR-Users] MSILO module

2015-10-21 Thread SamyGo
Hi Safdar,

The way I did was save the $mb variable in db when the Method is MESSAGE.

Regards,
Sam
On Oct 21, 2015 8:09 AM, "Safdar Khan"  wrote:

> How can i store messages in silo table not only offline also online.Demo
> code will be appreciated.waiting for response.
>
> ___
> SIP Express Router (SER) and Kamailio (OpenSER) - sr-users mailing list
> sr-users@lists.sip-router.org
> http://lists.sip-router.org/cgi-bin/mailman/listinfo/sr-users
>
>
___
SIP Express Router (SER) and Kamailio (OpenSER) - sr-users mailing list
sr-users@lists.sip-router.org
http://lists.sip-router.org/cgi-bin/mailman/listinfo/sr-users


Re: [SR-Users] Kamailio is not forwarding the call to asterisk

2015-10-03 Thread SamyGo
Hi,
The way youve described it seems like you are not routing anything at all
to the asterisk. It all depends on your comfiguration on how you handled
the call. Somehow Ive a feeling that asterisk is used only for voicemail
and is called only once the B party is not found in lookup(location)
function. Some cfg file snippet of your can help everyone understand the
real cause.

Regards,
Sammy
On Oct 3, 2015 3:01 AM, "amjad ali"  wrote:

> Hi,
>
> I have kamailio and asterisk running on same machine. When I make an
> internal call, it routes the call to other extension. However, if I stop
> the asterisk service then the call still routes the same way to other
> extension. Is there a chance that kamailio does the call routing it self.
>
> Also, I cannot see any sip extension registered at asterisk when I run a
> command "Sip show peers" neither there is any activity in Asterisk's log.
>
> Regards,
> Amjad
>
> ___
> SIP Express Router (SER) and Kamailio (OpenSER) - sr-users mailing list
> sr-users@lists.sip-router.org
> http://lists.sip-router.org/cgi-bin/mailman/listinfo/sr-users
>
>
___
SIP Express Router (SER) and Kamailio (OpenSER) - sr-users mailing list
sr-users@lists.sip-router.org
http://lists.sip-router.org/cgi-bin/mailman/listinfo/sr-users


Re: [SR-Users] Changed the bindport of Kamailio but still listening to older port

2015-10-03 Thread SamyGo
The kamailio.bindport is not used for the purpose here.
To change the listen port modify the parameter "Listen" or "port"
On Oct 3, 2015 3:01 AM, "amjad ali"  wrote:

> Hi,
>
> I am scratching my head for one month to get this sorted and I have spent
> so many hours but couldn't figure out. Please help !
>
> I have changed the bind port to 5099 but it is still listening to the
> previous port even I have rebooted the system.
>
> My Code is :
>
> kamailio.bindip = "192.168.1.105" desc  "Kamailio IP Address"
> kamailio.bindport = "5099" desc "kamailio port"
>
> However, when I restart kamailio service it shows that it is still
> listening to 5060 (attached the screen shot)
>
> Regards,
> Amjad
>
> ___
> SIP Express Router (SER) and Kamailio (OpenSER) - sr-users mailing list
> sr-users@lists.sip-router.org
> http://lists.sip-router.org/cgi-bin/mailman/listinfo/sr-users
>
>
___
SIP Express Router (SER) and Kamailio (OpenSER) - sr-users mailing list
sr-users@lists.sip-router.org
http://lists.sip-router.org/cgi-bin/mailman/listinfo/sr-users


Re: [SR-Users] Kamailio crash [receive_fd: EOF on 19]

2015-09-08 Thread SamyGo
Hi Daniel,

Thanks a ton for replying, please see the attached full trace.
Please note the Public IPs have been masked.

Best Regards,
Sammy

On Tue, Sep 8, 2015 at 3:01 PM, Daniel-Constantin Mierla <mico...@gmail.com>
wrote:

> Hello,
>
> can you give the output of 'bt full' in gdb to see where it actually
> crashed?
>
> Cheers,
> Daniel
>
>
> On 08/09/15 20:20, SamyGo wrote:
>
> Hi,
>
> I'm randomly getting crash in my Kamailio with an error in log files like
> this:
>
>  [pass_fd.c:293]: receive_fd(): ERROR: receive_fd: EOF on 19
> ALERT:  [main.c:775]: handle_sigs(): child process 6853 exited by a
> signal 11
> ALERT:  [main.c:778]: handle_sigs(): core was generated
> INFO:  [main.c:790]: handle_sigs(): INFO: terminating due to SIGCHLD
>
>
>
>
> *Version of Kamailio is: *
> [root@kamailio /]#kamailio  -V
> version: kamailio 4.1.4 (x86_64/linux) 39adca
> flags: STATS: Off, USE_TCP, USE_TLS, TLS_HOOKS, USE_RAW_SOCKS,
> DISABLE_NAGLE, USE_MCAST, DNS_IP_HACK, SHM_MEM, SHM_MMAP, PKG_MALLOC,
> DBG_QM_MALLOC, USE_FUTEX, FAST_LOCK-ADAPTIVE_WAIT, USE_DNS_CACHE,
> USE_DNS_FAILOVER, USE_NAPTR, USE_DST_BLACKLIST, HAVE_RESOLV_RES
> ADAPTIVE_WAIT_LOOPS=1024, MAX_RECV_BUFFER_SIZE 262144, MAX_LISTEN 16,
> MAX_URI_SIZE 1024, BUF_SIZE 65535, DEFAULT PKG_SIZE 4MB
> poll method support: poll, epoll_lt, epoll_et, sigio_rt, select.
> id: 39adca
> compiled on 03:48:50 Aug  1 2014 with gcc 4.4.7
>
> And gdb bt output is attached in text file.
>
> One thing out that is common in all the previous core files is this:
>
> #12 0x004a54ab in receive_msg (
> buf=0x924600 "INVITE sip:+17036833500@14.131.165.9:5073
> SIP/2.0\r\nVia: SIP/2.0/UDP 
> 14.55.2.43:5060;branch=z9hG4bK0eB8f68591a19b9b8f0\r\nFrom:
> \"Anonymous\" <sip:Anonymous@Anonymous.invalid>;tag=gK0e13e132\r\nTo: <
> sip:+170"..., len=1018, rcv_info=0x7fff3dbee970) at receive.c:212
> #13 0x0053c9a8 in udp_rcv_loop () at udp_server.c:536
>
>
> Does this mean that Kamailio can't understand the From Domain:
> Anonymous.invalid and hence crashes ?
>
> Thanks,
> Sammy
>
>
>
>
>
>
> ___
> SIP Express Router (SER) and Kamailio (OpenSER) - sr-users mailing 
> listsr-us...@lists.sip-router.orghttp://lists.sip-router.org/cgi-bin/mailman/listinfo/sr-users
>
>
> --
> Daniel-Constantin Mierlahttp://twitter.com/#!/miconda - 
> http://www.linkedin.com/in/miconda
> Book: SIP Routing With Kamailio - http://www.asipto.com
> Kamailio Advanced Training, Sep 28-30, 2015, in Berlin - 
> http://asipto.com/u/kat
>
>
> ___
> SIP Express Router (SER) and Kamailio (OpenSER) - sr-users mailing list
> sr-users@lists.sip-router.org
> http://lists.sip-router.org/cgi-bin/mailman/listinfo/sr-users
>
>
(gdb) bt full
#0  0x7f4d4dbc7ba9 in destroy_dlg_callbacks_list (cb=0x353a6d6f) at 
dlg_cb.c:77
cb_t = 0x7f4d49549650
__FUNCTION__ = "destroy_dlg_callbacks_list"
#1  0x7f4d4dbdc249 in destroy_dlg (dlg=0x7f4d4943e058) at dlg_hash.c:375
ret = 1
var = 0x7f4d5469df78
__FUNCTION__ = "destroy_dlg"
#2  0x7f4d4dbdf635 in dlg_unref (dlg=0x7f4d4943e058, cnt=1) at 
dlg_hash.c:812
d_entry = 0x7f4d4907cd30
__FUNCTION__ = "dlg_unref"
#3  0x7f4d4dbdf696 in dlg_release (dlg=0x7f4d4943e058) at dlg_hash.c:826
No locals.
#4  0x7f4d4dbd4e08 in dlg_new_dialog (req=0x7f4d5468fcc8, t=0x0, 
run_initial_cbs=1) at dlg_handlers.c:883
dlg = 0x7f4d4943e058
s = {s = 0x7f4d4de08490 "", len = 0}
callid = {
  s = 0x9246ee "420399357_104871319@14.55.2.43\r\nCSeq: 6068 
INVITE\r\nMax-Forwards: 67\r\nAllow: 
INVITE,ACK,CANCEL,BYE,REFER,SUBSCRIBE,PRACK,UPDATE\r\nAccept: application/sdp, 
application/isup, application/dtmf, application"..., len = 30}
ftag = {
  s = 0x9246af "gK0e13e132\r\nTo: 
<sip:+17036833500@14.131.165.9:5073>\r\nCall-ID: 
420399357_104871319@14.55.2.43\r\nCSeq: 6068 INVITE\r\nMax-Forwards: 
67\r\nAllow: INVITE,ACK,CANCEL,BYE,REFER,SUBSCRIBE,PRACK,UPDATE\r\nAccept: 
a"..., len = 10}
ttag = {s = 0x0, len = 0}
req_uri = {s = 0x7f4d54497068 "sip:+17036833500@14.131.165.9:5073", len 
= 34}
dir = 0
__FUNCTION__ = "dlg_new_dialog"
#5  0x7f4d4dbd9209 in dlg_manage (msg=0x7f4d5468fcc8) at dlg_handlers.c:1517
tag = {s = 0x0, len = 0}
backup_mode = 32589
dlg = 0x0
t = 0x0
__FUNCTION__ = "dlg_manage"
#6  0x7f4d4dbc34cb in w_dlg_manage (msg=0x7f4d5468fcc8, s1=0x0, s2=0x0) at 
dialog.c:1006
No locals.
#7  0x00419ad1 in do_action (h=0x7fff3

Re: [SR-Users] Kamailio crash [receive_fd: EOF on 19]

2015-09-08 Thread SamyGo
Thanks Daniel for pointing out, so if I upgrade my Kamailio it should all
go away , right. Will do a version upgrade and check similar calls.

I've seen very similar crashes EOF on 11, EOF of 16 etc etc in few other
situations as well, while at once such occasion it was an invalid kamctl
command and it crashed kamailio(Another thread maybe)

If Kamailio crashing before it can even get some route started then we
can't perform sanity checks and hence even if I've DNS SRV, LinuxHA, or
anything the caller might keep trying call over and again and keep crashing
the whole layer :)



On Tue, Sep 8, 2015 at 3:46 PM, Daniel-Constantin Mierla <mico...@gmail.com>
wrote:

> Hello,
>
> looks like there were updates to dialog modules in 4.1 after 4.1.4. The
> code lines do not match the back trace.
>
> You should upgrade to latest version in 4.1 branch -- there is no change
> that you have to do in kamailio.cfg or database.
>
> Meanwhile, we can see the relevant pieces of code from your specific
> version with following commands in gdb:
>
> frame 0
> list
>
> frame 4
> list
>
> Cheers,
> Daniel
>
>
> On 08/09/15 21:12, SamyGo wrote:
>
> Hi Daniel,
>
> Thanks a ton for replying, please see the attached full trace.
> Please note the Public IPs have been masked.
>
> Best Regards,
> Sammy
>
> On Tue, Sep 8, 2015 at 3:01 PM, Daniel-Constantin Mierla <
> <mico...@gmail.com>mico...@gmail.com> wrote:
>
>> Hello,
>>
>> can you give the output of 'bt full' in gdb to see where it actually
>> crashed?
>>
>> Cheers,
>> Daniel
>>
>>
>> On 08/09/15 20:20, SamyGo wrote:
>>
>> Hi,
>>
>> I'm randomly getting crash in my Kamailio with an error in log files like
>> this:
>>
>>  [pass_fd.c:293]: receive_fd(): ERROR: receive_fd: EOF on 19
>> ALERT:  [main.c:775]: handle_sigs(): child process 6853 exited by a
>> signal 11
>> ALERT:  [main.c:778]: handle_sigs(): core was generated
>> INFO:  [main.c:790]: handle_sigs(): INFO: terminating due to SIGCHLD
>>
>>
>>
>>
>> *Version of Kamailio is: *
>> [root@kamailio /]#kamailio  -V
>> version: kamailio 4.1.4 (x86_64/linux) 39adca
>> flags: STATS: Off, USE_TCP, USE_TLS, TLS_HOOKS, USE_RAW_SOCKS,
>> DISABLE_NAGLE, USE_MCAST, DNS_IP_HACK, SHM_MEM, SHM_MMAP, PKG_MALLOC,
>> DBG_QM_MALLOC, USE_FUTEX, FAST_LOCK-ADAPTIVE_WAIT, USE_DNS_CACHE,
>> USE_DNS_FAILOVER, USE_NAPTR, USE_DST_BLACKLIST, HAVE_RESOLV_RES
>> ADAPTIVE_WAIT_LOOPS=1024, MAX_RECV_BUFFER_SIZE 262144, MAX_LISTEN 16,
>> MAX_URI_SIZE 1024, BUF_SIZE 65535, DEFAULT PKG_SIZE 4MB
>> poll method support: poll, epoll_lt, epoll_et, sigio_rt, select.
>> id: 39adca
>> compiled on 03:48:50 Aug  1 2014 with gcc 4.4.7
>>
>> And gdb bt output is attached in text file.
>>
>> One thing out that is common in all the previous core files is this:
>>
>> #12 0x004a54ab in receive_msg (
>> buf=0x924600 "INVITE <http://sip:+17036833500@14.131.165.9:5073>
>> sip:+17036833500@14.131.165.9:5073 SIP/2.0\r\nVia: SIP/2.0/UDP
>> 14.55.2.43:5060;branch=z9hG4bK0eB8f68591a19b9b8f0\r\nFrom: \"Anonymous\"
>> <sip:Anonymous@Anonymous.invalid>;tag=gK0e13e132\r\nTo: <sip:+170"...,
>> len=1018, rcv_info=0x7fff3dbee970) at receive.c:212
>> #13 0x0053c9a8 in udp_rcv_loop () at udp_server.c:536
>>
>>
>> Does this mean that Kamailio can't understand the From Domain:
>> Anonymous.invalid and hence crashes ?
>>
>> Thanks,
>> Sammy
>>
>>
>>
>>
>>
>>
>> ___
>> SIP Express Router (SER) and Kamailio (OpenSER) - sr-users mailing 
>> listsr-us...@lists.sip-router.orghttp://lists.sip-router.org/cgi-bin/mailman/listinfo/sr-users
>>
>>
>> --
>> Daniel-Constantin Mierlahttp://twitter.com/#!/miconda - 
>> http://www.linkedin.com/in/miconda
>> Book: SIP Routing With Kamailio - http://www.asipto.com
>> Kamailio Advanced Training, Sep 28-30, 2015, in Berlin - 
>> http://asipto.com/u/kat
>>
>>
>> ___
>> SIP Express Router (SER) and Kamailio (OpenSER) - sr-users mailing list
>> sr-users@lists.sip-router.org
>> http://lists.sip-router.org/cgi-bin/mailman/listinfo/sr-users
>>
>>
>
> --
> Daniel-Constantin Mierlahttp://twitter.com/#!/miconda - 
> http://www.linkedin.com/in/miconda
> Book: SIP Routing With Kamailio - http://www.asipto.com
> Kamailio Advanced Training, Sep 28-30, 2015, in Berlin - 
> http://asipto.com/u/kat
>
>
___
SIP Express Router (SER) and Kamailio (OpenSER) - sr-users mailing list
sr-users@lists.sip-router.org
http://lists.sip-router.org/cgi-bin/mailman/listinfo/sr-users


Re: [SR-Users] Kamailio crash [receive_fd: EOF on 19]

2015-09-08 Thread SamyGo
Here is the output from gdp for fram 0 and 4.


(gdb) frame 0
#0  0x7f4d4dbc7ba9 in destroy_dlg_callbacks_list
(cb=0x353a6d6f) at dlg_cb.c:77
77  cb_t->callback_param_free(cb_t->param);
(gdb) list
72
73  while(cb) {
74  cb_t = cb;
75  cb = cb->next;
76  if (cb_t->callback_param_free && cb_t->param) {
77  cb_t->callback_param_free(cb_t->param);
78  cb_t->param = NULL;
79  }
80  shm_free(cb_t);
81  }
(gdb) frame 4
#4  0x7f4d4dbd4e08 in dlg_new_dialog (req=0x7f4d5468fcc8, t=0x0,
run_initial_cbs=1) at dlg_handlers.c:883
883 dlg_release(dlg);
(gdb) list
878
879 finish:
880 _dlg_ctx.iuid.h_entry = dlg->h_entry;
881 _dlg_ctx.iuid.h_id = dlg->h_id;
882 set_current_dialog(req, dlg);
883 dlg_release(dlg);
884
885 return 0;
886
887 error:
(gdb)


On Tue, Sep 8, 2015 at 4:44 PM, SamyGo <govoi...@gmail.com> wrote:

> Thanks Daniel for pointing out, so if I upgrade my Kamailio it should all
> go away , right. Will do a version upgrade and check similar calls.
>
> I've seen very similar crashes EOF on 11, EOF of 16 etc etc in few other
> situations as well, while at once such occasion it was an invalid kamctl
> command and it crashed kamailio(Another thread maybe)
>
> If Kamailio crashing before it can even get some route started then we
> can't perform sanity checks and hence even if I've DNS SRV, LinuxHA, or
> anything the caller might keep trying call over and again and keep crashing
> the whole layer :)
>
>
>
> On Tue, Sep 8, 2015 at 3:46 PM, Daniel-Constantin Mierla <
> mico...@gmail.com> wrote:
>
>> Hello,
>>
>> looks like there were updates to dialog modules in 4.1 after 4.1.4. The
>> code lines do not match the back trace.
>>
>> You should upgrade to latest version in 4.1 branch -- there is no change
>> that you have to do in kamailio.cfg or database.
>>
>> Meanwhile, we can see the relevant pieces of code from your specific
>> version with following commands in gdb:
>>
>> frame 0
>> list
>>
>> frame 4
>> list
>>
>> Cheers,
>> Daniel
>>
>>
>> On 08/09/15 21:12, SamyGo wrote:
>>
>> Hi Daniel,
>>
>> Thanks a ton for replying, please see the attached full trace.
>> Please note the Public IPs have been masked.
>>
>> Best Regards,
>> Sammy
>>
>> On Tue, Sep 8, 2015 at 3:01 PM, Daniel-Constantin Mierla <
>> <mico...@gmail.com>mico...@gmail.com> wrote:
>>
>>> Hello,
>>>
>>> can you give the output of 'bt full' in gdb to see where it actually
>>> crashed?
>>>
>>> Cheers,
>>> Daniel
>>>
>>>
>>> On 08/09/15 20:20, SamyGo wrote:
>>>
>>> Hi,
>>>
>>> I'm randomly getting crash in my Kamailio with an error in log files
>>> like this:
>>>
>>>  [pass_fd.c:293]: receive_fd(): ERROR: receive_fd: EOF on 19
>>> ALERT:  [main.c:775]: handle_sigs(): child process 6853 exited by
>>> a signal 11
>>> ALERT:  [main.c:778]: handle_sigs(): core was generated
>>> INFO:  [main.c:790]: handle_sigs(): INFO: terminating due to
>>> SIGCHLD
>>>
>>>
>>>
>>>
>>> *Version of Kamailio is: *
>>> [root@kamailio /]#kamailio  -V
>>> version: kamailio 4.1.4 (x86_64/linux) 39adca
>>> flags: STATS: Off, USE_TCP, USE_TLS, TLS_HOOKS, USE_RAW_SOCKS,
>>> DISABLE_NAGLE, USE_MCAST, DNS_IP_HACK, SHM_MEM, SHM_MMAP, PKG_MALLOC,
>>> DBG_QM_MALLOC, USE_FUTEX, FAST_LOCK-ADAPTIVE_WAIT, USE_DNS_CACHE,
>>> USE_DNS_FAILOVER, USE_NAPTR, USE_DST_BLACKLIST, HAVE_RESOLV_RES
>>> ADAPTIVE_WAIT_LOOPS=1024, MAX_RECV_BUFFER_SIZE 262144, MAX_LISTEN 16,
>>> MAX_URI_SIZE 1024, BUF_SIZE 65535, DEFAULT PKG_SIZE 4MB
>>> poll method support: poll, epoll_lt, epoll_et, sigio_rt, select.
>>> id: 39adca
>>> compiled on 03:48:50 Aug  1 2014 with gcc 4.4.7
>>>
>>> And gdb bt output is attached in text file.
>>>
>>> One thing out that is common in all the previous core files is this:
>>>
>>> #12 0x004a54ab in receive_msg (
>>> buf=0x924600 "INVITE <http://sip:+17036833500@14.131.165.9:5073>
>>> sip:+17036833500@14.131.165.9:5073 SIP/2.0\r\nVia: SIP/2.0/UDP
>>> 14.55.2.43:5060;branch=z9hG4bK0eB8f68591a19b9b8f0\r\nFrom:
>>> \"Anonymous\" &

[SR-Users] Kamailio crash [receive_fd: EOF on 19]

2015-09-08 Thread SamyGo
Hi,

I'm randomly getting crash in my Kamailio with an error in log files like
this:

 [pass_fd.c:293]: receive_fd(): ERROR: receive_fd: EOF on 19
ALERT:  [main.c:775]: handle_sigs(): child process 6853 exited by a
signal 11
ALERT:  [main.c:778]: handle_sigs(): core was generated
INFO:  [main.c:790]: handle_sigs(): INFO: terminating due to SIGCHLD




*Version of Kamailio is:*
[root@kamailio /]#kamailio  -V
version: kamailio 4.1.4 (x86_64/linux) 39adca
flags: STATS: Off, USE_TCP, USE_TLS, TLS_HOOKS, USE_RAW_SOCKS,
DISABLE_NAGLE, USE_MCAST, DNS_IP_HACK, SHM_MEM, SHM_MMAP, PKG_MALLOC,
DBG_QM_MALLOC, USE_FUTEX, FAST_LOCK-ADAPTIVE_WAIT, USE_DNS_CACHE,
USE_DNS_FAILOVER, USE_NAPTR, USE_DST_BLACKLIST, HAVE_RESOLV_RES
ADAPTIVE_WAIT_LOOPS=1024, MAX_RECV_BUFFER_SIZE 262144, MAX_LISTEN 16,
MAX_URI_SIZE 1024, BUF_SIZE 65535, DEFAULT PKG_SIZE 4MB
poll method support: poll, epoll_lt, epoll_et, sigio_rt, select.
id: 39adca
compiled on 03:48:50 Aug  1 2014 with gcc 4.4.7

And gdb bt output is attached in text file.

One thing out that is common in all the previous core files is this:

#12 0x004a54ab in receive_msg (
buf=0x924600 "INVITE sip:+17036833500@14.131.165.9:5073 SIP/2.0\r\nVia:
SIP/2.0/UDP 14.55.2.43:5060;branch=z9hG4bK0eB8f68591a19b9b8f0\r\nFrom:
\"Anonymous\" ;tag=gK0e13e132\r\nTo:

This is free software: you are free to change and redistribute it.
There is NO WARRANTY, to the extent permitted by law.  Type "show copying"
and "show warranty" for details.
This GDB was configured as "x86_64-redhat-linux-gnu".
For bug reporting instructions, please see:
...
Reading symbols from /usr/local/sbin/kamailio...done.
[New Thread 6853]
Missing separate debuginfo for /usr/local/lib64/kamailio/modules/db_mysql.so
Try: yum --enablerepo='*-debug*' install 
/usr/lib/debug/.build-id/bf/d435ef13d96d7dd6d04b10489c229197e9358d
Missing separate debuginfo for /usr/local/lib64/kamailio/libsrdb2.so.1
Try: yum --enablerepo='*-debug*' install 
/usr/lib/debug/.build-id/82/f945a31523b4c602a5bc72354651899b152f80
Missing separate debuginfo for /usr/local/lib64/kamailio/libsrdb1.so.1
Try: yum --enablerepo='*-debug*' install 
/usr/lib/debug/.build-id/84/588e9ccaa7b0552fd931a3c1dafee181a2ee52
Missing separate debuginfo for /usr/local/lib64/kamailio/modules/ndb_redis.so
Try: yum --enablerepo='*-debug*' install 
/usr/lib/debug/.build-id/ee/e67a7b3b09f7ed3b2b587c6be5821e50c0f03c
Missing separate debuginfo for /usr/local/lib64/kamailio/libkcore.so.1
Try: yum --enablerepo='*-debug*' install 
/usr/lib/debug/.build-id/80/f71bdc2aac64f6f1a80d2ef0d9eefecca2d1de
Missing separate debuginfo for /usr/local/lib64/kamailio/modules/avpops.so
Try: yum --enablerepo='*-debug*' install 
/usr/lib/debug/.build-id/79/5237aa2893c0e60be81f7234640861313f8348
Missing separate debuginfo for /usr/local/lib64/kamailio/modules/ipops.so
Try: yum --enablerepo='*-debug*' install 
/usr/lib/debug/.build-id/b3/f99f6b53d1faa868aeb1739356202dddb377f4
Missing separate debuginfo for /usr/local/lib64/kamailio/modules/mi_fifo.so
Try: yum --enablerepo='*-debug*' install 
/usr/lib/debug/.build-id/eb/22511803678db5ab3956fc1661064d9eeac39c
Missing separate debuginfo for /usr/local/lib64/kamailio/libkmi.so.1
Try: yum --enablerepo='*-debug*' install 
/usr/lib/debug/.build-id/f7/c103397c0ffe267918081af378d20f32999875
Missing separate debuginfo for /usr/local/lib64/kamailio/modules/kex.so
Try: yum --enablerepo='*-debug*' install 
/usr/lib/debug/.build-id/e1/0576e978af8ef4101aed2c693d039e32a2a3be
Missing separate debuginfo for /usr/local/lib64/kamailio/libsrutils.so.1
Try: yum --enablerepo='*-debug*' install 
/usr/lib/debug/.build-id/d1/be84809832ced72fce2675feae1fe77973ee74
Missing separate debuginfo for /usr/local/lib64/kamailio/modules/tm.so
Try: yum --enablerepo='*-debug*' install 
/usr/lib/debug/.build-id/2a/9baef8d43c7d041afa826291a58b1571009773
Missing separate debuginfo for /usr/local/lib64/kamailio/modules/tmx.so
Try: yum --enablerepo='*-debug*' install 
/usr/lib/debug/.build-id/15/4b30f1f7701a53400b3ae0e558502e995baebc
Missing separate debuginfo for /usr/local/lib64/kamailio/modules/sl.so
Try: yum --enablerepo='*-debug*' install 
/usr/lib/debug/.build-id/93/012c8c19d9303d867f3b2e8a74eeef834b120c
Missing separate debuginfo for /usr/local/lib64/kamailio/modules/rr.so
Try: yum --enablerepo='*-debug*' install 
/usr/lib/debug/.build-id/24/bf68aa13817f1d01ca9da7ce44a620996f4bdc
Missing separate debuginfo for 

Re: [SR-Users] multiple proxies

2015-08-27 Thread SamyGo
Hi Bruce,
Get some ideas from here:
http://www.opentelecom.it/cluecon/ClueCon_2015_Load_Balancing_HA.pdf
Also using DNS SRV is a good idea for use afront of multiple active proxies.

BR,
Sammy
On Aug 27, 2015 1:53 PM, Bruce Lefko blefko5...@gmail.com wrote:

 If I want to have multiple kamailio proxies in front of multiple media
 servers, can I balance them using plain old DNS behind a domain name?  If I
 wanted a specific proxy to be notified about an entire SIP dialog I could
 set the record route to use the public IP of the proxy that received the
 initial INVITE.

 Could I leverage something like route53 tcp healthchecks to know if I
 should be failing over to another proxy?

 ___
 SIP Express Router (SER) and Kamailio (OpenSER) - sr-users mailing list
 sr-users@lists.sip-router.org
 http://lists.sip-router.org/cgi-bin/mailman/listinfo/sr-users


___
SIP Express Router (SER) and Kamailio (OpenSER) - sr-users mailing list
sr-users@lists.sip-router.org
http://lists.sip-router.org/cgi-bin/mailman/listinfo/sr-users


Re: [SR-Users] Change ports for outgoing RTP packets in RTPproxy

2015-08-19 Thread SamyGo
Hi Jean,
Can you further explain your question, the steps you mentioend are already
handled by kamailio's module rtpproxy. Now, you mentioned change the SDP in
kamailio before rtpproxy function is calledI wonder how the device
would feel about it.
For example UA sent and INVITE/SDP saying I'm listening on port 54321 ; you
modify it to 12345 in kamailio and then call manage_rtpproxy() function.
After 200OK RTPproxy will try to send RTPs to 12345 port but nothing may be
possibly there ?!

Kindly explain the whole scenario.

BR,
Sammy


On Wed, Aug 19, 2015 at 8:28 AM, Jean-Marie Baran jean-marie.ba...@ama.bzh
wrote:

 Hi,

 Is there a way to change the ports were RTPproxy sends outgoing packets ?
 By rewriting the SDP before it gets to RTPproxy, or anything else ?

 1 - Kamailio receives the SDP
 2 - It somehow transmits the contact information to RTPproxy (ip + ports)
 3 - The client start sending packets to RTPproxy which in turn relays them
 to the contact

 How to change the ports in step 2 ?

 Sincerely,
 --
 *Jean-Marie Baran*

 ___
 SIP Express Router (SER) and Kamailio (OpenSER) - sr-users mailing list
 sr-users@lists.sip-router.org
 http://lists.sip-router.org/cgi-bin/mailman/listinfo/sr-users


___
SIP Express Router (SER) and Kamailio (OpenSER) - sr-users mailing list
sr-users@lists.sip-router.org
http://lists.sip-router.org/cgi-bin/mailman/listinfo/sr-users


Re: [SR-Users] need help with RTPProxy in bridged mode

2015-08-13 Thread SamyGo
Hi,
Try starting rtpprpxy with a / in between the two IP addresses.
For example -l 1.1.1.1/2.2.2.2
Besides that it depends where you are placing your rtpproxy function.

BR,
Sammy
On Aug 13, 2015 8:36 AM, Grant Bagdasarian g...@cm.nl wrote:

 Hello,



 I’m using RTPproxy for the first time in bridged mode and I can’t get
 kamailio/rtpproxy to rewrite the c parameter to the correct public ip
 address of kamailio.



 The setup is as following:



 Carrier --[fiber]-- Kamailio -[lan]- Freeswitch



 Kamailio is listening on two interfaces:

 1)  Private: 172.0.0.1

 2)  Public: 192.168.0.1 (since we have a dedicated fiber with our
 carrier, this is its public address)



 Freeswitch is listening on:

 1)  172.0.0.2



 Carrier is on:

 1)  10.0.0.1



 I’ve started an rtpproxy instance on the Kamailio box using:

 rtpproxy -s udp:127.0.0.1:7721 -u rtpproxy rtpproxy -p
 /var/run/rtpproxy/rtpproxy.pid -l 192.168.0.1 172.0.0.1



 I’ve played around with rtpproxy_manage() and the various flags (ie, ei),
 but I can’t get kamailio to set the correct public IP when the 200 OK has
 to be sent back to the carrier.

 It always sets it to its private address, instead of its public address.



 I’m using Kamailio 4.2 with sippy/rtpproxy 2.0.



 Could someone please point me into the right direction?



 Thanks!



 Grant



 ___
 SIP Express Router (SER) and Kamailio (OpenSER) - sr-users mailing list
 sr-users@lists.sip-router.org
 http://lists.sip-router.org/cgi-bin/mailman/listinfo/sr-users


___
SIP Express Router (SER) and Kamailio (OpenSER) - sr-users mailing list
sr-users@lists.sip-router.org
http://lists.sip-router.org/cgi-bin/mailman/listinfo/sr-users


Re: [SR-Users] need help with RTPProxy in bridged mode

2015-08-13 Thread SamyGo
Good to know that your issue is resolved. I see you're applying only one
rtpproxy command, possibly your's only need incoming calls from carrier.
Also in BYE you need to use unforce_rtpproxy function to release ports.

Same solution can have many solutions; I'll share how mine works, for the
sake of finding any expert advise to do it better way.

Carrier --[fiber]-- Kamailio -[lan]-{LoadBalanced
Freeswitch Servers}

Carrier IP is IP-AUTHENTICATED, add the ip in the address table, use
permission module.
FreeSwitch IP(s) are added in the dispatcher table, use dispatcher module.

Then RTPProxy is engaged in NATMANAGE Route

route[NATMANAGE] {
#!ifdef WITH_NAT
if (is_request()) {
if(has_totag()) {
if(check_route_param(nat=yes)) {
setbflag(FLB_NATB);
}
}
}
if (!(isflagset(FLT_NATS) || isbflagset(FLB_NATB)))
return;

if(ds_is_from_list()){  #Put outgoing condition here i.e From
internal side to external IPs.
rtpproxy_manage(ei);  #the sequence of flags depends on
how rtpproxy started 1.1.1.1/2.2.2.2 or 2.2.2.2/1.1.1.1
}else{  #Usually inverse of the above condition i.e
From outside world to internal
rtpproxy_manage(ie);  # You can use any other flasg as well, cawrie
  }

if (is_request()) {
if (!has_totag()) {
add_rr_param(;nat=yes);
}
}
if (is_reply()) {
if(isbflagset(FLB_NATB)) {
fix_nated_contact();
}
}
#!endif
return;
}


From your main route for a particular flow if you want rtpproxy to be
forced all you need to do is set the flag: FLT_NATS

*Example: *

Incoming IP Authenticated carrier always need to engage rtpproxy since it
will end up in the LAN MediaServer pool.

#!ifdef WITH_IPAUTH
if((!is_method(REGISTER))  allow_source_address())
{
xlog(L_INFO, [$fU@$si:$sp][$ru]{$rm}  ROUTE AUTH:: Source IP Allowed
for Inbound SIP/PSTN Carrier \n);
setflag(FLT_NATS);
return;
}
#!endif

I hope this either help alot of other ppl or get me some better advise on
how to improve.


Best Regards,
Sammy
Blog: http://saevolgo.blogspot.com




On Thu, Aug 13, 2015 at 10:10 AM, Grant Bagdasarian g...@cm.nl wrote:

 It’s working!

 Thank you very much!!



 *From:* sr-users [mailto:sr-users-boun...@lists.sip-router.org] *On
 Behalf Of *Waite, Hugh
 *Sent:* Thursday, August 13, 2015 4:02 PM
 *To:* Kamailio (SER) - Users Mailing List sr-users@lists.sip-router.org

 *Subject:* Re: [SR-Users] need help with RTPProxy in bridged mode



 Hi,

 If the media is coming from a different IP address than the signalling,
 you may need to use the ‘r’ flag to force the address in the SDP to be
 trusted.

 You should also use the same flags in the same order, in the on-reply
 route. (This is all in
 http://kamailio.org/docs/modules/4.3.x/modules/rtpproxy.html#idp1616)

 rtpproxy_manage(“eir”);



 In the withindlg route, you don’t need to specify the ei/ie direction, but
 you will need to pass the ‘r’ flag.



 Regards,

 Hugh



 *From:* sr-users [mailto:sr-users-boun...@lists.sip-router.org
 sr-users-boun...@lists.sip-router.org] *On Behalf Of *Grant Bagdasarian
 *Sent:* 13 August 2015 14:50
 *To:* SIP Router - Kamailio (OpenSER) and SIP Express Router (SER) -
 Users Mailing List
 *Subject:* Re: [SR-Users] need help with RTPProxy in bridged mode



 Hello,



 Yeah, I also noticed I forgot the / . Now the SDP c parameter is set
 correctly, but the audio from private to public isn’t relayed by rtpproxy.



 I ran a tcp dump on both interfaces (private and public), and it showed me
 RTP is being received from Freeswitch and also from our carrier, but
 nothing is passed between the two interfaces by rtpproxy. Any ideas?



 Below a slim version of my config:



 Request_route {



 if (is_method(INVITE)) {

record_route();

if (has_body(application/sdp)) {

rtpproxy_offer(ei);

}

 }



 }

 onreply_route[MANAGE_REPLY] {

 if (has_body(application/sdp)) {

rtpproxy_answer(ie);

 }

 }



 route[WITHINDLG] {

 if (!has_totag()) return;

 if (loose_route()) {

if(is_method(BYE)) {

rtpproxy_manage();

}

route(RELAY);

exit;

 }

 }



 *From:* sr-users [mailto:sr-users-boun...@lists.sip-router.org
 sr-users-boun...@lists.sip-router.org] *On Behalf Of *SamyGo
 *Sent:* Thursday, August 13, 2015 3:26 PM
 *To:* SIP Router - Kamailio (OpenSER) and SIP Express Router (SER) -
 Users Mailing List sr-users@lists.sip-router.org
 *Subject:* Re: [SR-Users] need help with RTPProxy in bridged mode



 Hi,
 Try starting rtpprpxy with a / in between the two IP addresses.
 For example -l 1.1.1.1/2.2.2.2
 Besides

Re: [SR-Users] kamailio as SIP Agent

2015-08-11 Thread SamyGo
 calculated: 3d26b7732e22874c5837c971c8ec76cd
  8(1186) DEBUG: tm [t_lookup.c:1072]: t_check_msg(): DEBUG: t_check_msg:
 msg id=2 global id=2 T start=0xb5d3f20c
  8(1186) DEBUG: tm [t_lookup.c:1144]: t_check_msg(): DEBUG: t_check_msg: T
 already found!
  8(1186) DEBUG: core [msg_translator.c:205]: check_via_address():
 check_via_address(172.22.14.17, 172.22.14.17, 0)
  8(1186) DEBUG: core [mem/shm_mem.c:111]: _shm_resize():
 WARNING:vqm_resize: resize(0) called
  8(1186) DEBUG: tm [t_reply.c:1653]: cleanup_uac_timers(): DEBUG:
 cleanup_uac_timers: RETR/FR timers reset
  8(1186) DEBUG: tm [t_hooks.c:288]: run_trans_callbacks_internal(): DBG:
 trans=0xb5d3f20c, callback type 512, id 0 entered
  8(1186) DEBUG: acc [acc_logic.c:571]: tmcb_func(): acc callback called
 for t(0xb5d3f20c) event type 512, reply code 404
  8(1186) DEBUG: tm [t_reply.c:728]: _reply_light(): DEBUG: reply sent out.
 buf=0xb7bb8030: *SIP/2.0 404 Not Foun.*.., shmem=0xb5d40cdc: SIP/2.0 404
 Not Foun
  8(1186) DEBUG: tm [t_reply.c:738]: _reply_light(): DEBUG: _reply_light:
 finished
  8(1186) DEBUG: sl [sl.c:288]: send_reply(): reply in stateful mode (tm)

 ++








 Warm Regards,
 Sandeep Chakravarthi.

 On Thu, Jul 30, 2015 at 6:35 PM, SamyGo govoi...@gmail.com wrote:

 Below is output from the dispatcher table, Set-2 is a pool of asterisk
 servers to be Load balanced, and Set-1 is the Telco IP.

 KAMSBC01:~# kamctl dispatcher dump
 SET_NO:: 2
 *SET:: 2 *
 URI:: sip:192.168.0.150:5050 flags=AP priority=1 attrs=
 URI:: sip:192.168.0.151:5060 flags=AP priority=1 attrs=
 URI:: sip:192.168.0.152:5070 flags=AP priority=1 attrs=
 URI:: sip:192.168.0.153:5080 flags=AP priority=1 attrs=
 URI:: sip:192.168.0.155:5090 flags=AP priority=1 attrs=
 *SET:: 1*
 URI:: sip:124.311.201.600:5060 flags=AP priority=1 attrs=

 Now in my kamailio.cfg in relevant route

 if(ds_is_from_list
 http://kamailio.org/docs/modules/4.3.x/modules/dispatcher.html#dispatcher.f.ds_is_from_list(1))
 {
 #Call from Telco Should goto Asterisk pool in Loadbalanced mode
  if(!ds_select_dst(2, 4)) {
 sl_send_reply(500, Service Unavailable);
 xlog(L_INFO,[$fU@$si:$sp]{$rm} No
 destinations available for $rd \n);
 exit;
 }
 } else if (ds_is_from_list(2)) {
 #Call from Asterisk servers pool, send it to telco using LoadBalancer
 if(!ds_select_dst(1, 4)) {
 sl_send_reply(500, Service Unavailable);
 xlog(L_INFO,[$fU@$si:$sp]{$rm} No
 destinations available for $rd \n);
 exit;
 }
 }


 So if your Telco has more than 1 IP you can do Load balancing.

 I hope this solves your problem.


 Best Regards,
 Sammy



 On Thu, Jul 30, 2015 at 3:17 AM, Sandeep Chakravarthi 
 ivschakravar...@gmail.com wrote:

 Hi,

 Can you share the sample code to differentiate the both telco IP and our
 server IP?

 .



 Warm Regards,
 Sandeep Chakravarthi.

 On Tue, Jul 14, 2015 at 10:55 PM, SamyGo govoi...@gmail.com wrote:

 Sure but if you look into the dispatcher module there is a field called
 'setid' or groupid. Use it wisely to differentiate between the Load
 Balanced asterisk pool and the Telco IP.
 The dispatcher module is exactly what you should use. You can find out
 if incoming source IP belongs to a particular set in dispatcher table thus
 you can tell if call is coming from Telco or from your Asterisks.
 You can select the dispatcher set for load balancing but if we only
 have one IP in there then it gets all the load.

 BR,
 Sammy


 On Tue, Jul 14, 2015 at 1:21 PM, Sandeep Chakravarthi 
 ivschakravar...@gmail.com wrote:

 Hi,
 Thanks for the immediate reply.

 You are right ,using the dispatcher module , i am able to send the
 OPTIONS packet to MSC Telco.

 But as i describer in  my earlier mail, i am using the same dispatcher
 module to establish the sip trunk  between my My Kamailio server and my
 Asterisk server.

 There is a table in the database with the name dispatcher.
 Now, in that table i have 2 records
 one is my Telco SIP IP and the other is Asterisk PBX IP.

 But as per my understanding from the google, dispatcher module is used
 for load balancing between the servers

 Telco SIP server will be sending the calls to Kamailio and Kamailio
 has to distribute completely to Asterisk server instead of distributing 
 the
 calls between Telco SIP IP and Asterisk.


 Please help with it.




 Warm Regards,
 Sandeep Chakravarthi.

 On Tue, Jul 14, 2015 at 10:28 PM, SamyGo govoi...@gmail.com wrote:

 Hi,
 You're right about using IP Auth in Kamailio. You'll need to use the
 permissions module. However I believe permissions module wont send the
 OPTIONS to the MSC SIP Server. For this you may alternatively use the
 dispatcher module.

 Take a look at the sample kamailio.cfg here:
 http

Re: [SR-Users] kamailio as SIP Agent

2015-08-11 Thread SamyGo
Thats because your configuration file is not sending packet out (RELAY) to
MSC instead it is only doing a Loadbalancer / destination lookup in
TOASTERISK route and comes out of it, processes the following routes in
order
  route(SIPOUT);
  route(PRESENCE);
  route(REGISTRAR);
  route(PSTN);
  route(LOCATION);

Where finally in LOCATION route it tries to find the destination user
0730092190 online locally on Kamailio, which it can't find and says 404 Not
Found.

You should modify your TOASTERISK route as follow:

route[TOASTERISK] {
if(ds_is_from_list(2)) {
#Call from Telco Should goto Asterisk pool in Loadbalanced mode
 if(!ds_select_dst(1, 4)) {
sl_send_reply(500, Service Unavailable);
xlog(L_INFO,[$fU@$si:$sp]{$rm} No destinations
available for $rd \n);
exit;
}
route(RELAY);
}if(ds_is_from_list(1)) {
#Call from Asterisk servers pool, send it to telco using LoadBalancer
if(!ds_select_dst(2, 4)) {
sl_send_reply(500, Service Unavailable);
xlog(L_INFO,[$fU@$si:$sp]{$rm} No destinations
available for $rd \n);
exit;
}
route(RELAY);
 }

}


This will immediately route the packet out towards the new $du after the
loadbalancer function ds_select_dst(...)


On Tue, Aug 11, 2015 at 10:48 AM, Sandeep Chakravarthi 
ivschakravar...@gmail.com wrote:

 Hi,
 Kamailio  is sending 404 Response and its not MSC.
 If you see the pcap file , Kamailio has to forward the SIP invite packet
 to MSC which it got from Asterisk server. But it is not happening.
 I am attaching the pcap one more time for your reference.

 In my pcap, below are the server details

 172.22.14.12 - Kamailio server
 172.22.14.17 - Asterisk server
 172.22.0.68 - MSC


 Regards,
 Sandeep

 Warm Regards,
 Sandeep Chakravarthi.

 On Tue, Aug 11, 2015 at 7:10 PM, SamyGo govoi...@gmail.com wrote:

 Hi Sandeep,
 what is the problem here ? Kamailio just sends a 404 on its own or is
 really sending calls to MSC and MSC is replying with 404 ?


 On Mon, Aug 10, 2015 at 12:33 PM, Sandeep Chakravarthi 
 ivschakravar...@gmail.com wrote:

 Hi ,
 Sorry for the delayed reply.
 I have configured my Asterisk and kamailio server, but when i initiate
 one outbound call from my asterisk server to kamailio server, kamailio
 server is initiating the call to MSC.
 Please find the attached pcap details for your reference.
 Below is my kamailio debug log and kamailio.cfg file.
 Please check the pcap and below cfg file and log file and let me know
 whether to change anything in cfg file or not.

 


 request_route {

 # per request initial checks
 route(REQINIT);

 # NAT detection
 route(NATDETECT);

 # CANCEL processing
 if (is_method(CANCEL))
 {
 if (t_check_trans()) {
 route(RELAY);
 }
 exit;
 }

 # handle requests within SIP dialogs
 route(WITHINDLG);

 ### only initial requests (no To tag)

 t_check_trans();

 # authentication
 route(AUTH);


 # record routing for dialog forming requests (in case they are
 routed)
 # - remove preloaded route headers
 remove_hf(Route);
 if (is_method(INVITE|SUBSCRIBE))
 record_route();

 # account only INVITEs
 if (is_method(INVITE))
 {
 setflag(FLT_ACC); # do accounting
 }
 route(TOASTERISK);

 # dispatch requests to foreign domains
 route(SIPOUT);

 ### requests for my local domains

 # handle presence related requests
 route(PRESENCE);

 # handle registrations
 route(REGISTRAR);

 if ($rU==$null)
 {
 # request with no Username in RURI
 sl_send_reply(484,Address Incomplete);
 exit;
 }

 # dispatch destinations to PSTN
 route(PSTN);
 # user location service
 route(LOCATION);
 }

 route[TOASTERISK] {
 if(ds_is_from_list(2)) {
 #Call from Telco Should goto Asterisk pool in Loadbalanced mode
  if(!ds_select_dst(1, 4)) {
 sl_send_reply(500, Service Unavailable);
 xlog(L_INFO,[$fU@$si:$sp]{$rm} No
 destinations available for $rd \n);
 exit;
 }
 }if(ds_is_from_list(1)) {
 #Call from Asterisk servers pool, send it to telco using LoadBalancer
 if(!ds_select_dst(2, 4)) {
 sl_send_reply(500, Service Unavailable);
 xlog(L_INFO,[$fU@$si:$sp]{$rm} No
 destinations available for $rd \n);
 exit

Re: [SR-Users] kamailio as SIP Agent

2015-08-11 Thread SamyGo
1 - Take a look at the Kamailio transformations and psuedo-variable page.
 change the $td to the IP of the MSC; modify the $ru as $rU + @
172.22.12.100:5060 where this is IP of MSC side.
2 - Wireshark guys could've said it SIP-3 - point is it doesnt matter at
this point since you know your MSC is replying back and talking to you.



On Tue, Aug 11, 2015 at 1:16 PM, Sandeep Chakravarthi 
ivschakravar...@gmail.com wrote:

 Yes, You are right and done the changes as you suggested.

 Kamailio server is forwarding the call to MSC. But two issues are there.
 1 .In the INVITE packet which is being sent from kamailio server to MSC,
 it is coming Request-Line: INVITE sip:0730092190@*172.22.14.12*
That is my kamailio server IP and it should be MSC IP(172.28.0.68) and
 as of now call is failing as MSC is sending 404 error.
 2. Other issue is , in the pcap file it is coming SIP/SDP as protocol and
 it is not coming SIP-I.

 Please find the latest attached pcap.

 Regards,
 Sandeep


 Warm Regards,
 Sandeep Chakravarthi.

 On Tue, Aug 11, 2015 at 9:47 PM, SamyGo govoi...@gmail.com wrote:

 Thats because your configuration file is not sending packet out (RELAY)
 to MSC instead it is only doing a Loadbalancer / destination lookup in
 TOASTERISK route and comes out of it, processes the following routes in
 order
   route(SIPOUT);
   route(PRESENCE);
   route(REGISTRAR);
   route(PSTN);
   route(LOCATION);

 Where finally in LOCATION route it tries to find the destination user
 0730092190 online locally on Kamailio, which it can't find and says 404 Not
 Found.

 You should modify your TOASTERISK route as follow:

 route[TOASTERISK] {
 if(ds_is_from_list(2)) {
 #Call from Telco Should goto Asterisk pool in Loadbalanced mode
  if(!ds_select_dst(1, 4)) {
 sl_send_reply(500, Service Unavailable);
 xlog(L_INFO,[$fU@$si:$sp]{$rm} No
 destinations available for $rd \n);
 exit;
 }
 route(RELAY);
 }if(ds_is_from_list(1)) {
 #Call from Asterisk servers pool, send it to telco using LoadBalancer
 if(!ds_select_dst(2, 4)) {
 sl_send_reply(500, Service Unavailable);
 xlog(L_INFO,[$fU@$si:$sp]{$rm} No
 destinations available for $rd \n);
 exit;
 }
 route(RELAY);
  }

 }


 This will immediately route the packet out towards the new $du after the
 loadbalancer function ds_select_dst(...)


 On Tue, Aug 11, 2015 at 10:48 AM, Sandeep Chakravarthi 
 ivschakravar...@gmail.com wrote:

 Hi,
 Kamailio  is sending 404 Response and its not MSC.
 If you see the pcap file , Kamailio has to forward the SIP invite packet
 to MSC which it got from Asterisk server. But it is not happening.
 I am attaching the pcap one more time for your reference.

 In my pcap, below are the server details

 172.22.14.12 - Kamailio server
 172.22.14.17 - Asterisk server
 172.22.0.68 - MSC


 Regards,
 Sandeep

 Warm Regards,
 Sandeep Chakravarthi.

 On Tue, Aug 11, 2015 at 7:10 PM, SamyGo govoi...@gmail.com wrote:

 Hi Sandeep,
 what is the problem here ? Kamailio just sends a 404 on its own or is
 really sending calls to MSC and MSC is replying with 404 ?


 On Mon, Aug 10, 2015 at 12:33 PM, Sandeep Chakravarthi 
 ivschakravar...@gmail.com wrote:

 Hi ,
 Sorry for the delayed reply.
 I have configured my Asterisk and kamailio server, but when i initiate
 one outbound call from my asterisk server to kamailio server, kamailio
 server is initiating the call to MSC.
 Please find the attached pcap details for your reference.
 Below is my kamailio debug log and kamailio.cfg file.
 Please check the pcap and below cfg file and log file and let me know
 whether to change anything in cfg file or not.

 


 request_route {

 # per request initial checks
 route(REQINIT);

 # NAT detection
 route(NATDETECT);

 # CANCEL processing
 if (is_method(CANCEL))
 {
 if (t_check_trans()) {
 route(RELAY);
 }
 exit;
 }

 # handle requests within SIP dialogs
 route(WITHINDLG);

 ### only initial requests (no To tag)

 t_check_trans();

 # authentication
 route(AUTH);


 # record routing for dialog forming requests (in case they are
 routed)
 # - remove preloaded route headers
 remove_hf(Route);
 if (is_method(INVITE|SUBSCRIBE))
 record_route();

 # account only INVITEs
 if (is_method(INVITE))
 {
 setflag(FLT_ACC); # do accounting
 }
 route(TOASTERISK);

 # dispatch requests to foreign domains
 route(SIPOUT);

 ### requests for my local domains

 # handle presence related requests

[SR-Users] Kamailio crash when imc_list_rooms

2015-08-08 Thread SamyGo
Hi,
I'm working with IMC module and noticed that when I execute fifo command
imc_list_rooms it crashes.

[root@kamailio75 ]# kamctl fifo imc_list_rooms

my Kamailio version is 4.2.1

Right now the way IMC module works is that a SIP UA has to send a chat room
command to create a new room, get participants added etc. If I try to add
users directly from DB the kamailio don't recognize the room or
participants unless restart. Would it be possible to reload the DB tables
for IMC via MI command, a big plus if we can do room creation, user
addition via MI as well !

Thanks,
Sammy
___
SIP Express Router (SER) and Kamailio (OpenSER) - sr-users mailing list
sr-users@lists.sip-router.org
http://lists.sip-router.org/cgi-bin/mailman/listinfo/sr-users


Re: [SR-Users] MSILO: Archiving every message

2015-08-03 Thread SamyGo
Thanks Daniel for pointing out.

On Mon, Aug 3, 2015 at 6:30 AM, Daniel-Constantin Mierla mico...@gmail.com
wrote:

 Hello,

 On 01/08/15 16:03, SamyGo wrote:
  Hi,
 
  Tried finding anything as weird as I am trying to do on mailing list
  but couldn't. The idea is to save a copy of the messages on database.
 
  MSILO module can keep the message as long as the destination user is
  offline, or doesn't support method:MESSAGE or expiry timeout.
 
 
 I haven't really gotten the last phrase -- is there an issue or what
 exactly doesn't support.

 If you want to keep a copy of the stored message, you can try to do some
 tricks at the database layer, to store in another table -- e.g., using
 triggers.

 With kamailio, perhaps there is not going to be a big patch to msilo
 that instead of deleting the records, to mark them as delivered.

 Cheers,
 Daniel

 --
 Daniel-Constantin Mierla
 http://twitter.com/#!/miconda - http://www.linkedin.com/in/miconda
 Book: SIP Routing With Kamailio - http://www.asipto.com


 ___
 SIP Express Router (SER) and Kamailio (OpenSER) - sr-users mailing list
 sr-users@lists.sip-router.org
 http://lists.sip-router.org/cgi-bin/mailman/listinfo/sr-users

___
SIP Express Router (SER) and Kamailio (OpenSER) - sr-users mailing list
sr-users@lists.sip-router.org
http://lists.sip-router.org/cgi-bin/mailman/listinfo/sr-users


[SR-Users] MSILO: Archiving every message

2015-08-01 Thread SamyGo
Hi,

Tried finding anything as weird as I am trying to do on mailing list but
couldn't. The idea is to save a copy of the messages on database.

MSILO module can keep the message as long as the destination user is
offline, or doesn't support method:MESSAGE or expiry timeout.

Any ideas will be appreciated.

Best Regards,
Sammy
___
SIP Express Router (SER) and Kamailio (OpenSER) - sr-users mailing list
sr-users@lists.sip-router.org
http://lists.sip-router.org/cgi-bin/mailman/listinfo/sr-users


Re: [SR-Users] kamailio as SIP Agent

2015-07-30 Thread SamyGo
Below is output from the dispatcher table, Set-2 is a pool of asterisk
servers to be Load balanced, and Set-1 is the Telco IP.

KAMSBC01:~# kamctl dispatcher dump
SET_NO:: 2
*SET:: 2 *
URI:: sip:192.168.0.150:5050 flags=AP priority=1 attrs=
URI:: sip:192.168.0.151:5060 flags=AP priority=1 attrs=
URI:: sip:192.168.0.152:5070 flags=AP priority=1 attrs=
URI:: sip:192.168.0.153:5080 flags=AP priority=1 attrs=
URI:: sip:192.168.0.155:5090 flags=AP priority=1 attrs=
*SET:: 1*
URI:: sip:124.311.201.600:5060 flags=AP priority=1 attrs=

Now in my kamailio.cfg in relevant route

if(ds_is_from_list
http://kamailio.org/docs/modules/4.3.x/modules/dispatcher.html#dispatcher.f.ds_is_from_list(1))
{
#Call from Telco Should goto Asterisk pool in Loadbalanced mode
 if(!ds_select_dst(2, 4)) {
sl_send_reply(500, Service Unavailable);
xlog(L_INFO,[$fU@$si:$sp]{$rm} No destinations
available for $rd \n);
exit;
}
} else if (ds_is_from_list(2)) {
#Call from Asterisk servers pool, send it to telco using LoadBalancer
if(!ds_select_dst(1, 4)) {
sl_send_reply(500, Service Unavailable);
xlog(L_INFO,[$fU@$si:$sp]{$rm} No destinations
available for $rd \n);
exit;
}
}


So if your Telco has more than 1 IP you can do Load balancing.

I hope this solves your problem.


Best Regards,
Sammy



On Thu, Jul 30, 2015 at 3:17 AM, Sandeep Chakravarthi 
ivschakravar...@gmail.com wrote:

 Hi,

 Can you share the sample code to differentiate the both telco IP and our
 server IP?

 .



 Warm Regards,
 Sandeep Chakravarthi.

 On Tue, Jul 14, 2015 at 10:55 PM, SamyGo govoi...@gmail.com wrote:

 Sure but if you look into the dispatcher module there is a field called
 'setid' or groupid. Use it wisely to differentiate between the Load
 Balanced asterisk pool and the Telco IP.
 The dispatcher module is exactly what you should use. You can find out if
 incoming source IP belongs to a particular set in dispatcher table thus you
 can tell if call is coming from Telco or from your Asterisks.
 You can select the dispatcher set for load balancing but if we only have
 one IP in there then it gets all the load.

 BR,
 Sammy


 On Tue, Jul 14, 2015 at 1:21 PM, Sandeep Chakravarthi 
 ivschakravar...@gmail.com wrote:

 Hi,
 Thanks for the immediate reply.

 You are right ,using the dispatcher module , i am able to send the
 OPTIONS packet to MSC Telco.

 But as i describer in  my earlier mail, i am using the same dispatcher
 module to establish the sip trunk  between my My Kamailio server and my
 Asterisk server.

 There is a table in the database with the name dispatcher.
 Now, in that table i have 2 records
 one is my Telco SIP IP and the other is Asterisk PBX IP.

 But as per my understanding from the google, dispatcher module is used
 for load balancing between the servers

 Telco SIP server will be sending the calls to Kamailio and Kamailio has
 to distribute completely to Asterisk server instead of distributing the
 calls between Telco SIP IP and Asterisk.


 Please help with it.




 Warm Regards,
 Sandeep Chakravarthi.

 On Tue, Jul 14, 2015 at 10:28 PM, SamyGo govoi...@gmail.com wrote:

 Hi,
 You're right about using IP Auth in Kamailio. You'll need to use the
 permissions module. However I believe permissions module wont send the
 OPTIONS to the MSC SIP Server. For this you may alternatively use the
 dispatcher module.

 Take a look at the sample kamailio.cfg here:
 http://kb.asipto.com/asterisk:realtime:kamailio-4.0.x-asterisk-11.3.0-astdb

 Follow the tag WITH_IPAUTH and I'm sure you'll be able to implement it
 easily.

 BR,
 Sammy

 On Tue, Jul 14, 2015 at 12:51 PM, Sandeep Chakravarthi 
 ivschakravar...@gmail.com wrote:


 Hi,
 We have a requirement with one of our telco
 We are using asterisk in our servers and we are planning to implement
 SIP-I protocol and we choosed kamailio for it.

 In Kamailio website, i came to know that kamailio will be supporting
 both SIP-I and SIP-T protocols

 Below is what we need and pls confirm whether it is possible or not?

 Asterisk PBX --- Kamailio  Telco MSC


 Telco will be forwarding the calls to kamailio on sip-i protocol and
 kamailio server has to forward the calls to our Asterisk server by
 converting sip-i to standard sip protocol

 Similiarly Asterisk will be initiating sip call to kamailio server and
 kamailio server should convert it into SIP-I and should forward the call 
 to
 Telco MSC


 1.  I am able to establish the SIP trunk [sending OPTIONS from
 asterisk and kamailio acknowledges with 200 OK] between Asterisk and
 Kamailio using dispatcher module in kamailio and sip.conf in asterisk.

 How to establish the SIP trunk between kamailio and telco MSC?
 [Generally MSC will act as SIP server and kamalio should send OPTIONS
 packet

Re: [SR-Users] kamailio as SIP Agent

2015-07-14 Thread SamyGo
Hi,
You're right about using IP Auth in Kamailio. You'll need to use the
permissions module. However I believe permissions module wont send the
OPTIONS to the MSC SIP Server. For this you may alternatively use the
dispatcher module.

Take a look at the sample kamailio.cfg here:
http://kb.asipto.com/asterisk:realtime:kamailio-4.0.x-asterisk-11.3.0-astdb

Follow the tag WITH_IPAUTH and I'm sure you'll be able to implement it
easily.

BR,
Sammy

On Tue, Jul 14, 2015 at 12:51 PM, Sandeep Chakravarthi 
ivschakravar...@gmail.com wrote:


 Hi,
 We have a requirement with one of our telco
 We are using asterisk in our servers and we are planning to implement
 SIP-I protocol and we choosed kamailio for it.

 In Kamailio website, i came to know that kamailio will be supporting both
 SIP-I and SIP-T protocols

 Below is what we need and pls confirm whether it is possible or not?

 Asterisk PBX --- Kamailio  Telco MSC


 Telco will be forwarding the calls to kamailio on sip-i protocol and
 kamailio server has to forward the calls to our Asterisk server by
 converting sip-i to standard sip protocol

 Similiarly Asterisk will be initiating sip call to kamailio server and
 kamailio server should convert it into SIP-I and should forward the call to
 Telco MSC


 1.  I am able to establish the SIP trunk [sending OPTIONS from asterisk
 and kamailio acknowledges with 200 OK] between Asterisk and Kamailio using
 dispatcher module in kamailio and sip.conf in asterisk.

 How to establish the SIP trunk between kamailio and telco MSC?
 [Generally MSC will act as SIP server and kamalio should send OPTIONS
 packet and MSC will acknowledges with 200 OK]


 My telco MSC has only provided me the MSC SIP IP and there were no
 username/passwords provided.
 Means i need to use IP based authentication for the SIP Trunk
 establishment.

 In Kamailio how to achieve it?

 Please help and any suggestions/feedback will be highly appreciated and
 thankful


 Regards,
 Sandeep

 ___
 SIP Express Router (SER) and Kamailio (OpenSER) - sr-users mailing list
 sr-users@lists.sip-router.org
 http://lists.sip-router.org/cgi-bin/mailman/listinfo/sr-users


___
SIP Express Router (SER) and Kamailio (OpenSER) - sr-users mailing list
sr-users@lists.sip-router.org
http://lists.sip-router.org/cgi-bin/mailman/listinfo/sr-users


Re: [SR-Users] kamailio as SIP Agent

2015-07-14 Thread SamyGo
Sure but if you look into the dispatcher module there is a field called
'setid' or groupid. Use it wisely to differentiate between the Load
Balanced asterisk pool and the Telco IP.
The dispatcher module is exactly what you should use. You can find out if
incoming source IP belongs to a particular set in dispatcher table thus you
can tell if call is coming from Telco or from your Asterisks.
You can select the dispatcher set for load balancing but if we only have
one IP in there then it gets all the load.

BR,
Sammy


On Tue, Jul 14, 2015 at 1:21 PM, Sandeep Chakravarthi 
ivschakravar...@gmail.com wrote:

 Hi,
 Thanks for the immediate reply.

 You are right ,using the dispatcher module , i am able to send the OPTIONS
 packet to MSC Telco.

 But as i describer in  my earlier mail, i am using the same dispatcher
 module to establish the sip trunk  between my My Kamailio server and my
 Asterisk server.

 There is a table in the database with the name dispatcher.
 Now, in that table i have 2 records
 one is my Telco SIP IP and the other is Asterisk PBX IP.

 But as per my understanding from the google, dispatcher module is used for
 load balancing between the servers

 Telco SIP server will be sending the calls to Kamailio and Kamailio has to
 distribute completely to Asterisk server instead of distributing the calls
 between Telco SIP IP and Asterisk.


 Please help with it.




 Warm Regards,
 Sandeep Chakravarthi.

 On Tue, Jul 14, 2015 at 10:28 PM, SamyGo govoi...@gmail.com wrote:

 Hi,
 You're right about using IP Auth in Kamailio. You'll need to use the
 permissions module. However I believe permissions module wont send the
 OPTIONS to the MSC SIP Server. For this you may alternatively use the
 dispatcher module.

 Take a look at the sample kamailio.cfg here:
 http://kb.asipto.com/asterisk:realtime:kamailio-4.0.x-asterisk-11.3.0-astdb

 Follow the tag WITH_IPAUTH and I'm sure you'll be able to implement it
 easily.

 BR,
 Sammy

 On Tue, Jul 14, 2015 at 12:51 PM, Sandeep Chakravarthi 
 ivschakravar...@gmail.com wrote:


 Hi,
 We have a requirement with one of our telco
 We are using asterisk in our servers and we are planning to implement
 SIP-I protocol and we choosed kamailio for it.

 In Kamailio website, i came to know that kamailio will be supporting
 both SIP-I and SIP-T protocols

 Below is what we need and pls confirm whether it is possible or not?

 Asterisk PBX --- Kamailio  Telco MSC


 Telco will be forwarding the calls to kamailio on sip-i protocol and
 kamailio server has to forward the calls to our Asterisk server by
 converting sip-i to standard sip protocol

 Similiarly Asterisk will be initiating sip call to kamailio server and
 kamailio server should convert it into SIP-I and should forward the call to
 Telco MSC


 1.  I am able to establish the SIP trunk [sending OPTIONS from asterisk
 and kamailio acknowledges with 200 OK] between Asterisk and Kamailio using
 dispatcher module in kamailio and sip.conf in asterisk.

 How to establish the SIP trunk between kamailio and telco MSC?
 [Generally MSC will act as SIP server and kamalio should send OPTIONS
 packet and MSC will acknowledges with 200 OK]


 My telco MSC has only provided me the MSC SIP IP and there were no
 username/passwords provided.
 Means i need to use IP based authentication for the SIP Trunk
 establishment.

 In Kamailio how to achieve it?

 Please help and any suggestions/feedback will be highly appreciated and
 thankful


 Regards,
 Sandeep

 ___
 SIP Express Router (SER) and Kamailio (OpenSER) - sr-users mailing list
 sr-users@lists.sip-router.org
 http://lists.sip-router.org/cgi-bin/mailman/listinfo/sr-users



 ___
 SIP Express Router (SER) and Kamailio (OpenSER) - sr-users mailing list
 sr-users@lists.sip-router.org
 http://lists.sip-router.org/cgi-bin/mailman/listinfo/sr-users



 ___
 SIP Express Router (SER) and Kamailio (OpenSER) - sr-users mailing list
 sr-users@lists.sip-router.org
 http://lists.sip-router.org/cgi-bin/mailman/listinfo/sr-users


___
SIP Express Router (SER) and Kamailio (OpenSER) - sr-users mailing list
sr-users@lists.sip-router.org
http://lists.sip-router.org/cgi-bin/mailman/listinfo/sr-users


Re: [SR-Users] HA+DRBD setup

2015-07-09 Thread SamyGo
I believe thats the configuration you've done via 'crm' to monitor for 3
crashes (by default probably) - that means if you kill it it will try start
the monitored application on the same node first and if fails in 3 attempts
only then goes to the secondary site. (try inducing an error in
kamailio.cfg file and then killing the kamailio)

Now using a VIP or not is your choice.

I can only assume that you want to monitor the Kamailio service and if
failed launch it on the secondary server that's all. If that's the case
then you don't need to define any FAILOVER-IP

You need to read more on configuring via the crm command to change this
behaviour.

Here is an old blog post I wrote on this:
http://saevolgo.blogspot.ca/2013/05/opensipskamailio-high-availability.html

Probably the reference link can help you for more detailed explanation.

BR,
Sammy



On Thu, Jul 9, 2015 at 6:24 AM, solution solution...@gmail.com wrote:

 i am not using anycast.


 On Thu, Jul 9, 2015 at 1:06 PM, Loic Chabert [via SIP Router] [hidden
 email] http:///user/SendEmail.jtp?type=nodenode=139441i=0 wrote:

 OK, and could you use anycast routing ?
 Your HA could be done with BGP using communities and bgp localpref.

 One restriction to bgp anycast routing: your network should be stable (to
 preserve transaction and sip dialog).

 Regards.

 2015-07-08 14:02 GMT+02:00 solution [hidden email]
 http:///user/SendEmail.jtp?type=nodenode=139436i=0:

 we dont want to use VIP

 On Wed, Jul 8, 2015 at 5:31 PM, Loic Chabert [via SIP Router] [hidden
 email] http:///user/SendEmail.jtp?type=nodenode=139418i=0 wrote:

 Hello,

 For failover IP, why could not use keepalived ? With a script
 monitoring, you can switch vip from one host to another easily.

 More simple than corosync etc in my opinion.

 Regards.
 Loïc.
 Le 8 juil. 2015 13:49, Fred Posner [hidden email]
 http:///user/SendEmail.jtp?type=nodenode=139416i=0 a écrit :



 On 07/08/2015 12:31 AM, solution wrote:
  but while i manually killing that application fail over switching is
 not
  happening.

 Are there any errors?

 --fred

 ___
 SIP Express Router (SER) and Kamailio (OpenSER) - sr-users mailing list
 [hidden email] http:///user/SendEmail.jtp?type=nodenode=139416i=1
 http://lists.sip-router.org/cgi-bin/mailman/listinfo/sr-users


 ___
 SIP Express Router (SER) and Kamailio (OpenSER) - sr-users mailing list
 [hidden email] http:///user/SendEmail.jtp?type=nodenode=139416i=2
 http://lists.sip-router.org/cgi-bin/mailman/listinfo/sr-users


 --
  If you reply to this email, your message will be added to the
 discussion below:

 http://sip-router.1086192.n5.nabble.com/HA-DRBD-setup-tp22576p139416.html
  To unsubscribe from HA+DRBD setup, click here.
 NAML
 http://sip-router.1086192.n5.nabble.com/template/NamlServlet.jtp?macro=macro_viewerid=instant_html%21nabble%3Aemail.namlbase=nabble.naml.namespaces.BasicNamespace-nabble.view.web.template.NabbleNamespace-nabble.view.web.template.NodeNamespacebreadcrumbs=notify_subscribers%21nabble%3Aemail.naml-instant_emails%21nabble%3Aemail.naml-send_instant_email%21nabble%3Aemail.naml



 --
 View this message in context: Re: HA+DRBD setup
 http://sip-router.1086192.n5.nabble.com/HA-DRBD-setup-tp22576p139418.html
 Sent from the Users mailing list archive
 http://sip-router.1086192.n5.nabble.com/Users-f3.html at Nabble.com.

 ___
 SIP Express Router (SER) and Kamailio (OpenSER) - sr-users mailing list
 [hidden email] http:///user/SendEmail.jtp?type=nodenode=139436i=1
 http://lists.sip-router.org/cgi-bin/mailman/listinfo/sr-users



 ___
 SIP Express Router (SER) and Kamailio (OpenSER) - sr-users mailing list
 [hidden email] http:///user/SendEmail.jtp?type=nodenode=139436i=2
 http://lists.sip-router.org/cgi-bin/mailman/listinfo/sr-users


 --
  If you reply to this email, your message will be added to the
 discussion below:
 http://sip-router.1086192.n5.nabble.com/HA-DRBD-setup-tp22576p139436.html
  To unsubscribe from HA+DRBD setup, click here.
 NAML
 http://sip-router.1086192.n5.nabble.com/template/NamlServlet.jtp?macro=macro_viewerid=instant_html%21nabble%3Aemail.namlbase=nabble.naml.namespaces.BasicNamespace-nabble.view.web.template.NabbleNamespace-nabble.view.web.template.NodeNamespacebreadcrumbs=notify_subscribers%21nabble%3Aemail.naml-instant_emails%21nabble%3Aemail.naml-send_instant_email%21nabble%3Aemail.naml



 --
 View this message in context: Re: HA+DRBD setup
 http://sip-router.1086192.n5.nabble.com/HA-DRBD-setup-tp22576p139441.html
 Sent from the Users mailing list archive
 http://sip-router.1086192.n5.nabble.com/Users-f3.html at Nabble.com.

 ___
 SIP Express Router (SER) and Kamailio (OpenSER) - sr-users 

Re: [SR-Users] Multi-homed Kamailio Modifies ACK

2015-05-12 Thread SamyGo
Yeah sure, attached here is the trace from the CISCO logs. Not in pcap
format.
Also this is the flow of the call.

 +---+  +--+   +--+
|Provider |+ +Kamailio +--+CISCO IAD  |
+---+  +--+   +-+
| ^
  v |
  +---+
|Asterisk |
+---+

Thanks and best Regards,
--

On Tue, May 12, 2015 at 11:50 AM, Alex Balashov abalas...@evaristesys.com
wrote:

 Is the UAC in this case a 2543 endpoint by chance? Can you send a complete
 SIP trace of the entire setup?

  --
 Alex Balashov | Principal | Evariste Systems LLC
 303 Perimeter Center North, Suite 300
 Atlanta, GA 30346
 United States

 Tel: +1-800-250-5920 (toll-free) / +1-678-954-0671 (direct)
 Web: http://www.evaristesys.com/, http://www.csrpswitch.com/

 Sent from my BlackBerry.
   *From: *SamyGo
 *Sent: *Tuesday, May 12, 2015 11:46
 *To: *SIP Router - Kamailio (OpenSER) and SIP Express Router (SER) -
 Users Mailing List
 *Reply To: *Kamailio (SER) - Users Mailing List
 *Subject: *[SR-Users] Multi-homed Kamailio Modifies ACK

 Hi all,

 I'm having a scenario where I'm sending call to CISCO IAD2431. The call
 establishes with 200OK from CISCO and Kamailio sends back modified ACK.
 Cisco at this points gives out an error and sends 200OK again, Kamailio
 replies with ACK, and this cycle goes on until the call drops.

 Here is the error from CISCO:

 Failed FROM/TO Request check
   old_from: Test Phone sip:+14432232221@192.168.1.106;tag=as370915fc
   old_to:   sip:+1812...@sip.iamip.com:5041;tag=9FEC572E-100F
   new_from: Test Phone sip:+14432232221@192.168.1.106;tag=as370915fc
   new_to:   sip:+1812211@192.168.1.244:5041;tag=9FE

 I've
 #auto_aliases=no

 and,
 listen=udp:44.33.22.11:5041
 listen=udp:192.168.1.244:5041

 Kamailio sends INVITE through the Public IP to the CISCO gw, but decides
 to change the ACK header.

 Any advise please.

 Best Regards,
 Sammy.



 ___
 SIP Express Router (SER) and Kamailio (OpenSER) - sr-users mailing list
 sr-users@lists.sip-router.org
 http://lists.sip-router.org/cgi-bin/mailman/listinfo/sr-users


=~=~=~=~=~=~=~=~=~=~=~= PuTTY log 2015.05.11 15:38:15 =~=~=~=~=~=~=~=~=~=~=~=

CISCO-GW#
CISCO-GW#
CISCO-GW#t show log


006271: *May 12 04:26:06.939: Received: 
INVITE sip:+1812211@99.110.111.112:5060 SIP/2.0
Record-Route: 
sip:44.33.22.11:5041;r2=on;lr=on;ftag=as370915fc;did=e28.f8c1;nat=yes
Record-Route: 
sip:192.168.1.244:5041;r2=on;lr=on;ftag=as370915fc;did=e28.f8c1;nat=yes
Via: SIP/2.0/UDP 
44.33.22.11:5041;branch=z9hG4bKff67.ddb600ce64f62e3d27a4570903cfd827.0
Via: SIP/2.0/UDP 192.168.1.106:5060;branch=z9hG4bK2d047b8c;rport=5060
Max-Forwards: 69
From: Test Phone sip:+14432232221@192.168.1.106;tag=as370915fc
To: sip:+1812...@sip.iamip.com:5041
Contact: sip:+14432232221@192.168.1.106:5060
Call-ID: 29d42683248faec624fb0ce94e04ebf9@192.168.1.106:5060
CSeq: 102 INVITE
User-Agent: Asterisk PBX 11.13.1
Date: Mon, 11 May 2015 19:39:18 GMT
Allow: INVITE, ACK, CANCEL, OPTIONS, BYE, REFER, SUBSCRIBE, NOTIFY, INFO, 
PUBLISH, MESSAGE
Supported: replaces, timer
P-TRUNKPORT: 5060
P-TRUNKIP: 99.110.111.112
P-UDOMAIN: sip.iamip.com
Content-Type: application/sdp
Content-Length: 301

v=0
o=root 1791803783 1791803783 IN IP4 44.33.22.12
s=Asterisk PBX 11.13.1
c=IN IP4 44.33.22.12
t=0 0
m=audio 51590 RTP/AVP 8 3 0 101
a=rtpmap:8 PCMA/8000
a=rtpmap:3 GSM/8000
a=rtpmap:0 PCMU/8000
a=rtpmap:101 telephone-event/8000
a=fmtp:101 0-16
a=ptime:20
a=sendrecv
a=nortpproxy:yes

006329: *May 12 04:26:06.995: Sent: 
SIP/2.0 100 Trying
Via: SIP/2.0/UDP 
44.33.22.11:5041;branch=z9hG4bKff67.ddb600ce64f62e3d27a4570903cfd827.0,SIP/2.0/UDP
 192.168.1.106:5060;branch=z9hG4bK2d047b8c;rport=5060
From: Test Phone sip:+14432232221@192.168.1.106;tag=as370915fc
To: sip:+1812...@sip.iamip.com:5041;tag=9FEC572E-100F
Date: Sat, 28 Aug 1993 04:26:06 GMT
Call-ID: 29d42683248faec624fb0ce94e04ebf9@192.168.1.106:5060
Server: Cisco-SIPGateway/IOS-12.x
CSeq: 102 INVITE
Allow-Events: telephone-event
Content-Length: 0


006380: *May 12 04:26:07.027: Sent: 
SIP/2.0 183 Session Progress
Via: SIP/2.0/UDP 
44.33.22.11:5041;branch=z9hG4bKff67.ddb600ce64f62e3d27a4570903cfd827.0,SIP/2.0/UDP
 192.168.1.106:5060;branch=z9hG4bK2d047b8c;rport=5060
From: Test Phone sip:+14432232221@192.168.1.106;tag=as370915fc
To: sip:+1812...@sip.iamip.com:5041;tag=9FEC572E-100F
Date: Sat, 28 Aug 1993 04:26:06 GMT
Call-ID: 29d42683248faec624fb0ce94e04ebf9@192.168.1.106:5060
Server: Cisco-SIPGateway/IOS-12.x
CSeq: 102 INVITE
Allow-Events: telephone-event
Contact: sip:+1812211@99.110.111.112:5060
Record-Route: 
sip:44.33.22.11:5041;r2=on;lr=on;ftag=as370915fc;did=e28.f8c1;nat=yes,sip:192.168.1.244:5041;r2=on;lr=on;ftag=as370915fc;did=e28.f8c1;nat=yes
Content-Disposition: session;handling=required
Content-Type: application/sdp
Content-Length: 250

v=0
o

Re: [SR-Users] Multi-homed Kamailio Modifies ACK

2015-05-12 Thread SamyGo
Update, manually modifying the To-Domain in ACK has fixed this, I saved the
key value pair Call-ID/To-Domain of 200OK from CISCO and for corresponding
ACK with same Call-ID modified the $td

same problem appeared in BYE for the call, again same fix by modifying the
To-Domain for the same Call-iD in subsequent BYE.

QUESTION: Was this supposed to happen with mhomed Kamailio ? I have not
observed this scenario with any provider/gateway other than this CISCO gw!

BR,
Sammy.




On Tue, May 12, 2015 at 12:24 PM, SamyGo govoi...@gmail.com wrote:

 Yeah sure, attached here is the trace from the CISCO logs. Not in pcap
 format.
 Also this is the flow of the call.

  +---+  +--+   +--+
 |Provider |+ +Kamailio +--+CISCO IAD  |
 +---+  +--+   +-+
 | ^
   v |
   +---+
 |Asterisk |
 +---+

 Thanks and best Regards,
 --

 On Tue, May 12, 2015 at 11:50 AM, Alex Balashov abalas...@evaristesys.com
  wrote:

 Is the UAC in this case a 2543 endpoint by chance? Can you send a
 complete SIP trace of the entire setup?

  --
 Alex Balashov | Principal | Evariste Systems LLC
 303 Perimeter Center North, Suite 300
 Atlanta, GA 30346
 United States

 Tel: +1-800-250-5920 (toll-free) / +1-678-954-0671 (direct)
 Web: http://www.evaristesys.com/, http://www.csrpswitch.com/

 Sent from my BlackBerry.
   *From: *SamyGo
 *Sent: *Tuesday, May 12, 2015 11:46
 *To: *SIP Router - Kamailio (OpenSER) and SIP Express Router (SER) -
 Users Mailing List
 *Reply To: *Kamailio (SER) - Users Mailing List
 *Subject: *[SR-Users] Multi-homed Kamailio Modifies ACK

 Hi all,

 I'm having a scenario where I'm sending call to CISCO IAD2431. The call
 establishes with 200OK from CISCO and Kamailio sends back modified ACK.
 Cisco at this points gives out an error and sends 200OK again, Kamailio
 replies with ACK, and this cycle goes on until the call drops.

 Here is the error from CISCO:

 Failed FROM/TO Request check
   old_from: Test Phone sip:+14432232221@192.168.1.106;tag=as370915fc
   old_to:   sip:+1812...@sip.iamip.com:5041;tag=9FEC572E-100F
   new_from: Test Phone sip:+14432232221@192.168.1.106;tag=as370915fc
   new_to:   sip:+1812211@192.168.1.244:5041;tag=9FE

 I've
 #auto_aliases=no

 and,
 listen=udp:44.33.22.11:5041
 listen=udp:192.168.1.244:5041

 Kamailio sends INVITE through the Public IP to the CISCO gw, but decides
 to change the ACK header.

 Any advise please.

 Best Regards,
 Sammy.



 ___
 SIP Express Router (SER) and Kamailio (OpenSER) - sr-users mailing list
 sr-users@lists.sip-router.org
 http://lists.sip-router.org/cgi-bin/mailman/listinfo/sr-users



___
SIP Express Router (SER) and Kamailio (OpenSER) - sr-users mailing list
sr-users@lists.sip-router.org
http://lists.sip-router.org/cgi-bin/mailman/listinfo/sr-users


[SR-Users] Multi-homed Kamailio Modifies ACK

2015-05-12 Thread SamyGo
Hi all,

I'm having a scenario where I'm sending call to CISCO IAD2431. The call
establishes with 200OK from CISCO and Kamailio sends back modified ACK.
Cisco at this points gives out an error and sends 200OK again, Kamailio
replies with ACK, and this cycle goes on until the call drops.

Here is the error from CISCO:

Failed FROM/TO Request check
  old_from: Test Phone sip:+14432232221@192.168.1.106;tag=as370915fc
  old_to:   sip:+1812...@sip.iamip.com:5041;tag=9FEC572E-100F
  new_from: Test Phone sip:+14432232221@192.168.1.106;tag=as370915fc
  new_to:   sip:+1812211@192.168.1.244:5041;tag=9FE

I've
#auto_aliases=no

and,
listen=udp:44.33.22.11:5041
listen=udp:192.168.1.244:5041

Kamailio sends INVITE through the Public IP to the CISCO gw, but decides to
change the ACK header.

Any advise please.

Best Regards,
Sammy.
___
SIP Express Router (SER) and Kamailio (OpenSER) - sr-users mailing list
sr-users@lists.sip-router.org
http://lists.sip-router.org/cgi-bin/mailman/listinfo/sr-users


Re: [SR-Users] NO VOICE AFTER MSILO

2015-05-01 Thread SamyGo
They should be unrelated, RTPPROXY called on INVITES and MSILO on
REGISTER|MESSAGE, why should INVITE's flow change using that msilo route ?


On Thu, Apr 30, 2015 at 4:13 AM, sscc androids...@gmail.com wrote:

 # - msilo params -
 #!ifdef WITH_MSILO

 modparam(msilo, db_url, mysql://kamailio:abc@localhost/kamailio)

 modparam(msilo, from_address, sip:regist...@sscc.tk)

 modparam(msilo, contact_hdr, Contact: regist...@sscc.tk
 ;msilo=yes\r\n)

 modparam(msilo, content_type_hdr, Content-Type:text/plain\r\n)
 modparam(msilo, offline_message, User $ru is offline!)

 modparam (msilo, outbound_proxy, sip:sscc.tk:6524;transport=tcp)






 ### Routing Logic 


 # Main SIP request routing logic
 # - processing of any incoming SIP request starts with this route
 # - note: this is the same as route { ... }
 request_route {

 # per request initial checks
 route(REQINIT);

 # NAT detection
 route(NATDETECT);

 # CANCEL processing
 if (is_method(CANCEL)) {
 if (t_check_trans()) {
 route(RELAY);
 }
 exit;
 }

 # handle requests within SIP dialogs
 route(WITHINDLG);

 ### only initial requests (no To tag)
 xlog(L_NOTICE,main route enter\n);
 # handle retransmissions
 if(t_precheck_trans()) {
 t_check_trans();
 exit;
 }
 t_check_trans();

 # authentication
 route(AUTH);

 # record routing for dialog forming requests (in case they are
 routed)
 # - remove preloaded route headers
 remove_hf(Route);
 if (is_method(INVITE|SUBSCRIBE))
 record_route();

 # account only INVITEs
 if (is_method(INVITE)) {
 setflag(FLT_ACC); # do accounting
 }

 # dispatch requests to foreign domains
 route(SIPOUT);

 ### requests for my local domains

 # handle presence related requests
 route(PRESENCE);

 # handle registrations
 route(REGISTRAR);

 if ($rU==$null) {
 # request with no Username in RURI
 sl_send_reply(484,Address Incomplete);
 exit;
 }
 # for msilo routing logic (sajjad)
 route(MSILO);
 # dispatch destinations to PSTN
 route(PSTN);

 # user location service
 route(LOCATION);
 }

 # Wrapper for relaying requests
 route[RELAY] {
  xlog(L_NOTICE, RELAY route enter\n);

 # enable additional event routes for forwarded requests
 # - serial forking, RTP relaying handling, a.s.o.
 if (is_method(INVITE|BYE|SUBSCRIBE|UPDATE)) {
 if(!t_is_set(branch_route)) t_on_branch(MANAGE_BRANCH);
 }
 if (is_method(INVITE|SUBSCRIBE|UPDATE)) {
 if(!t_is_set(onreply_route)) t_on_reply(MANAGE_REPLY);
 }
 if (is_method(INVITE)) {
 if(!t_is_set(failure_route))
 t_on_failure(MANAGE_FAILURE);
 }

 if (!t_relay()) {
 sl_reply_error();
 }
 exit;
 }

 # Per SIP request initial checks
 route[REQINIT] {
 #!ifdef WITH_ANTIFLOOD
 # flood dection from same IP and traffic ban for a while
 # be sure you exclude checking trusted peers, such as pstn gateways
 # - local host excluded (e.g., loop to self)
 if(src_ip!=myself) {
 if($sht(ipban=$si)!=$null) {
 # ip is already blocked
 #xdbg(request from blocked IP - $rm from $fu
 (IP:$si:$sp)\n);
 xlog(L_NOTICE,request from blocked IP - $rm from
 $fu (IP:$si:$sp)\n);
 exit;
 }
 if (!pike_check_req()) {
 #xlog(L_ALERT,ALERT: pike blocking $rm from $fu
 (IP:$si:$sp)\n);
 xlog(L_NOTICE,ALERT: pike blocking $rm from $fu
 (IP:$si:$sp)\n);
 $sht(ipban=$si) = 1;
 exit;
 }
 }
 if($ua =~ friendly-scanner) {
 sl_send_reply(200, OK);
 exit;
 }
 #!endif

 if (!mf_process_maxfwd_header(10)) {
 sl_send_reply(483,Too Many Hops);
 exit;
 }

 if(is_method(OPTIONS)  uri==myself  $rU==$null) {
 sl_send_reply(200,Keepalive);
 exit;
 }

 if(!sanity_check(1511, 7)) {
 xlog(Malformed SIP message from $si:$sp\n);
 exit;
 }
 }

 # Handle requests within SIP dialogs
 route[WITHINDLG] {
 if (!has_totag()) return;

 # sequential request withing a dialog should
 # take the path determined by record-routing
 if (loose_route()) {
 route(DLGURI);
 if (is_method(BYE)) {

Re: [SR-Users] [SR_USers] Authenticate asterisk-kamailio

2015-04-30 Thread SamyGo
Hi,
The important thing to consider here is this line.

#!define WITH_ASTERISK

 so if you've defined this on the very top of your kamailio.cfg then it
will go and check username/passwords from the sipusers table from the
Database defined by this: DBASTURL

if (!auth_check($fd, sipusers, 1)) {

Make sure you've the same user defined and username and passwords are
defined in these columns:

modparam(auth_db, user_column, name)

modparam(auth_db, password_column, sippasswd)

the sipasswd column is text based so dont use encrypted PASSWORD() in there.


Once you follow these steps your user should get registered.



On Wed, Apr 29, 2015 at 9:52 AM, Mauricio Tejeda mauricio.tej...@outlook.cl
 wrote:

 Hello All.

 My English is bad so I hope you can understand.



 I have been working with Kamailio some time, I following some of Guides of
 http://kb.asipto.com, http://saevolgo.blogspot.com and http://nil.uniza.sk
 .



 To Authenticate Asterisk sipusers I'm not have problems, but subscriber of
 Kamailio  authenticate is my problem.

 Autenticate are denied to subscriber Kamailio.



 In spanish I can explain it better  :-)



 best regards





 my Settings:



 ###

 # - auth_db params -

 #!ifdef WITH_AUTH

 modparam(auth_db, calculate_ha1, yes)

 modparam(auth_db, load_credentials, )



 #!ifdef WITH_ASTERISK

 modparam(auth_db, user_column, name)

 modparam(auth_db, password_column, sippasswd)

 modparam(auth_db, db_url, DBASTURL)

 modparam(auth_db, version_table, 0)

 #!else

 modparam(auth_db, db_url, DBURL)

 modparam(auth_db, password_column, password)

 modparam(auth_db, use_domain, MULTIDOMAIN)

 #!endif



 



 #!ifdef WITH_AUTH



 #!ifdef WITH_ASTERISK

 # do not auth traffic from Asterisk - trusted!

 if(route(FROMASTERISK))

return;

 #!endif



 #!ifdef WITH_IPAUTH

 if((!is_method(REGISTER))  allow_source_address())

 {

# source IP allowed

return;

 }

 #!endif



 if (is_method(REGISTER) || from_uri==myself)

 {

# authenticate requests

 #!ifdef WITH_ASTERISK

if (!auth_check($fd, sipusers, 1))
 {   Aquí autentifica sin problemas en caso de ser
 un usuario asterisk

 #!else
 Pero hace caso
 omiso al switch.

if (!auth_check($fd, subscriber, 1))
 {  No autentifica subscriber de la base de datos de
 kamailio

 #!endif

auth_challenge($fd, 0);

exit;

}

# user authenticated - remove auth header

if(!is_method(REGISTER|PUBLISH))

consume_credentials();

 }

 #!endif

 return;

 }



 #



 DEBUG KAMAILIO



 Apr 29 10:40:48 labkamailio kamailio[11304]: DEBUG: core
 [parser/msg_parser.c:623]: parse_msg(): SIP Request:

 Apr 29 10:40:48 labkamailio kamailio[11304]: DEBUG: core
 [parser/msg_parser.c:625]: parse_msg():  method:  REGISTER

 Apr 29 10:40:48 labkamailio kamailio[11304]: DEBUG: core
 [parser/msg_parser.c:627]: parse_msg():  uri: sip:192.168.65.132

 Apr 29 10:40:48 labkamailio kamailio[11304]: DEBUG: core
 [parser/msg_parser.c:629]: parse_msg():  version: SIP/2.0

 Apr 29 10:40:48 labkamailio kamailio[11304]: DEBUG: core
 [parser/parse_addr_spec.c:898]: parse_addr_spec(): end of header reached,
 state=10

 Apr 29 10:40:48 labkamailio kamailio[11304]: DEBUG: core
 [parser/msg_parser.c:190]: get_hdr_field(): DEBUG: get_hdr_field: To
 [29]; uri=[sip:107@192.168.65.132]

 Apr 29 10:40:48 labkamailio kamailio[11304]: DEBUG: core
 [parser/msg_parser.c:192]: get_hdr_field(): DEBUG: to body [107
 sip:107@192.168.65.132#015#012]

 Apr 29 10:40:48 labkamailio kamailio[11304]: DEBUG: core
 [parser/parse_via.c:1284]: parse_via_param(): Found param type 232,
 branch = z9hG4bK-d87543-733510592-1--d87543-; state=6

 Apr 29 10:40:48 labkamailio kamailio[11304]: DEBUG: core
 [parser/parse_via.c:1284]: parse_via_param(): Found param type 235, rport
 = n/a; state=17

 Apr 29 10:40:48 labkamailio kamailio[11304]: DEBUG: core
 [parser/parse_via.c:2672]: parse_via(): end of header reached, state=5

 Apr 29 10:40:48 labkamailio kamailio[11304]: DEBUG: core
 [parser/msg_parser.c:513]: parse_headers(): parse_headers: Via found,
 flags=2

 Apr 29 10:40:48 labkamailio kamailio[11304]: DEBUG: core
 [parser/msg_parser.c:515]: parse_headers(): parse_headers: this is the
 first via

 Apr 29 10:40:48 labkamailio kamailio[11304]: DEBUG: core
 [receive.c:154]: 

Re: [SR-Users] NO VOICE AFTER MSILO

2015-04-30 Thread SamyGo
Could you provide your section of the code where you're using msilo ? how
you're using it !
 I just wonder how could it just tell kamailio to skip rtpproxy stuff !!

On Wed, Apr 29, 2015 at 11:55 PM, sscc androids...@gmail.com wrote:

 i have configured msilo module successful but there isn't any voice with
 msilo. i debug and compare the call flow with and without msilo. with msilo
 in call flow it didn't follow to relay and consequently didnt activate
 rtpproxy befor the call is answered. due to which during call there isn't
 any voice. please help



 --
 View this message in context:
 http://sip-router.1086192.n5.nabble.com/NO-VOICE-AFTER-MSILO-tp137430.html
 Sent from the Users mailing list archive at Nabble.com.

 ___
 SIP Express Router (SER) and Kamailio (OpenSER) - sr-users mailing list
 sr-users@lists.sip-router.org
 http://lists.sip-router.org/cgi-bin/mailman/listinfo/sr-users

___
SIP Express Router (SER) and Kamailio (OpenSER) - sr-users mailing list
sr-users@lists.sip-router.org
http://lists.sip-router.org/cgi-bin/mailman/listinfo/sr-users


Re: [SR-Users] UAC Module

2015-04-30 Thread SamyGo
t_on_failure(F_VOIP) to be used before t_relay();
That will arm the call to go to F_VOIP on failure responses.

On Thu, Apr 30, 2015 at 9:33 AM, Ali Jibran alijib...@vividtech.io wrote:



 #!ifdef WITH_FREESWITCH

 if(is_method(INVITE)  route(FROMFREESWITCH))) {

 xlog(L_INFO ,[$fU/$tU@$si:$sp]{$rm} Call from
 FreeSWITCH needs to be sent TOVOIP \n);

 route(TOVOIP);

 t_on_failure(F_VOIP);

 exit;

 }



 #!endif







 route[TOVOIP] {

 xlog(L_INFO,ALERT: $fu to $tu  );

 $fU=XX;

 $td=sip.voipfone.net;

 $du=sip:...@sip.voipfone.net;

 t_relay();



 }





 failure_route[F_VOIP] {

 uac_auth();

 xlog(L_INFO,ALERT: IN FAIL);

}





 I tried this but it never makes it to the failure branch. Im a newbie to
 kamailio and still working around the scripting. Can you please help me out
 here to where I am making the mistake?



 *From:* sr-users [mailto:sr-users-boun...@lists.sip-router.org] *On
 Behalf Of *SamyGo
 *Sent:* Thursday, April 30, 2015 9:18 AM
 *To:* Kamailio (SER) - Users Mailing List
 *Subject:* Re: [SR-Users] UAC Module



 Hi Jibran,



 Here is an old thread as reference:


 http://lists.sip-router.org/pipermail/sr-users/2013-August/079336.html



 I wouldn't want to do the whole handshake of INVITE,PROXY-AUTH,INVITE with
 username/password on a Provider for huge number of calls..imagine sending
 thousands of call to that provider and for each call going through the
 trouble of exchanging authentication.

 Thats why its usually recommended to go with IP-Authentication only. Send
 INVITE and Provider says Lets do this call,simple and easy.



 From the configuration perspective this is my idea of still using UAC.



 - Call coming from FS on kamailio

 - Rewrite the from-uri  (so the provider receives calls from the
 registered username)

 - modify the to-domain part to contain the IP address of the provider

 - set the $du to ip of the provider, and t_relay() the call.

 - Most likely the Provider would say Proxy-Auth required..that can be
 caught in failure_route[]

 - There you can call the uac_auth() function to have username.password
 attached to the response of above.
 http://kamailio.org/docs/modules/4.3.x/modules/uac.html#uac.f.uac_auth()

 - once this function is successful send the INVITE again to the provider.



 Last three steps can be the following snippet of code(reference from here
 http://opensips.org/pipermail/users/2010-August/013947.html):



 failure_route[2] {

  if (t_check_status(40[17])) {

 xlog(got challenged \n);

 if (uac_auth()) {

 xlog(auth was succesful \n);

 t_relay(udp:ip_addr:5060); //provider's IP_ADDR

 }

 }





 I hope you get IP Auth from the provider, and find the reply useful.



 Regards,







 On Wed, Apr 29, 2015 at 4:49 PM, Ali Jibran alijib...@vividtech.io
 wrote:


 Hi all.
 I have this setup.
 Trunk---KamailioFreeSWITCH

 I have a trunk from a sip provided and registered successfully with the
 UAC module. Incoming is working fine. I need to make out going through
 kamailio too.

 I have it in the dialplan to forward the invite to kamailio from
 FreeSWITCH. I can see it the logs that it reaches kamailio. Now how do I
 make the call via the trunk?

 Basically this is what I'm trying to workout
 FSkamailiotrunk.


 Any help will be much appreciated. Thanks.
 AJ
 ___
 SIP Express Router (SER) and Kamailio (OpenSER) - sr-users mailing list
 sr-users@lists.sip-router.org
 http://lists.sip-router.org/cgi-bin/mailman/listinfo/sr-users




 --
http://www.avast.com/

 This email is free from viruses and malware because avast! Antivirus
 http://www.avast.com/ protection is active.


 ___
 SIP Express Router (SER) and Kamailio (OpenSER) - sr-users mailing list
 sr-users@lists.sip-router.org
 http://lists.sip-router.org/cgi-bin/mailman/listinfo/sr-users


___
SIP Express Router (SER) and Kamailio (OpenSER) - sr-users mailing list
sr-users@lists.sip-router.org
http://lists.sip-router.org/cgi-bin/mailman/listinfo/sr-users


Re: [SR-Users] UAC Module

2015-04-30 Thread SamyGo
I'd like you to google around, there is a function available from another
module which will apply the changes in SIP Message.


On Thu, Apr 30, 2015 at 9:51 AM, Ali Jibran alijib...@vividtech.io wrote:

 Perfect. Yeah got the working.

 Just one last issue. I don’t think this is rewriting the header. When I
 log the header again after the changes it still shows me the old values.



 *From:* sr-users [mailto:sr-users-boun...@lists.sip-router.org] *On
 Behalf Of *SamyGo
 *Sent:* Thursday, April 30, 2015 6:50 PM

 *To:* Kamailio (SER) - Users Mailing List
 *Subject:* Re: [SR-Users] UAC Module



 t_on_failure(F_VOIP) to be used before t_relay();

 That will arm the call to go to F_VOIP on failure responses.



 On Thu, Apr 30, 2015 at 9:33 AM, Ali Jibran alijib...@vividtech.io
 wrote:



 #!ifdef WITH_FREESWITCH

 if(is_method(INVITE)  route(FROMFREESWITCH))) {

 xlog(L_INFO ,[$fU/$tU@$si:$sp]{$rm} Call from
 FreeSWITCH needs to be sent TOVOIP \n);

 route(TOVOIP);

 t_on_failure(F_VOIP);

 exit;

 }



 #!endif







 route[TOVOIP] {

 xlog(L_INFO,ALERT: $fu to $tu  );

 $fU=XX;

 $td=sip.voipfone.net;

 $du=sip:...@sip.voipfone.net;

 t_relay();



 }





 failure_route[F_VOIP] {

 uac_auth();

 xlog(L_INFO,ALERT: IN FAIL);

}





 I tried this but it never makes it to the failure branch. Im a newbie to
 kamailio and still working around the scripting. Can you please help me out
 here to where I am making the mistake?



 *From:* sr-users [mailto:sr-users-boun...@lists.sip-router.org] *On
 Behalf Of *SamyGo
 *Sent:* Thursday, April 30, 2015 9:18 AM
 *To:* Kamailio (SER) - Users Mailing List
 *Subject:* Re: [SR-Users] UAC Module



 Hi Jibran,



 Here is an old thread as reference:


 http://lists.sip-router.org/pipermail/sr-users/2013-August/079336.html



 I wouldn't want to do the whole handshake of INVITE,PROXY-AUTH,INVITE with
 username/password on a Provider for huge number of calls..imagine sending
 thousands of call to that provider and for each call going through the
 trouble of exchanging authentication.

 Thats why its usually recommended to go with IP-Authentication only. Send
 INVITE and Provider says Lets do this call,simple and easy.



 From the configuration perspective this is my idea of still using UAC.



 - Call coming from FS on kamailio

 - Rewrite the from-uri  (so the provider receives calls from the
 registered username)

 - modify the to-domain part to contain the IP address of the provider

 - set the $du to ip of the provider, and t_relay() the call.

 - Most likely the Provider would say Proxy-Auth required..that can be
 caught in failure_route[]

 - There you can call the uac_auth() function to have username.password
 attached to the response of above.
 http://kamailio.org/docs/modules/4.3.x/modules/uac.html#uac.f.uac_auth()

 - once this function is successful send the INVITE again to the provider.



 Last three steps can be the following snippet of code(reference from here
 http://opensips.org/pipermail/users/2010-August/013947.html):



 failure_route[2] {

  if (t_check_status(40[17])) {

 xlog(got challenged \n);

 if (uac_auth()) {

 xlog(auth was succesful \n);

 t_relay(udp:ip_addr:5060); //provider's IP_ADDR

 }

 }





 I hope you get IP Auth from the provider, and find the reply useful.



 Regards,







 On Wed, Apr 29, 2015 at 4:49 PM, Ali Jibran alijib...@vividtech.io
 wrote:


 Hi all.
 I have this setup.
 Trunk---KamailioFreeSWITCH

 I have a trunk from a sip provided and registered successfully with the
 UAC module. Incoming is working fine. I need to make out going through
 kamailio too.

 I have it in the dialplan to forward the invite to kamailio from
 FreeSWITCH. I can see it the logs that it reaches kamailio. Now how do I
 make the call via the trunk?

 Basically this is what I'm trying to workout
 FSkamailiotrunk.


 Any help will be much appreciated. Thanks.
 AJ
 ___
 SIP Express Router (SER) and Kamailio (OpenSER) - sr-users mailing list
 sr-users@lists.sip-router.org
 http://lists.sip-router.org/cgi-bin/mailman/listinfo/sr-users




 --

 [image: Image removed by sender.] http://www.avast.com/

 This email is free from viruses and malware because avast! Antivirus
 http://www.avast.com/ protection is active.




 ___
 SIP Express Router (SER) and Kamailio (OpenSER) - sr-users mailing list
 sr-users@lists.sip-router.org
 http://lists.sip-router.org/cgi-bin/mailman/listinfo/sr-users




 --
http://www.avast.com/

 This email is free from viruses and malware because avast! Antivirus
 http://www.avast.com/ protection is active.


 ___
 SIP Express

Re: [SR-Users] UAC Module

2015-04-29 Thread SamyGo
Hi Jibran,

Here is an old thread as reference:

http://lists.sip-router.org/pipermail/sr-users/2013-August/079336.html

I wouldn't want to do the whole handshake of INVITE,PROXY-AUTH,INVITE with
username/password on a Provider for huge number of calls..imagine sending
thousands of call to that provider and for each call going through the
trouble of exchanging authentication.
Thats why its usually recommended to go with IP-Authentication only. Send
INVITE and Provider says Lets do this call,simple and easy.

From the configuration perspective this is my idea of still using UAC.

- Call coming from FS on kamailio
- Rewrite the from-uri  (so the provider receives calls from the registered
username)
- modify the to-domain part to contain the IP address of the provider
- set the $du to ip of the provider, and t_relay() the call.
- Most likely the Provider would say Proxy-Auth required..that can be
caught in failure_route[]
- There you can call the uac_auth() function to have username.password
attached to the response of above.
http://kamailio.org/docs/modules/4.3.x/modules/uac.html#uac.f.uac_auth()
- once this function is successful send the INVITE again to the provider.

Last three steps can be the following snippet of code(reference from here
http://opensips.org/pipermail/users/2010-August/013947.html):

failure_route[2] {
 if (t_check_status(40[17])) {
xlog(got challenged \n);
if (uac_auth()) {
xlog(auth was succesful \n);
t_relay(udp:ip_addr:5060); //provider's IP_ADDR
}
}



I hope you get IP Auth from the provider, and find the reply useful.

Regards,



On Wed, Apr 29, 2015 at 4:49 PM, Ali Jibran alijib...@vividtech.io wrote:


 Hi all.
 I have this setup.
 Trunk---KamailioFreeSWITCH

 I have a trunk from a sip provided and registered successfully with the
 UAC module. Incoming is working fine. I need to make out going through
 kamailio too.

 I have it in the dialplan to forward the invite to kamailio from
 FreeSWITCH. I can see it the logs that it reaches kamailio. Now how do I
 make the call via the trunk?

 Basically this is what I'm trying to workout
 FSkamailiotrunk.


 Any help will be much appreciated. Thanks.
 AJ
 ___
 SIP Express Router (SER) and Kamailio (OpenSER) - sr-users mailing list
 sr-users@lists.sip-router.org
 http://lists.sip-router.org/cgi-bin/mailman/listinfo/sr-users

___
SIP Express Router (SER) and Kamailio (OpenSER) - sr-users mailing list
sr-users@lists.sip-router.org
http://lists.sip-router.org/cgi-bin/mailman/listinfo/sr-users


Re: [SR-Users] Announcement: Kamailio is now systemd-rtc-server

2015-03-31 Thread SamyGo
From the diaries of the amazing Alex-Man,
Chapter 4 Page 1, Vol 15.

Congrats ;)

On Wed, Apr 1, 2015 at 12:11 AM, Alex Balashov abalas...@evaristesys.com
wrote:

 For immediate release:

 ATLANTA, GA (1 April 2015)--Evariste Systems LLC, an Atlanta-based software
 vendor specialising in Kamailio-based service delivery solutions for the
 VoIP ITSP market, is pleased to announce that it, in collaboration with
 Red Hat Software and Ringfree Communications, has finalised the
 absorption of the Kamailio SIP Server into the 'systemd' system management
 platform for Linux. The new component shall be called 'systemd-rtc-server',
 or 'Systemd Real-Time Communication Server'.

 Alex Balashov, principal of Evariste and leader of the tri-vendor
 collaboration effort, will officially announce the handover of the reigns
 of the Kamailio project to the personal leadership of Lennart Poettering
 at the upcoming Systemd Real Time Communications World conference, to be
 held in Berlin on 27-29 May of this year.

 John Knight, Director of GNOME 3 Integration and part-time usability
 consultant at Ringfree Communications, based in Hendersonville, North
 Carolina,was quick to summarise the triumphs of the long-standing
 integration effort.

 Remarked Knight:

 The industry has recognised for years that a SIP proxy is a basic building
 block in the 'init' subsystem of any Linux host. In this age of multimedia
 communication with voice and video, it was a travesty that systemd handled
 time synchronisation, network configuration, login management, logging,
 and console, but not SIP message routing.

 Sean McCord, a veteran partner at Atlanta-based integrator CyCORE  Docker,
 was quick to concur:

 SIP calls are much easier to troubleshoot with binary logs. Combined
 with packet captures of TLS-encrypted WebRTC calls, systemd-journald
 is the ultimate call setup troubleshooting methodology of the responsive,
 kinetic enterprise.

 To support the integration of Kamailio into the ecosystem of every major
 Linux distribution, Evariste has released new 'dbus_api' and 'pulseaudio'
 modules for the project.

 Balashov stated, We fully expect to use the D-Bus API to achieve
 gnome-session integration with systemd-rtc-server-usrloc, but we aren't
 going to leave Windows users behind; KamailioSvcHost.exe will support
 Domain Controller policies for G.722 in Active Directory forests.

 Despite an aggressive delivery timeline by the tri-vendor consortium behind
 systemd-rtc-server, industry commentators have widely lambasted the fact
 that it took so long for Kamailio to become integrated into systemd. Fred
 Posner, solutions architect at The Palner Group in Fort Lauderdale,
 Florida,
 recently wrote in a widely-publicised blog post:

 sr-dev have been keeping their heads in the sand for too long. For years
 now, it has been completely obvious and self-evident to anyone with half
 a brain that all kinds of VoIP software should be included in systemd.
 It's a basic building block of the whole OS, having absorbed functionality
 previously provided by all kinds of packages like util-linux and
 wireless-tools.

 John Knight of Ringfree accepted the criticism readily, but advocated a
 forward-thinking orientation focused on breaking with the uncertainty of
 the past:

 In the absence of a SIP component for routing calls to the PSTN, some
 people thought, 'systemd has no clear direction apart from the whims of its
 developers, and is a perpetually moving goal post.' Well, a SIP server
 should
 put an end to that whole discussion; that's exactly what was missing, and
 now
 that we have systemd-rtc-server, we've eliminated all doubts about the
 coherence, conceptual integrity and finality of systemd.



 --
 Alex Balashov | Principal | Evariste Systems LLC
 303 Perimeter Center North, Suite 300
 Atlanta, GA 30346
 United States

 Tel: +1-800-250-5920 (toll-free) / +1-678-954-0671 (direct)
 Web: http://www.evaristesys.com/, http://www.csrpswitch.com/

 ___
 SIP Express Router (SER) and Kamailio (OpenSER) - sr-users mailing list
 sr-users@lists.sip-router.org
 http://lists.sip-router.org/cgi-bin/mailman/listinfo/sr-users

___
SIP Express Router (SER) and Kamailio (OpenSER) - sr-users mailing list
sr-users@lists.sip-router.org
http://lists.sip-router.org/cgi-bin/mailman/listinfo/sr-users


Re: [SR-Users] using xHTTP module, bind port?

2015-03-13 Thread SamyGo
Thanks Daniel,
Thats really simple solution, the other thing I was wondering was
Authentication since the interface was all open. Maybe I should put in
similiar kind on configurations checks to verify users from DB etc !

Best Regards,
Sammy.

On Fri, Mar 13, 2015 at 4:27 AM, Daniel-Constantin Mierla mico...@gmail.com
 wrote:

  Hello,

 you can add:

 listen=tcp:1.2.3.4:8080

 and handle http requests on that port.

 You can restrict to have only http traffic on that port adding in the
 event_route for xhttp:

 if(dst_port!=8080) {
# send forbidden reply
 }

 Similar you can add in request_route for sip traffic to be on port 5060
 only.

 Cheers,
 Daniel


 On 12/03/15 19:58, SamyGo wrote:

 Hi All,

  I am just trying xhttp_rpc module
 http://www.kamailio.org/docs/modules/4.2.x/modules/xhttp_rpc.html

 Where can I set/change the port for this module ? currently its only 5060
 !?

  Thanks,
 Sammy.



 ___
 SIP Express Router (SER) and Kamailio (OpenSER) - sr-users mailing 
 listsr-us...@lists.sip-router.orghttp://lists.sip-router.org/cgi-bin/mailman/listinfo/sr-users


 --
 Daniel-Constantin Mierlahttp://twitter.com/#!/miconda - 
 http://www.linkedin.com/in/miconda
 Kamailio World Conference, May 27-29, 2015
 Berlin, Germany - http://www.kamailioworld.com


 ___
 SIP Express Router (SER) and Kamailio (OpenSER) - sr-users mailing list
 sr-users@lists.sip-router.org
 http://lists.sip-router.org/cgi-bin/mailman/listinfo/sr-users


___
SIP Express Router (SER) and Kamailio (OpenSER) - sr-users mailing list
sr-users@lists.sip-router.org
http://lists.sip-router.org/cgi-bin/mailman/listinfo/sr-users


[SR-Users] Loadmodule mi_xmlrpc.so gives error

2015-03-12 Thread SamyGo
Hi All,

Im trying to load up module 'mi_xmlrpc.so' into my v4.2.1 Kamailio. It
compiles nicely but when I try to load the module in config and restart
kamailio it gives following error(s)

0(30917) ERROR: core [sr_module.c:597]: load_module(): could not open
module /usr/local/lib64/kamailio/modules/mi_xmlrpc.so:
/usr/local/lib64/kamailio/modules/mi_xmlrpc.so: undefined symbol:
xmlrpc_strsol
 0(30917) : core [cfg.y:3436]: yyerror_at(): parse error in config file
/usr/local/etc/kamailio/kamailio.cfg, line 329, column 12-25: failed to
load module
 0(30917) ERROR: core [modparam.c:166]: set_mod_param_regex(): No module
matching mi_xmlrpc found

Now, I've done some searching around and it seems like pre-req library
version mismatch thing..

Do you guys have any solution to this.

My end objective is to be able to send MI commands to my Kamailio server(s)
via web-Interface. Any recommendations, examples are welcome.


Best Regards,
Sammy.
___
SIP Express Router (SER) and Kamailio (OpenSER) - sr-users mailing list
sr-users@lists.sip-router.org
http://lists.sip-router.org/cgi-bin/mailman/listinfo/sr-users


[SR-Users] using xHTTP module, bind port?

2015-03-12 Thread SamyGo
Hi All,

I am just trying xhttp_rpc module
http://www.kamailio.org/docs/modules/4.2.x/modules/xhttp_rpc.html

Where can I set/change the port for this module ? currently its only 5060 !?

Thanks,
Sammy.
___
SIP Express Router (SER) and Kamailio (OpenSER) - sr-users mailing list
sr-users@lists.sip-router.org
http://lists.sip-router.org/cgi-bin/mailman/listinfo/sr-users


Re: [SR-Users] Presence module for BLF issue

2015-02-10 Thread SamyGo
Hello Again,
Thanks for the great and timely help Daniel. Finally adjusted the BLF
lights. Only couple of things, which I'm sure are some functions missing
the call flow, are:

1- When users register or un-register the BLF don't update anything though
NOTIFY are triggered.
2- When call comes from PSTN and an available user answers the call, BLF
stays on green/available.

I'll continue working on fixing these in the config, any hints are still
welcome.

Many thanks once again.
Best Regards,
Sammy

On Tue, Feb 10, 2015 at 4:33 AM, Daniel-Constantin Mierla mico...@gmail.com
 wrote:

  Hello,

 ok, good that is working better now.

 I will also look more into these module in the near future. I think the
 Expires value must be different based on state, e.g., trying and ringing
 should be shorter than active call.

 Cheers,
 Daniel


 On 10/02/15 10:27, SamyGo wrote:

 Hi Daniel,
 This has helped us substantially, I've added few more lines in the config
 and seems we've working BLF now. I'll share the results when we complete
 the tests.

  Thanks alot for the timely help.
 BR,
 Sammy

 On Mon, Feb 9, 2015 at 11:24 AM, Daniel-Constantin Mierla 
 mico...@gmail.com wrote:

  Hello,

 went and configured a server for BLF as the logs were not showing any
 obvious issue.

 The result was that the way module parameters were set or have default
 values was creating this situation.

 The story is that the pua_dialoginfo takes the dialog lifetime to set the
 expires for PUBLISH. Dialog module sets that by default to 12 hours. That
 means the entries in presentity table were kept for 12 hours.

 Then force_single_dialog for presence_dialoginfo is 0, which means
 aggregate all the xml documents from presentity table. That could end up in
 a long message.

 The solution is to overwrite the dialog lifetime via pua_dialoginfo:
   -
 http://kamailio.org/docs/modules/4.2.x/modules/pua_dialoginfo.html#idp2576952

 Set override_lifetime to a lower value, like 90 .. 120 seconds, see the
 readme for hints on its value.

 Also, force_single_dialog set to 1 could be considered, but lowering the
 lifetime should make it work.

 Let me know if works ok with these settings.

 Cheers,
 Daniel


 On 07/02/15 10:48, SamyGo wrote:

 Please ignore the previous attachment got corrupted, these are the
 complete debug logs.

  Many Thanks,


 On Fri, Feb 6, 2015 at 4:38 AM, Daniel-Constantin Mierla 
 mico...@gmail.com wrote:

  Btw, there is no 'debug' message -- have you set debug=3?

 Daniel


 On 06/02/15 10:26, Daniel-Constantin Mierla wrote:

 Hello,

 the log doesn't show the messages from the INVITE to the BYE. Are you
 sure you got them for the entire call? There are notes from syslog that
 there are rate limits, dropping logs.

 Also, I noticed errors printed by t_check_trans(), are you using it from
 a branch_route? Eventually you can send the config to me to figure out from
 where the issues for error log messages are coming.

 Cheers,
 Daniel


 On 05/02/15 23:54, SamyGo wrote:

 Hi Daniel,
 Thanks alot for your time, please see the log file attached.

  If needed, I can provide sip captures received at the phone .

  Thanks,

 On Thu, Feb 5, 2015 at 4:42 PM, Daniel-Constantin Mierla 
 mico...@gmail.com wrote:


  Hello,

 can you reproduce this with three phones (not to get too much traffic)?
 Use debug=3 in kamailio.cfg and send to me all the logs from kamailio
 start. I will look to see what happens.

 Cheers,
 Daniel


 On 05/02/15 22:21, SamyGo wrote:

  Hi community,

  I'm dealing with a problem here related to presence module handling
 BLF. My BLF phones are Yealink T28p with latest firmware and work perfectly
 with Asterisk and FreeSwitch but not with Kamailio as expected.

  What I'm observing here is a malfunctioning statuses due to
 accumulation of multiple entries of just one status in presentitiy table.
 These entries neither get expired not cleared from DB hence I see atleast
 21 XML tags combined in the NOTIFY sent to Phones.

  Here is what I've figured out a manual way to make the BLF work fine
 again.

  *Step -1* Make call between two endpoints. see entries in presentitiy
 table showing up.
 *Step -2* NOTIFYs sent to phones subscribing those users from Kamailio
 and phones show correct flashing red BLF lights

  *Step -3* clear the entries from presentity table manually i.e mysql
 truncate presentity;

  *Step -4* Hangup the phones, presentity table shows few more entries
 with state='terminated' NOTIFY sent again to subscribers.. BLF lighst turn
 green happily.

  Here are my module params:


  modparam(presence, db_url, DBURL)
 modparam(presence, notifier_processes, 1)
  modparam(presence, server_address, sip:1.2.5.5 )
 modparam(presence, send_fast_notify, 0)
 modparam(presence, db_update_period, 1)
 modparam(presence, clean_period, 4)
 modparam(presence, subs_db_mode, 2)
 modparam(presence, max_expires, 36)
 modparam(presence, expires_offset, 10)
 modparam(presence, subs_htable_size, 12)
  modparam(presence

Re: [SR-Users] Presence module for BLF issue

2015-02-10 Thread SamyGo
Hi Daniel,
This has helped us substantially, I've added few more lines in the config
and seems we've working BLF now. I'll share the results when we complete
the tests.

Thanks alot for the timely help.
BR,
Sammy

On Mon, Feb 9, 2015 at 11:24 AM, Daniel-Constantin Mierla mico...@gmail.com
 wrote:

  Hello,

 went and configured a server for BLF as the logs were not showing any
 obvious issue.

 The result was that the way module parameters were set or have default
 values was creating this situation.

 The story is that the pua_dialoginfo takes the dialog lifetime to set the
 expires for PUBLISH. Dialog module sets that by default to 12 hours. That
 means the entries in presentity table were kept for 12 hours.

 Then force_single_dialog for presence_dialoginfo is 0, which means
 aggregate all the xml documents from presentity table. That could end up in
 a long message.

 The solution is to overwrite the dialog lifetime via pua_dialoginfo:
   -
 http://kamailio.org/docs/modules/4.2.x/modules/pua_dialoginfo.html#idp2576952

 Set override_lifetime to a lower value, like 90 .. 120 seconds, see the
 readme for hints on its value.

 Also, force_single_dialog set to 1 could be considered, but lowering the
 lifetime should make it work.

 Let me know if works ok with these settings.

 Cheers,
 Daniel


 On 07/02/15 10:48, SamyGo wrote:

 Please ignore the previous attachment got corrupted, these are the
 complete debug logs.

  Many Thanks,


 On Fri, Feb 6, 2015 at 4:38 AM, Daniel-Constantin Mierla 
 mico...@gmail.com wrote:

  Btw, there is no 'debug' message -- have you set debug=3?

 Daniel


 On 06/02/15 10:26, Daniel-Constantin Mierla wrote:

 Hello,

 the log doesn't show the messages from the INVITE to the BYE. Are you
 sure you got them for the entire call? There are notes from syslog that
 there are rate limits, dropping logs.

 Also, I noticed errors printed by t_check_trans(), are you using it from
 a branch_route? Eventually you can send the config to me to figure out from
 where the issues for error log messages are coming.

 Cheers,
 Daniel


 On 05/02/15 23:54, SamyGo wrote:

 Hi Daniel,
 Thanks alot for your time, please see the log file attached.

  If needed, I can provide sip captures received at the phone .

  Thanks,

 On Thu, Feb 5, 2015 at 4:42 PM, Daniel-Constantin Mierla 
 mico...@gmail.com wrote:


  Hello,

 can you reproduce this with three phones (not to get too much traffic)?
 Use debug=3 in kamailio.cfg and send to me all the logs from kamailio
 start. I will look to see what happens.

 Cheers,
 Daniel


 On 05/02/15 22:21, SamyGo wrote:

  Hi community,

  I'm dealing with a problem here related to presence module handling
 BLF. My BLF phones are Yealink T28p with latest firmware and work perfectly
 with Asterisk and FreeSwitch but not with Kamailio as expected.

  What I'm observing here is a malfunctioning statuses due to
 accumulation of multiple entries of just one status in presentitiy table.
 These entries neither get expired not cleared from DB hence I see atleast
 21 XML tags combined in the NOTIFY sent to Phones.

  Here is what I've figured out a manual way to make the BLF work fine
 again.

  *Step -1* Make call between two endpoints. see entries in presentitiy
 table showing up.
 *Step -2* NOTIFYs sent to phones subscribing those users from Kamailio
 and phones show correct flashing red BLF lights

  *Step -3* clear the entries from presentity table manually i.e mysql
 truncate presentity;

  *Step -4* Hangup the phones, presentity table shows few more entries
 with state='terminated' NOTIFY sent again to subscribers.. BLF lighst turn
 green happily.

  Here are my module params:


  modparam(presence, db_url, DBURL)
 modparam(presence, notifier_processes, 1)
  modparam(presence, server_address, sip:1.2.5.5 )
 modparam(presence, send_fast_notify, 0)
 modparam(presence, db_update_period, 1)
 modparam(presence, clean_period, 4)
 modparam(presence, subs_db_mode, 2)
 modparam(presence, max_expires, 36)
 modparam(presence, expires_offset, 10)
 modparam(presence, subs_htable_size, 12)
  modparam(presence, pres_htable_size, 12)
 modparam(presence, fetch_rows, 1000)
  (these params were set as default earlier but I changed them as above
 hoping they'll help)

  Kindly share your expert opinion.

  Best Regards,
 Sammy


 --
 Daniel-Constantin Mierlahttp://twitter.com/#!/miconda - 
 http://www.linkedin.com/in/miconda
 Kamailio World Conference, May 27-29, 2015
 Berlin, Germany - http://www.kamailioworld.com


___
SIP Express Router (SER) and Kamailio (OpenSER) - sr-users mailing list
sr-users@lists.sip-router.org
http://lists.sip-router.org/cgi-bin/mailman/listinfo/sr-users


[SR-Users] Presence module for BLF issue

2015-02-05 Thread SamyGo
Hi community,

I'm dealing with a problem here related to presence module handling BLF. My
BLF phones are Yealink T28p with latest firmware and work perfectly with
Asterisk and FreeSwitch but not with Kamailio as expected.

What I'm observing here is a malfunctioning statuses due to accumulation of
multiple entries of just one status in presentitiy table. These entries
neither get expired not cleared from DB hence I see atleast 21 XML tags
combined in the NOTIFY sent to Phones.

Here is what I've figured out a manual way to make the BLF work fine again.

*Step -1* Make call between two endpoints. see entries in presentitiy table
showing up.
*Step -2* NOTIFYs sent to phones subscribing those users from Kamailio and
phones show correct flashing red BLF lights

*Step -3* clear the entries from presentity table manually i.e mysql
truncate presentity;

*Step -4* Hangup the phones, presentity table shows few more entries with
state='terminated' NOTIFY sent again to subscribers.. BLF lighst turn green
happily.

Here are my module params:


modparam(presence, db_url, DBURL)
modparam(presence, notifier_processes, 1)
modparam(presence, server_address, sip:1.2.5.5 )
modparam(presence, send_fast_notify, 0)
modparam(presence, db_update_period, 1)
modparam(presence, clean_period, 4)
modparam(presence, subs_db_mode, 2)
modparam(presence, max_expires, 36)
modparam(presence, expires_offset, 10)
modparam(presence, subs_htable_size, 12)
modparam(presence, pres_htable_size, 12)
modparam(presence, fetch_rows, 1000)
(these params were set as default earlier but I changed them as above
hoping they'll help)

Kindly share your expert opinion.

Best Regards,
Sammy
___
SIP Express Router (SER) and Kamailio (OpenSER) - sr-users mailing list
sr-users@lists.sip-router.org
http://lists.sip-router.org/cgi-bin/mailman/listinfo/sr-users


  1   2   3   >