Re: [OpenSIPS-Devel] [opensips] Opensips Crash, presentity Module (#646)

2015-09-28 Thread Madkonix
Hi Răzvan,
Here is a more detailed output of the logs : http://pastebin.com/mStnXxcB
The last error message before the crash is the one at 15:02:12 (Line 50).
Thank you,

---
Reply to this email directly or view it on GitHub:
https://github.com/OpenSIPS/opensips/issues/646#issuecomment-143820637___
Devel mailing list
Devel@lists.opensips.org
http://lists.opensips.org/cgi-bin/mailman/listinfo/devel


Re: [OpenSIPS-Devel] [opensips] Opensips Crash, presentity Module (#646)

2015-09-28 Thread Răzvan Crainea
Can you separate the logs before and after the crash? Perhaps the time is 
useful.

---
Reply to this email directly or view it on GitHub:
https://github.com/OpenSIPS/opensips/issues/646#issuecomment-143780193___
Devel mailing list
Devel@lists.opensips.org
http://lists.opensips.org/cgi-bin/mailman/listinfo/devel


Re: [OpenSIPS-Devel] [opensips] OpenSIPS 2.1 crash when replicate_contacts_to enabled (#652)

2015-09-28 Thread Răzvan Crainea
Sure, we should put a warning there, it shouldn't have crashed :). But it is 
not that simple, it needs a bit of refactoring, that's why I'll keep the issue 
opened until the crash is fixed.

---
Reply to this email directly or view it on GitHub:
https://github.com/OpenSIPS/opensips/issues/652#issuecomment-143769022___
Devel mailing list
Devel@lists.opensips.org
http://lists.opensips.org/cgi-bin/mailman/listinfo/devel


Re: [OpenSIPS-Devel] [opensips] OpenSIPS 2.1 crash when replicate_contacts_to enabled (#652)

2015-09-28 Thread Stas Kobzar
Hello Răzvan,

You are right, I do not have bin_listen. And it works perfect after I have 
added this parameter.

I actually wanted this OpenSIPS instance only to send bin replications, that's 
why I did not configured this parameter. But it is obvious that to send, 
OpenSIPS also needs to know which interface to use. 

So it is also my mistake. It would be great though if OpenSIPS can give a 
warning/error about missing this parameter in startup logs too.

Thank you,
Stas



---
Reply to this email directly or view it on GitHub:
https://github.com/OpenSIPS/opensips/issues/652#issuecomment-143766440___
Devel mailing list
Devel@lists.opensips.org
http://lists.opensips.org/cgi-bin/mailman/listinfo/devel


Re: [OpenSIPS-Devel] [opensips] Opensips Crash, presentity Module (#646)

2015-09-28 Thread Madkonix
Hi Răzvan,

Here are the individual errors that happened from 10min before the crash to 
10min after : 

==
ERROR:core:parse_first_line: at line 0 char 10: 
ERROR:core:parse_first_line: at line 0 char 13: 
ERROR:core:parse_first_line: bad request first line
ERROR:core:parse_first_line: parsed so far: 
ERROR:core:parse_msg: message=<>
ERROR:core:receive_msg: Unable to parse msg received from [10.132.112.114:5060]
ERROR:core:receive_msg: Unable to parse msg received from [10.132.112.210:5060]
ERROR:pua:publ_cback_func: No record found
ERROR:pua_usrloc:ul_publish: failed to send publish
ERROR:acc:acc_db_request: failed to insert into database
ERROR:core:db_do_delete: error while submitting query
ERROR:core:db_do_insert: error while submitting query
ERROR:core:db_do_update: error while submitting query
ERROR:core:parse_first_line: at line 0 char 11: 
ERROR:core:parse_first_line: at line 0 char 13: 
ERROR:core:parse_first_line: at line 0 char 16: 
ERROR:core:parse_first_line: at line 0 char 20: 
ERROR:core:parse_first_line: at line 0 char 5: 
ERROR:core:parse_first_line: bad request first line
ERROR:core:parse_first_line: parsed so far: 
ERROR:core:parse_msg: message=<>
ERROR:core:receive_msg: Unable to parse msg received from [10.132.112.114:5060]
ERROR:core:receive_msg: Unable to parse msg received from [10.132.112.210:5060]
ERROR:db_mysql:connect_with_retry: permanent re-connect failure for 
0x7ffb16c57f38
ERROR:db_mysql:db_mysql_connect: driver error(2003): Can't connect to MySQL 
server on 'mysqlserver' (4)
ERROR:db_mysql:db_mysql_do_prepared_query: failed to create new context
ERROR:db_mysql:re_init_statement: failed to reconnect before trying 
mysql_stmt_prepare()
ERROR:presence:delete_db_subs: sql delete failed
ERROR:presence:get_stored_info: wrong sequence number;received: 1367 - stored: 
1367
ERROR:presence:handle_publish: when updating presentity
ERROR:presence:handle_subscribe: getting stored info
ERROR:presence:handle_subscribe: in update_subscription
ERROR:presence:insert_subs_db: unsuccessful sql insert
ERROR:presence:update_db_subs: deleting expired information from database
ERROR:presence:update_presentity: inserting new record in database
ERROR:presence:update_presentity: No E_Tag match [a.1442606770.16919.5217.312]
ERROR:presence:update_presentity: updating published info in database
ERROR:presence:update_subscription: failed to insert subscription in database
ERROR:presence:update_subscription: updating subscription in database table
ERROR:presence:update_subs_db: updating presence information
ERROR:pua:pua_db_delete: Sql delete failed
ERROR:pua:publ_cback_func: No record found
ERROR:pua_usrloc:ul_publish: failed to send publish
==

Thank you,
Mamadou

---
Reply to this email directly or view it on GitHub:
https://github.com/OpenSIPS/opensips/issues/646#issuecomment-143765799___
Devel mailing list
Devel@lists.opensips.org
http://lists.opensips.org/cgi-bin/mailman/listinfo/devel


Re: [OpenSIPS-Devel] [opensips] OpenSIPS 2.1 crash when replicate_contacts_to enabled (#652)

2015-09-28 Thread Răzvan Crainea
Hi, Stas!

You do not have any bin_listeners in your configuration file, so OpenSIPS does 
not know what to use to replicate the information. The crash itself is indeed a 
bug, and we are working on a fox for this. Meanwhile, setting a 
```bin_listen=192.168.1.139:5070``` directive to your script should temporary 
fix your problem.

Best regards,
Răzvan

---
Reply to this email directly or view it on GitHub:
https://github.com/OpenSIPS/opensips/issues/652#issuecomment-143737416___
Devel mailing list
Devel@lists.opensips.org
http://lists.opensips.org/cgi-bin/mailman/listinfo/devel


Re: [OpenSIPS-Devel] [opensips] mi_json timeout on answer to pua_publish (#657)

2015-09-28 Thread Damien Sandrs
Log is here:
http://www.ekiga.net/misc/callserver.txt

---
Reply to this email directly or view it on GitHub:
https://github.com/OpenSIPS/opensips/issues/657#issuecomment-143729400___
Devel mailing list
Devel@lists.opensips.org
http://lists.opensips.org/cgi-bin/mailman/listinfo/devel


[OpenSIPS-Devel] [opensips] mi_json timeout on answer to pua_publish (#657)

2015-09-28 Thread Damien Sandrs
Hi,

Issue #552 was recently fixed, but I fear not all problems are gone.

We are experiencing several cases where the json call over http times out with 
no answer being given after a few seconds.

The easiest way to reproduce it is to trigger a PUBLISH to publish some state, 
then to send a PUBLISH with expires=0. I can reproduce the problem 100% of the 
time doing so.

Looking at the attached opensips.log, you will see that the PUBLISH with 
expires=0 works, but that there is no answer from mi_json:
Sep 28 14:16:48 golgoth05 opensips[3980]: DBG:mi_json:mi_json_run_mi_cmd: got 
mi_rpl=[0x]
Sep 28 14:16:48 golgoth05 opensips[3980]: 
DBG:mi_json:mi_json_answer_to_connection: got an async reply

Then nothing more.





---
Reply to this email directly or view it on GitHub:
https://github.com/OpenSIPS/opensips/issues/657___
Devel mailing list
Devel@lists.opensips.org
http://lists.opensips.org/cgi-bin/mailman/listinfo/devel


[OpenSIPS-Devel] [OpenSIPS/opensips] 9962f6: makefile: detect target architecture using the com...

2015-09-28 Thread Saúl Ibarra Corretgé
  Branch: refs/heads/1.11
  Home:   https://github.com/OpenSIPS/opensips
  Commit: 9962f6228f319a219d2c796fe6270ac4d18624dc
  
https://github.com/OpenSIPS/opensips/commit/9962f6228f319a219d2c796fe6270ac4d18624dc
  Author: Saúl Ibarra Corretgé 
  Date:   2015-09-28 (Mon, 28 Sep 2015)

  Changed paths:
M Makefile.defs

  Log Message:
  ---
  makefile: detect target architecture using the compiler

Fixes producing a 32bit build in a 64bit system.

Original patch by Andrei Pelinescu-Onciul:
https://github.com/kamailio/kamailio/commit/c46e79709216c4975abc83869fbce9fa696eac74

(cherry picked from commit 1161779ab91ac5bbd330ddf5dccc3f00d9e34f35)


  Commit: d980098810adce6ec9de875bc7c0cd295b8dad0f
  
https://github.com/OpenSIPS/opensips/commit/d980098810adce6ec9de875bc7c0cd295b8dad0f
  Author: Saúl Ibarra Corretgé 
  Date:   2015-09-28 (Mon, 28 Sep 2015)

  Changed paths:
M Makefile.defs

  Log Message:
  ---
  build: fix setting HOST_ARCH on Solaris

(cherry picked from commit 63bccb458d7a1ec59498439c5e3c952fff6c82c6)


  Commit: 1de872c08ba345604f5a50b2516fc0b08bf2348e
  
https://github.com/OpenSIPS/opensips/commit/1de872c08ba345604f5a50b2516fc0b08bf2348e
  Author: Saúl Ibarra Corretgé 
  Date:   2015-09-28 (Mon, 28 Sep 2015)

  Changed paths:
M Makefile.defs

  Log Message:
  ---
  build: fix setting LIBDIR correctly

(cherry picked from commit 3d485cdff60080124a1257dfdfa68f25408f4114)


Compare: 
https://github.com/OpenSIPS/opensips/compare/64256bddd892...1de872c08ba3___
Devel mailing list
Devel@lists.opensips.org
http://lists.opensips.org/cgi-bin/mailman/listinfo/devel


Re: [OpenSIPS-Devel] [opensips] Fix setting LIBDIR (#626)

2015-09-28 Thread Răzvan Crainea
Merged into 1.11 too.

---
Reply to this email directly or view it on GitHub:
https://github.com/OpenSIPS/opensips/pull/626#issuecomment-143724249___
Devel mailing list
Devel@lists.opensips.org
http://lists.opensips.org/cgi-bin/mailman/listinfo/devel


[OpenSIPS-Devel] [opensips] topology_hiding + 302 response (#656)

2015-09-28 Thread petekelly
if you are using topology hiding and the UAS sends a 302, the data (new $ru) in 
the Contact header is not persisted to the UAC, meaning topology hiding is not 
valid in a scenario where a 302 may be found.

It would be useful (even if it was a per module setting or per transaction 
flag) to allow the full Contact header (or headers) sent by the UAS back to the 
UAC

---
Reply to this email directly or view it on GitHub:
https://github.com/OpenSIPS/opensips/issues/656___
Devel mailing list
Devel@lists.opensips.org
http://lists.opensips.org/cgi-bin/mailman/listinfo/devel


[OpenSIPS-Devel] [opensips] dialplan causes crash on startup (#655)

2015-09-28 Thread petekelly
I am running OpenSIPS 2.1 latest from git, and seeing a strange issue with 
dialplan module in conjunction with postgresql. Basically opensips will not 
start, even with an empty dialplan table and is terminated with a SIGBUS. 

The problem still happens with some rows in dialplan table, but disappears if I 
comment out dialplan module and call to dp_translate.

I have not tried to replicate with MySQL


OpenSIPs version is

version: opensips 2.1.1 (x86_64/linux)
flags: STATS: On, DISABLE_NAGLE, USE_MCAST, SHM_MMAP, PKG_MALLOC, F_MALLOC, 
FAST_LOCK-ADAPTIVE_WAIT
ADAPTIVE_WAIT_LOOPS=1024, MAX_RECV_BUFFER_SIZE 262144, MAX_LISTEN 16, 
MAX_URI_SIZE 1024, BUF_SIZE 65535
poll method support: poll, epoll_lt, epoll_et, sigio_rt, select.
git revision: 4963c7c
main.c compiled on 08:24:30 Sep 28 2015 with gcc 4.9.2

Log output is

Sep 28 08:47:16 opensips01 opensips-reg[20519]: 
DBG:db_postgres:db_postgres_submit_query: 0x7fca723c2b60 PQsendQuery(select 
dpid,pr,match_op,match_exp,match_flags,subst_exp,repl_exp,attrs,timerec from 
dialplan where disabled=0 order by pr)
Sep 28 08:47:16 opensips01 opensips-reg[20519]: DBG:core:db_new_result: 
allocate 48 bytes for result set at 0x7fca723c2cf8
Sep 28 08:47:16 opensips01 opensips-reg[20519]: 
DBG:db_postgres:db_postgres_fetch_result: 0x7fca723c2b60 
PQresultStatus(PGRES_TUPLES_OK) PQgetResult(0x242a680)
Sep 28 08:47:16 opensips01 opensips-reg[20519]: 
DBG:db_postgres:db_postgres_get_columns: 9 columns returned from the query
Sep 28 08:47:16 opensips01 opensips-reg[20519]: DBG:core:db_allocate_columns: 
allocate 252 bytes for result columns at 0x7fca723c2dc0
Sep 28 08:47:16 opensips01 opensips-reg[20519]: 
DBG:db_postgres:db_postgres_get_columns: RES_NAMES(0x7fca723c2e08)[0]=[dpid]
Sep 28 08:47:16 opensips01 opensips-reg[20519]: 
DBG:db_postgres:db_postgres_get_columns: use DB_INT result type
Sep 28 08:47:16 opensips01 opensips-reg[20519]: 
DBG:db_postgres:db_postgres_get_columns: RES_NAMES(0x7fca723c2e18)[1]=[pr]
Sep 28 08:47:16 opensips01 opensips-reg[20519]: 
DBG:db_postgres:db_postgres_get_columns: use DB_INT result type
Sep 28 08:47:16 opensips01 opensips-reg[20519]: 
DBG:db_postgres:db_postgres_get_columns: RES_NAMES(0x7fca723c2e28)[2]=[match_op]
Sep 28 08:47:16 opensips01 opensips-reg[20519]: 
DBG:db_postgres:db_postgres_get_columns: use DB_INT result type
Sep 28 08:47:16 opensips01 opensips-reg[20519]: 
DBG:db_postgres:db_postgres_get_columns: 
RES_NAMES(0x7fca723c2e38)[3]=[match_exp]
Sep 28 08:47:16 opensips01 opensips-reg[20519]: 
DBG:db_postgres:db_postgres_get_columns: use DB_STRING result type
Sep 28 08:47:16 opensips01 opensips-reg[20519]: 
DBG:db_postgres:db_postgres_get_columns: 
RES_NAMES(0x7fca723c2e48)[4]=[match_flags]
Sep 28 08:47:16 opensips01 opensips-reg[20519]: 
DBG:db_postgres:db_postgres_get_columns: use DB_INT result type
Sep 28 08:47:16 opensips01 opensips-reg[20519]: 
DBG:db_postgres:db_postgres_get_columns: 
RES_NAMES(0x7fca723c2e58)[5]=[subst_exp]
Sep 28 08:47:16 opensips01 opensips-reg[20519]: 
DBG:db_postgres:db_postgres_get_columns: use DB_STRING result type
Sep 28 08:47:16 opensips01 opensips-reg[20519]: 
DBG:db_postgres:db_postgres_get_columns: RES_NAMES(0x7fca723c2e68)[6]=[repl_exp]
Sep 28 08:47:16 opensips01 opensips-reg[20519]: 
DBG:db_postgres:db_postgres_get_columns: use DB_STRING result type
Sep 28 08:47:16 opensips01 opensips-reg[20519]: 
DBG:db_postgres:db_postgres_get_columns: RES_NAMES(0x7fca723c2e78)[7]=[attrs]
Sep 28 08:47:16 opensips01 opensips-reg[20519]: 
DBG:db_postgres:db_postgres_get_columns: use DB_STRING result type
Sep 28 08:47:16 opensips01 opensips-reg[20519]: 
DBG:db_postgres:db_postgres_get_columns: RES_NAMES(0x7fca723c2e88)[8]=[timerec]
Sep 28 08:47:16 opensips01 opensips-reg[20519]: 
DBG:db_postgres:db_postgres_get_columns: use DB_STRING result type
Sep 28 08:47:16 opensips01 opensips-reg[20519]: WARNING:dialplan:dp_load_db: no 
data in the db
Sep 28 08:47:16 opensips01 opensips-reg[20513]: DBG:core:handle_sigs: status = 
135
Sep 28 08:47:16 opensips01 opensips-reg[20513]: INFO:core:handle_sigs: child 
process 20519 exited by a signal 7
Sep 28 08:47:16 opensips01 opensips-reg[20513]: INFO:core:handle_sigs: core was 
generated
Sep 28 08:47:16 opensips01 opensips-reg[20513]: INFO:core:handle_sigs: 
terminating due to SIGCHLD
Sep 28 08:47:16 opensips01 opensips-reg[20515]: INFO:core:sig_usr: signal 15 
received
Sep 28 08:47:16 opensips01 opensips-reg[20518]: INFO:core:sig_usr: signal 15 
received
Sep 28 08:47:16 opensips01 opensips-reg[20514]: INFO:core:sig_usr: signal 15 
received
Sep 28 08:47:16 opensips01 opensips-reg[20516]: INFO:core:sig_usr: signal 15 
received
Sep 28 08:47:16 opensips01 opensips-reg[20517]: INFO:core:sig_usr: signal 15 
received
Sep 28 08:47:16 opensips01 opensips-reg[20513]: INFO:core:cleanup: cleanup


Backtrace output is

Core was generated by `/usr/local/opensips_proxy/sbin/opensips -P 
/var/run/opensips/opensips.pid -m 64'.
Program terminated with signal SIGBUS, Bus error.
#0  destroy

Re: [OpenSIPS-Devel] Opensips not responing to options

2015-09-28 Thread Bogdan-Andrei Iancu

Hi Jason,

Try to follow the processing through your script by using the 
script_trace() function:

http://www.opensips.org/Documentation/Script-CoreFunctions-1-11#toc42

Put it in the very beginning of your script.

Regards,

Bogdan-Andrei Iancu
OpenSIPS Founder and Developer
http://www.opensips-solutions.com

On 27.09.2015 14:03, Jason Bedward wrote:

Hi

I have the below but when traffic is coming into my server its not 
responding with 200. Opensips is listening server is on Amazon EC2. 
Please help...


### Routing Logic 

# main request routing logic
route {
# log the basic info regarding this call
xlog("L_DBG", "$ci|start|recieved $oP request $rm $ou");
xlog("L_DBG", "$ci|log|source $si:$sp");
xlog("L_DBG", "$ci|log|from $fu");
xlog("L_DBG", "$ci|log|to $tu");

if(is_method("OPTIONS")) {
# send reply for each options request
sl_send_reply("200", "ok");
exit();
}
else if (!mf_process_maxfwd_header("10")) {
sl_send_reply("483","Too Many Hops");
exit;
}


___
Devel mailing list
Devel@lists.opensips.org
http://lists.opensips.org/cgi-bin/mailman/listinfo/devel


___
Devel mailing list
Devel@lists.opensips.org
http://lists.opensips.org/cgi-bin/mailman/listinfo/devel


Re: [OpenSIPS-Devel] [opensips] running out of pkg_mem (#651)

2015-09-28 Thread Bogdan Andrei IANCU
@etamme , have you tried to enable the memory debugging:
http://www.opensips.org/Documentation/TroubleShooting-OutOfMem
And fire a USR1 signal to the process complaining of lack of memory in order to 
force it to do a mem dump ? Some patterns in the used memory may reveal the 
problem. 

---
Reply to this email directly or view it on GitHub:
https://github.com/OpenSIPS/opensips/issues/651#issuecomment-143692120___
Devel mailing list
Devel@lists.opensips.org
http://lists.opensips.org/cgi-bin/mailman/listinfo/devel


Re: [OpenSIPS-Devel] [opensips] exec: Clarify what not to do with exec(). (#653)

2015-09-28 Thread Ionut Ionita
Merged #653.

---
Reply to this email directly or view it on GitHub:
https://github.com/OpenSIPS/opensips/pull/653#event-420547176___
Devel mailing list
Devel@lists.opensips.org
http://lists.opensips.org/cgi-bin/mailman/listinfo/devel


[OpenSIPS-Devel] [OpenSIPS/opensips] 105107: exec: Clarify what not to do with exec().

2015-09-28 Thread Ionut Ionita
  Branch: refs/heads/master
  Home:   https://github.com/OpenSIPS/opensips
  Commit: 105107548fb76e08e91175a1f5cb70c4ca94e819
  
https://github.com/OpenSIPS/opensips/commit/105107548fb76e08e91175a1f5cb70c4ca94e819
  Author: Walter Doekes 
  Date:   2015-09-27 (Sun, 27 Sep 2015)

  Changed paths:
M modules/exec/README
M modules/exec/doc/exec_admin.xml
M modules/exec/exec.c

  Log Message:
  ---
  exec: Clarify what not to do with exec().

See:
https://github.com/OpenSIPS/opensips/pull/375#discussion-diff-19524753


  Commit: 4488d95a7c418bbff25c5ef2fbd3d5feff702c37
  
https://github.com/OpenSIPS/opensips/commit/4488d95a7c418bbff25c5ef2fbd3d5feff702c37
  Author: Ionut Ionita 
  Date:   2015-09-28 (Mon, 28 Sep 2015)

  Changed paths:
M modules/exec/README
M modules/exec/doc/exec_admin.xml
M modules/exec/exec.c

  Log Message:
  ---
  Merge pull request #653 from wdoekes/wjd-exec_admindoc_safety

exec: Clarify what not to do with exec().


Compare: 
https://github.com/OpenSIPS/opensips/compare/1e1ea149cdad...4488d95a7c41___
Devel mailing list
Devel@lists.opensips.org
http://lists.opensips.org/cgi-bin/mailman/listinfo/devel


Re: [OpenSIPS-Devel] [opensips] Opensips Crash, presentity Module (#646)

2015-09-28 Thread Răzvan Crainea
It looks like OpenSIPS crashed due to an ```abort()``` call.

Can you check the logs if there are any errors?

Best regards,
Răzvan

---
Reply to this email directly or view it on GitHub:
https://github.com/OpenSIPS/opensips/issues/646#issuecomment-143679729___
Devel mailing list
Devel@lists.opensips.org
http://lists.opensips.org/cgi-bin/mailman/listinfo/devel


[OpenSIPS-Devel] [opensips] Tls rework (#654)

2015-09-28 Thread Eseanu Marius Cristian

You can view, comment on, or merge this pull request online at:

  https://github.com/OpenSIPS/opensips/pull/654

-- Commit Summary --

  * add db support for tls
  * tls_mgm: updated readme

-- File Changes --

M modules/proto_tls/proto_tls.c (5)
M modules/proto_tls/tls_server.c (2)
M modules/proto_tls/tls_server.h (4)
M modules/tls_mgm/README (226)
M modules/tls_mgm/api.h (6)
M modules/tls_mgm/doc/tls_mgm.xml (9)
M modules/tls_mgm/doc/tls_mgm_admin.xml (22)
M modules/tls_mgm/doc/tls_mgm_devel.xml (10)
M modules/tls_mgm/tls_config.c (22)
M modules/tls_mgm/tls_config.h (22)
M modules/tls_mgm/tls_domain.c (222)
M modules/tls_mgm/tls_domain.h (18)
M modules/tls_mgm/tls_helper.h (1)
M modules/tls_mgm/tls_mgm.c (483)
M modules/tls_mgm/tls_params.c (134)
M modules/tls_mgm/tls_params.h (24)

-- Patch Links --

https://github.com/OpenSIPS/opensips/pull/654.patch
https://github.com/OpenSIPS/opensips/pull/654.diff

---
Reply to this email directly or view it on GitHub:
https://github.com/OpenSIPS/opensips/pull/654
___
Devel mailing list
Devel@lists.opensips.org
http://lists.opensips.org/cgi-bin/mailman/listinfo/devel