Hi, finally I've discovered the cause of important issues with my
Kamailio deployments which sometimes get frozen "with no reason":
- We use Debian Lenny with rsyslog writting the logs in local files
(/var/log/kamailio.log) and also rsyslog-mysql extension to send the
logs to a remote MySQL server using mysql TCP protocol.
- For "external" reason (external to me) such MySQL server sometimes
fails or it's down.
- Then kamailio tries to log to syslog. rsyslog receives the request
and tries to send it via MySQL. Unfortunatelly it gets frozen as the
DB doesn't work, and it neither writes the log to the local log file
!!! (this is really surprising to me).
- Worse is the fact the rsyslog replies nothing to kamailio process so
the kamailio process gets 100% *blocked* waiting for the response
(this is what I suspect).
- As a dirty workaround, stopping the local rsyslog server makes
kamailio to work again.
So, I think this is mostly a bug in rsyslog-mysql as it shouldn't get
frozen if the MySQL server doesn't work. However I also think that
Kamailio should not depend on it, and perhaps it shouldn't wait
indefinitely for the rsyslog response. What do you think?
Would make sense a "ping" mechanism like with RtpProxy servers in
order to enable/dissable the syslog logging?
Regards.
--
Iñaki Baz Castillo
<ibc(a)aliax.net>
Module: sip-router
Branch: master
Commit: d4031fa7e9ad917969c04f946f8dd986f8ba0e48
URL: http://git.sip-router.org/cgi-bin/gitweb.cgi/sip-router/?a=commit;h=d4031fa…
Author: Daniel-Constantin Mierla <miconda(a)gmail.com>
Committer: Daniel-Constantin Mierla <miconda(a)gmail.com>
Date: Thu Jul 29 14:48:21 2010 +0200
acc_radius(k): new module for RADIUS accounting
- the modules is built out of acc module radius part
- acc module still has the RADIUS accounting inside, available with
RAD_ACC define like so far - subject to be removed if everyone agrees
- this module can be used together with acc avoiding to recompile acc
module to enable RAD_ACC, making at least packaging easier
- same cfg parameters and functions used for radius accounting in acc
module are available in acc_radius
---
modules_k/acc_radius/Makefile | 20 ++
modules_k/acc_radius/README | 195 ++++++++++++
modules_k/acc_radius/acc_radius_mod.c | 416 +++++++++++++++++++++++++
modules_k/acc_radius/acc_radius_mod.h | 39 +++
modules_k/acc_radius/doc/Makefile | 4 +
modules_k/acc_radius/doc/acc_radius.xml | 43 +++
modules_k/acc_radius/doc/acc_radius_admin.xml | 199 ++++++++++++
7 files changed, 916 insertions(+), 0 deletions(-)
Diff: http://git.sip-router.org/cgi-bin/gitweb.cgi/sip-router/?a=commitdiff;h=d40…
Hello,
I have the following transformation on the SDP Body:
$(rb{re.subst,/^(.*)m=audio ([0-9]+) RTP\/AVP ([0-9 ]+)\015\012(.*)$/\3/s})
However when I assign this to an AVP, i.e.
$avp(s:sdp-payloads) = $(rb{re.subst,/^(.*)m=audio ([0-9]+) RTP\/AVP ([0-9
]+)\015\012(.*)$/\3/s});
I receive back a NULL result / transformation "regex does not match" is what
I receive with high verbose syslog on kamailio.
HOWEVER.
When I do something like this:
xlog("L_INFO", "Payloads Available: $(rb{re.subst,/^(.*)m=audio ([0-9]+)
RTP\/AVP ([0-9 ]+)\015\012(.*)$/\3/s})");
It executes properly -- transformation regex matches and the payloads are
displayed as expected.
If anyone can provide any insight as to what I may be doing wrong it would
be greatly appreciated.
P.S. Kamailio SVN Revision # 2:5906M (1.5.2-notls).
Also I CC'ed devel list (as I do believe this may be a bug).
Thanks!
Sincerely,
Brandon Armstead
THIS IS AN AUTOMATED MESSAGE, DO NOT REPLY.
The following task has a new comment added:
FS#81 - patch to add method masking to xlog function
User who did this - Daniel-Constantin Mierla (miconda)
----------
Juha, as you can use different log levels as parameters you can use different variables and have couple of assignments (e.g., $var(dbg), $var(info), ...). That xlog parameter supports static value or variable for so long time, so there is nothing extra that is done.
You can implement your extra functions if these suggestions does not fit you, but the basic functions must stay available to the config, without adding particular needs of filtering - there can be wrappers, same was done for xlogl().
----------
More information can be found at the following URL:
http://sip-router.org/tracker/index.php?do=details&task_id=81#comment105
You are receiving this message because you have requested it from the Flyspray bugtracking system. If you did not expect this message or don't want to receive mails in future, you can change your notification settings at the URL shown above.
THIS IS AN AUTOMATED MESSAGE, DO NOT REPLY.
The following task has a new comment added:
FS#81 - patch to add method masking to xlog function
User who did this - Juha Heinanen (jh)
----------
the proposed solution does not work, because different log messages related to the same request may (and in practice are) printed at different log levels. it it thus not possible to set $var(log) to some given level at top of the main route block. the above test and setting of $var(log) would thus need to be done before each xlog call in the script. in addition, always using a var as the first param of xlog call would be much slower than the simple c if statement inside xlog function.
----------
More information can be found at the following URL:
http://sip-router.org/tracker/index.php?do=details&task_id=81#comment104
You are receiving this message because you have requested it from the Flyspray bugtracking system. If you did not expect this message or don't want to receive mails in future, you can change your notification settings at the URL shown above.
Hello,
after never really having to use sip-router's tm callbacks but
Kamailio's only, I did some tests today and found a few issues I'd like
to discuss followingly:
1) In Kamailio, certain callbacks (namely TMCB_RESPONSE_PRE_OUT,
TMCB_RESPONSE_OUT, and TMCB_REQUEST_BUILT) provided the entire processed
message (i.e., after headers were modified) in tmcb_params->extra1 as
*str. AFAICS, sr's equivalent to that parameter is send_buf in the
tmcb_params structure. However, the only sr callbacks that do provide
the processed messages are TMCB_REQUEST_SENT and TMCB_RESPONSE_SENT
which, had no perfect correspondency in Kamailio (*_OUT callbacks would
not be called for retransmissions).
Technically, this makes complete sense because the two *_SENT callbacks
and the send_buf variable are available only when WITH_ONSEND is
defined. Also, I noticed that these callbacks are handled through
run_onsend_callbacks[2]() instead of run_trans_callbacks(). Only the
former fill send_buf and hence pass processed messages as part of the
callback.
Why do these TMCB_ONSEND callbacks need such special care? Would it be
feasible to pass processed messages for other callbacks somehow too?
Ideally, I'd like to see that happen for every callback where a
processed message is supposed to be available, i.e., all *_OUT and
*_READY callbacks.
2) Is there a special reason why TMCB_REQUEST_OUT is missing? Kamailio
used to have it although it's name TMCB_REQUEST_BUILT was a little
misleading.
3) Similarly, how hard would it be to implement TMCB_REQUEST_READY?
Kamailio lacked that but I'd truly love to see it exist in sr.
Sorry for the abundance of questions and lack of solutions -- when I had
just started to get a rough idea of how Kamailio's tm module works
internally, here comes sr and forces me to start over again. :)
TIA and
cheers,
--Timo
Patches item #3035778, was opened at 2010-07-28 09:04
Message generated for change (Comment added) made by ibc_sf
You can respond by visiting:
https://sourceforge.net/tracker/?func=detail&atid=743022&aid=3035778&group_…
Please note that this message will contain a full copy of the comment thread,
including the initial issue submission, for this request,
not just the latest update.
Category: modules
Group: ver 1.5.x
>Status: Closed
>Resolution: Invalid
Priority: 5
Private: No
Submitted By: Alex Hermann (axlh)
Assigned to: Nobody/Anonymous (nobody)
Summary: Fix registrar when fetching binding for unregistered user
Initial Comment:
When an UA fetches the bindings for a user and the user isn't registered, properly return an empty contact.
----------------------------------------------------------------------
>Comment By: Iñaki Baz Castillo (ibc_sf)
Date: 2010-07-28 12:29
Message:
A "Contact" header with no value is *not* valid according to SIP BNF
grammar so in case a UA fetches its bindging and there are not bindings
then the registrar should reply a 200 without "Contact" header. Taking this
into account I suspect that this patch is wrong.
As a side note, there is a bug/issue open for RFC 3261 related to this
topic as the RFC 3261 seems to state that the registrar should reply a
200 with a Contact header containing all the bindings. But it's clear
(also in the RFC bug report) that the BNF grammar cannot be violated
so there should be NO Contact header if there are no bindings.
I close this bug as it not valid. However as Daniel said please use
http://sip-router.org/tracker/ for future reports :)
----------------------------------------------------------------------
Comment By: Daniel-Constantin Mierla (miconda)
Date: 2010-07-28 09:07
Message:
Can you use the tracker at sip-router.org?
http://sip-router.org/tracker/
SF tracker should not be used anymore for new items.
----------------------------------------------------------------------
You can respond by visiting:
https://sourceforge.net/tracker/?func=detail&atid=743022&aid=3035778&group_…
Patches item #3035778, was opened at 2010-07-28 10:04
Message generated for change (Comment added) made by miconda
You can respond by visiting:
https://sourceforge.net/tracker/?func=detail&atid=743022&aid=3035778&group_…
Please note that this message will contain a full copy of the comment thread,
including the initial issue submission, for this request,
not just the latest update.
Category: modules
Group: ver 1.5.x
Status: Open
Resolution: None
Priority: 5
Private: No
Submitted By: Alex Hermann (axlh)
Assigned to: Nobody/Anonymous (nobody)
Summary: Fix registrar when fetching binding for unregistered user
Initial Comment:
When an UA fetches the bindings for a user and the user isn't registered, properly return an empty contact.
----------------------------------------------------------------------
>Comment By: Daniel-Constantin Mierla (miconda)
Date: 2010-07-28 10:07
Message:
Can you use the tracker at sip-router.org?
http://sip-router.org/tracker/
SF tracker should not be used anymore for new items.
----------------------------------------------------------------------
You can respond by visiting:
https://sourceforge.net/tracker/?func=detail&atid=743022&aid=3035778&group_…
Patches item #3035808, was opened at 2010-07-28 10:13
Message generated for change (Tracker Item Submitted) made by axlh
You can respond by visiting:
https://sourceforge.net/tracker/?func=detail&atid=743022&aid=3035808&group_…
Please note that this message will contain a full copy of the comment thread,
including the initial issue submission, for this request,
not just the latest update.
Category: modules
Group: ver 1.5.x
Status: Open
Resolution: None
Priority: 5
Private: No
Submitted By: Alex Hermann (axlh)
Assigned to: Nobody/Anonymous (nobody)
Summary: Add rfc1918 test for source ip to nat_uac_test
Initial Comment:
Expand nathelper function nat_uac_test with function to test for rfc1918 address in source ip of SIP message.
Move some code to helper functions to prevent duplication of code.
----------------------------------------------------------------------
You can respond by visiting:
https://sourceforge.net/tracker/?func=detail&atid=743022&aid=3035808&group_…