Re: [OpenSIPS-Users] Bypass UAC IP

2009-12-23 Thread Bogdan-Andrei Iancu
Hi Ahmed,

If Asterisk dislpays the IP from the network level, you cannot change 
it. Otherwise you can do a trick and make opensips to place the UAC IP 
into a SIP header to be passed to Asterisk and maybe you can "convince" 
Asterisk to display the IP from the header.

Regards,
Bogdan

Ahmed Munir wrote:
> Hi,
>
> I want to know how can I bypass UAC IP through OpenSIPS. Like my UAC 
> IP is xx.xx.xx.xx, my OpenSIPS IP is yy.yy.yy.yy and Asterisk IP is 
> zz.zz.zz.zz, where I'm using OpenSIPs as redirect server, when I make 
> a call I want UAC IP displayed on Asterisk machine not OpenSIPs IP.
>
> Kindly advise me which fuction do I require for it. The configuration 
> I've done is listed down below;
>
> route{
>
> if (!mf_process_maxfwd_header("10")) {
> sl_send_reply("483","Too Many Hops");
> exit;
> }
>
> if (is_method("INVITE")) {
> log("INVITE###");
> ds_select_domain("1","4");
> sl_send_reply("300","Redirect");
> route(1);
> log("#END");
> exit;
> }
>
> if (is_method("REGISTER")) {
> log("REGISTER###");
> ds_select_dst("1","4");
> #t_replicate("77.66.2.136");
> #sl_send_reply("200", "ok");
> forward();
> log("#END");
> #exit;
> return;
> }
>
> }
>
>
> -- 
> Regards,
>
> Ahmed Munir
>
>
> 
>
> ___
> Users mailing list
> Users@lists.opensips.org
> http://lists.opensips.org/cgi-bin/mailman/listinfo/users
>   


-- 
Bogdan-Andrei Iancu
www.voice-system.ro


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


[OpenSIPS-Users] Bypass UAC IP

2009-12-23 Thread Ahmed Munir
Hi,

I want to know how can I bypass UAC IP through OpenSIPS. Like my UAC IP is
xx.xx.xx.xx, my OpenSIPS IP is yy.yy.yy.yy and Asterisk IP is zz.zz.zz.zz,
where I'm using OpenSIPs as redirect server, when I make a call I want UAC
IP displayed on Asterisk machine not OpenSIPs IP.

Kindly advise me which fuction do I require for it. The configuration I've
done is listed down below;

route{

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

if (is_method("INVITE")) {
log("INVITE###");
ds_select_domain("1","4");
sl_send_reply("300","Redirect");
route(1);
log("#END");
exit;
}

if (is_method("REGISTER")) {
log("REGISTER###");
ds_select_dst("1","4");
#t_replicate("77.66.2.136");
#sl_send_reply("200", "ok");
forward();
log("#END");
#exit;
return;
}

}


-- 
Regards,

Ahmed Munir
___
Users mailing list
Users@lists.opensips.org
http://lists.opensips.org/cgi-bin/mailman/listinfo/users


[OpenSIPS-Users] Authentication problem

2009-12-23 Thread Daniel Goepp
I am having another issue with this latest version also, and I believe it
could perhaps be related to my last post.  Very straight forward here, I
have just two users on this new lab system.

The problem:

First register comes in, challenged with 401 no problem, then a register
with auth header, which is responded to with:

SIP/2.0 403 Forbidden auth ID.

I did an SQL trace, and the query is select password from subscriber where
username='2001':

When I execute manually, no problem:

mysql> select password from subscriber where username='2001';
+--+
| password |
+--+
| 2001 |
+--+

Did something change recently regarding how users are auth'd?  This is a
very very basic setup, pretty much out of the box.  And ideas about what
boneheaded thing I have done here?

Thanks

-dg
___
Users mailing list
Users@lists.opensips.org
http://lists.opensips.org/cgi-bin/mailman/listinfo/users


[OpenSIPS-Users] Error on new install

2009-12-23 Thread Daniel Goepp
I'm setting up a new system here, same as all my other ones, this one is the
latest version 1.6.1 checked out today.  The config is basically just the
default config, I haven't changed much, just deleted presence related stuff,
and uncommented db support for aliases and domains, same as all my other
systems.  But I'm now getting this error:

Dec 23 15:35:06 ip-10-160-23-47 /usr/local/sbin/opensips[19213]:
INFO:alias_db:mod_init: initializing...
Dec 23 15:35:06 ip-10-160-23-47 /usr/local/sbin/opensips[19213]:
ERROR:uri:db_checks_fixup: configuration error - no database URL is
configured!
Dec 23 15:35:06 ip-10-160-23-47 /usr/local/sbin/opensips[19213]:
ERROR:core:fix_actions: fixing failed (code=-6) at cfg line 165
Dec 23 15:35:06 ip-10-160-23-47 /usr/local/sbin/opensips[19213]:
CRITICAL:core:fix_expr: fix_actions error
Dec 23 15:35:06 ip-10-160-23-47 /usr/local/sbin/opensips[19213]:
ERROR:core:main: failed to fix configuration with err code -6

I get this when I change the check_to and check_from to be prepended with
db_ (not sure why the default config in 1.6.1 still has the old method
names).

The only docs I found were:

http://www.opensips.org/html/docs/modules/1.6.x/uri_db.html
http://www.opensips.org/html/docs/modules/1.6.x/uri.html

As per the uri_db module (still with the old method names) I tried to set:

modparam("uri_db", "db_url", "mysql://opensips:opensip...@localhost
/opensips")

But I still get the same error, I had to change this to:

modparam("uri", "db_url", "mysql://opensips:opensip...@localhost/opensips")

That is a parameter for the uri module though, not the uri_db module.  And
was not necessary to set in previous versions, and is not in the template
config.  I am very confused at this point the line between these two
modules.  Anyone have any clarification they can provide on this?  I'm up
and running but would like to understand this better.

Thanks

-dg
___
Users mailing list
Users@lists.opensips.org
http://lists.opensips.org/cgi-bin/mailman/listinfo/users


Re: [OpenSIPS-Users] CDRtool freeradius mysql error

2009-12-23 Thread osiris123d

One more bit of info.

If I start freeradius in debug mode I see the following

CDRTool:/etc/init.d# freeradius -X
Starting - reading configuration files ...
reread_config:  reading radiusd.conf
Config:   including file: /etc/freeradius/proxy.conf
Config:   including file: /etc/freeradius/clients.conf
Config:   including file: /etc/freeradius/snmp.conf
Config:   including file: /etc/freeradius/sql.conf
 main: prefix = "/usr"
 main: localstatedir = "/var"
 main: logdir = "/var/log/freeradius"
 main: libdir = "/usr/lib/freeradius"
 main: radacctdir = "/var/log/freeradius/radacct"
 main: hostname_lookups = no
 main: snmp = no
 main: max_request_time = 6
 main: cleanup_delay = 5
 main: max_requests = 1024
 main: delete_blocked_requests = 0
 main: port = 0
 main: allow_core_dumps = no
 main: log_stripped_names = no
 main: log_file = "/var/log/freeradius/radius.log"
 main: log_auth = no
 main: log_auth_badpass = no
 main: log_auth_goodpass = no
 main: pidfile = "/var/run/freeradius/freeradius.pid"
 main: bind_address = 12.*.*.218 IP address [12.*.*.218]
 main: user = "freerad"
 main: group = "freerad"
 main: usercollide = no
 main: lower_user = "no"
 main: lower_pass = "no"
 main: nospace_user = "no"
 main: nospace_pass = "no"
 main: checkrad = "/usr/sbin/checkrad"
 main: proxy_requests = yes
 proxy: retry_delay = 1
 proxy: retry_count = 5
 proxy: synchronous = no
 proxy: default_fallback = yes
 proxy: dead_time = 120
 proxy: post_proxy_authorize = yes
 proxy: wake_all_if_all_dead = no
 security: max_attributes = 200
 security: reject_delay = 1
 security: status_server = no
 main: debug_level = 0
read_config_files:  reading dictionary
read_config_files:  reading naslist
Using deprecated naslist file.  Support for this will go away soon.
read_config_files:  reading clients
read_config_files:  reading realms
radiusd:  entering modules setup
Module: Library search path is /usr/lib/freeradius
Module: Loaded preprocess 
 preprocess: huntgroups = "/etc/freeradius/huntgroups"
 preprocess: hints = "/etc/freeradius/hints"
 preprocess: with_ascend_hack = no
 preprocess: ascend_channels_per_line = 23
 preprocess: with_ntdomain_hack = no
 preprocess: with_specialix_jetstream_hack = no
 preprocess: with_cisco_vsa_hack = no
 preprocess: with_alvarion_vsa_hack = no
Module: Instantiated preprocess (preprocess) 
Module: Loaded Acct-Unique-Session-Id 
 acct_unique: key = "Acct-Session-Id, Client-IP-Address, Sip-From-Tag,
Sip-To-Tag"
Module: Instantiated acct_unique (acct_unique) 
Module: Loaded realm 
 realm: format = "suffix"
 realm: delimiter = "@"
 realm: ignore_default = no
 realm: ignore_null = no
Module: Instantiated realm (suffix) 
Module: Loaded detail 
 detail: detailfile =
"/var/log/freeradius/radacct/%{Client-IP-Address}/detail-%Y%m%d"
 detail: detailperm = 384
 detail: dirperm = 493
 detail: locking = no
Module: Instantiated detail (detail) 
Module: Loaded SQL 
 sql: driver = "rlm_sql_mysql"
 sql: server = "12.*.*.218"
 sql: port = "3306"
 sql: login = "radius"
 sql: password = "cdrt00l1234"
 sql: radius_db = "radius"
 sql: nas_table = "nas"
 sql: sqltrace = no
 sql: sqltracefile = "/var/log/freeradius/sqltrace-%Y%m%d.log"
 sql: readclients = no
 sql: deletestalesessions = no
 sql: num_sql_socks = 25
 sql: sql_user_name = ""
 sql: default_user_profile = ""
 sql: query_on_not_found = no
 sql: authorize_check_query = ""
 sql: authorize_reply_query = ""
 sql: authorize_group_check_query = ""
 sql: authorize_group_reply_query = ""
 sql: accounting_onoff_query = ""
 sql: accounting_update_query = "  CALL
update_raddact_record_mediaproxy( 'radius',
'%{Acct-Session-Time}', '%{Acct-Input-Octets}',
'%{Acct-Output-Octets}', '%{Sip-User-Agents}',
'%{Media-Codecs}', '%{Sip-Application-Type}',
'%{Media-Info}', '0', '%{Acct-Session-Id}', 
   
'%{Sip-To-Tag}', '%{Sip-From-Tag}' )"
 sql: accounting_update_query_alt = ""
 sql: accounting_start_query = "  CALL insert_radacct_record(   
 
'radius', '%{Acct-Session-Id}',
'%{Acct-Unique-Session-Id}', '%{Billing-Party}',
'%{Billing-Party}', '%{SIP-Proxy-IP}',
'%{NAS-Port}', '%S', '0',
'0', '0', '0',
'%{Called-Station-Id}', '%{Calling-Station-Id}',
'%{Sip-Response-Code}', '%{Service-Type}',
'%{ENUM-TLD}', '%{Framed-IP-Address}',
'%{Acct-Delay-Time}', '0',
'%{Sip-Response-Code}', '%{Sip-Method}',
'%{Sip-Translated-Request-URI}', '%{Sip-To-Tag}',   
 
'%{Sip-From-Tag}', '%{Si

Re: [OpenSIPS-Users] AVP DB Query

2009-12-23 Thread osiris123d

I believe you will want to look into the memcache module in OpenSIPS 1.6. 
There is also a tutorial for this on the OpenSIPS documentation page.

Hope thats what you were looking for.



Antonio Anderson M. de Souza wrote:
> 
> Dear all,
> 
> The SQL query used to get the data from the database is executed
> syncronaly
> with the avp_db_load, every call to the avp_db_load will trigger a SQL
> Query
> in the dadatbase, or there are some cache in memory to minimize the
> database
> access to load AVPs?
> 
> Thank you very much,
> 
> Antonio Anderson M. Souza
> Voice Technology
> http://www.antonioams.com
> 
> ___
> Users mailing list
> Users@lists.opensips.org
> http://lists.opensips.org/cgi-bin/mailman/listinfo/users
> 
> 

-- 
View this message in context: 
http://n2.nabble.com/AVP-DB-Query-tp4210415p4210511.html
Sent from the OpenSIPS - Users mailing list archive at Nabble.com.

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


[OpenSIPS-Users] AVP DB Query

2009-12-23 Thread Antonio Anderson M. de Souza
Dear all,

The SQL query used to get the data from the database is executed syncronaly
with the avp_db_load, every call to the avp_db_load will trigger a SQL Query
in the dadatbase, or there are some cache in memory to minimize the database
access to load AVPs?

Thank you very much,

Antonio Anderson M. Souza
Voice Technology
http://www.antonioams.com
___
Users mailing list
Users@lists.opensips.org
http://lists.opensips.org/cgi-bin/mailman/listinfo/users


Re: [OpenSIPS-Users] Opensips 1.6.1 dos not start on Ubuntu 9.1 64bits

2009-12-23 Thread Antonio Anderson M. de Souza
Hi Brian,

A correction I'm using the 1.6.0 version i downloaded it from
http://opensips.org/pub/opensips/1.6.0/src/

Using the 1.6.0 version I removed the dialplan module from the script and
Opensips started properly, after that i updated the opensips to the 1.6.1
version, but in the 1.6.1 it stop when initiating the drouting module (log
bellow)

Dec 23 15:48:03 asouza-laptop opensips[24702]: INFO:dialog:mod_init: Dialog
module - initializinger
Dec 23 15:48:03 asouza-laptop opensips[24702]: NOTICE:signaling:mod_init:
initializing module ...
Dec 23 15:48:03 asouza-laptop opensips[24702]: INFO:drouting:dr_init:
Dynamic-Routing - initializing

I rolledback the version to 1.6.0, but i need dialplan module running in my
script.

There are some other level of logs to activate, to try to understand what is
happening?

Regarding the permission module Warnings, I am using the permissions module
with the database, because this i did'nt configure the permission files.

Thank you very much,

Antonio Anderson M. Souza
Voice Technology
http://www.antonioams.com


On Wed, Dec 23, 2009 at 2:59 PM,  wrote:

>
> Hello Antonio,
>
> An mer., déc 23, 2009, Antonio Anderson M. de Souza schrieb:
> >I've installed the Opensips 1.6.1 on my Ubuntu 9.10 64bits form the
> >source, the installation was done without any problem.
> >
> >Opensips abnormally stops during the initialization of Dialplan
> >module (follows logs bellow)
> >
> >Dec 23 13:38:30 asouza-laptop opensips[7233]: NOTICE:core:main: version:
> opensips 1.6.0-notls (x86_64/linux)
> >[...]
> >Dec 23 13:38:30 asouza-laptop opensips[7233]:
> WARNING:permissions:parse_config_file: file not found:
> /usr/local/etc/opensips/permissions.allow
> >[...]
> >*Dec 23 13:38:30 asouza-laptop opensips[7233]: INFO:dialplan:mod_init:
> initializing module...*
> >
> >The bold line is the last line before the process terminates, but
> >there are no error in the initialization process.
> >
> >Does somebody has some clue about thie problem?
> >
> What happens if you don't use the dialplan, does the process still
> terminate in the same place?
>
> And is the string '1.6.0' an error in your logs or are you sure that
> you've compiled the latest release (1.6.1)? I seem to remember that
> the debian unstable repository had a problem with version numbers
> for a day or so, maybe you really are using the latest release.
>
> Lastly (but probably unimportant) you might first get rid of the
> warning message. If you are using the permissions module then
> configure it correctly by placing the file 'permissions.allow'
> where OpenSIPS expects it.
>
> Regards,
> Brian
>
> ___
> Users mailing list
> Users@lists.opensips.org
> http://lists.opensips.org/cgi-bin/mailman/listinfo/users
>
___
Users mailing list
Users@lists.opensips.org
http://lists.opensips.org/cgi-bin/mailman/listinfo/users


Re: [OpenSIPS-Users] CDRtool freeradius mysql error

2009-12-23 Thread osiris123d

I edited /etc/mysql/my.cnf with the following

server-id = 1
log_bin = /var/log/mysql/mysql-bin.log
binlog_do_db = include_database_name
binlog_ignore_db = include_database_name

When I restart mysql the following file is created under /var/log/mysql
mysql-bin.01

But when I start up /etc/init.d/cdrtool start and /etc/init.d/freeradius  
start
nothing shows up in the log file all that is there is
CDRTool:/var/log/mysql# more mysql-bin.01
KˆN2KuK^b5.0.51a-24+lenny2-logJ2K8


Thats it. :(

When is the radacctMM created? Is it when cdrtool is started or when  
freeradius is started?? I see in the /etc/cron.d/cdrtool file that the  
following are commented out
# Next two jobs are only used when using a central radacct table:
# 0 3 1 * * root php /var/www/CDRTool/scripts/OpenSIPS/rotateTables.php  
>/dev/null
# 0 4 * * * root php /var/www/CDRTool/scripts/purgeTables.php >/dev/null

but the rotateTables looks like it would only create the new months table  
on the first of the month. So that can't be my issue, but I am guessing  
that this does need to be uncommented for future table creations correct?


On Dec 23, 2009 10:24am, "Saul Ibarra Corretge [via OpenSIPS (Open SIP  
Server)]"  wrote:




> On 23/12/09 4:40 PM, osiris123d wrote:


> >


> > It still isn't working. The radacctMM table is never created in the


> > radius database. I have logging turned on in MySQL and I never see the


> > radius user execute the INSERT command to create the database. Can you


> > explain to me when exactly does the radacctMM database get created?


> > That way I could pinput what is going on and why it's not working.


> >



> The tables get created by the stored procedure. Enable binary logging of


> stored procedures to see if you are getting an error there.




> Regards,



> --


> Saúl Ibarra Corretgé


> AG Projects



> ___


> Users mailing list


> [hidden email]


> http://lists.opensips.org/cgi-bin/mailman/listinfo/users









> View message @  
> http://n2.nabble.com/CDRtool-freeradius-mysql-error-tp4200490p4209391.html




> To unsubscribe from Re: CDRtool freeradius mysql error, click here.








-- 
View this message in context: 
http://n2.nabble.com/CDRtool-freeradius-mysql-error-tp4200490p4209672.html
Sent from the OpenSIPS - Users mailing list archive at Nabble.com.
___
Users mailing list
Users@lists.opensips.org
http://lists.opensips.org/cgi-bin/mailman/listinfo/users


[OpenSIPS-Users] Help with the dialog module please

2009-12-23 Thread opensipslist

Hello list,

Does the dialog module define a dialog as from the:

  First INVITE that appears with Call-ID '1234'

...or

  Second INVITE that appears with Call-ID '1234'

I'm asking because if a unauthenticated INVITE arrives the sending
UAC will be forced to send a second INVITE (with a new cseq) that
includes authentication credentials. If the second INVITE with its
auth credentials is accepted, then I assume that the dialog begins.
It therefore follows that the first INVITE will not be included in
the dialog modules table of dialogs, and will be ignored in the
dialog context. Is that right?

What I'm trying to do is set_dlg_flag("20") in the first INVITE and
then read is_dlg_flag_set("20") in the next one. It would be
convenient if the first INVITE began the dialog and the second
INVITE was considered part of the dialog as well. Is this possible?

Can I change some SIP header of the second INVITE to match the
first, so that the dialog module believes them both to be in the
same dialog?

Another question, is there any difference between:

modparam("dialog", "dlg_flag", 4)
route {
setflag(4);
}

...and

route {
create_dialog();
}

Are they completely interchangeable? Does this make sense:

modparam("dialog", "dlg_flag", 4)
route {
setflag(4);
create_dialog();
}

Thanks,
Brian

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


Re: [OpenSIPS-Users] Opensips 1.6.1 dos not start on Ubuntu 9.1 64bits

2009-12-23 Thread opensipslist

Hello Antonio,

An mer., déc 23, 2009, Antonio Anderson M. de Souza schrieb:
>I've installed the Opensips 1.6.1 on my Ubuntu 9.10 64bits form the
>source, the installation was done without any problem.
>
>Opensips abnormally stops during the initialization of Dialplan
>module (follows logs bellow)
>
>Dec 23 13:38:30 asouza-laptop opensips[7233]: NOTICE:core:main: version: 
>opensips 1.6.0-notls (x86_64/linux)
>[...]
>Dec 23 13:38:30 asouza-laptop opensips[7233]: 
>WARNING:permissions:parse_config_file: file not found: 
>/usr/local/etc/opensips/permissions.allow
>[...]
>*Dec 23 13:38:30 asouza-laptop opensips[7233]: INFO:dialplan:mod_init: 
>initializing module...*
>
>The bold line is the last line before the process terminates, but
>there are no error in the initialization process.
>
>Does somebody has some clue about thie problem?
>
What happens if you don't use the dialplan, does the process still
terminate in the same place?

And is the string '1.6.0' an error in your logs or are you sure that
you've compiled the latest release (1.6.1)? I seem to remember that
the debian unstable repository had a problem with version numbers
for a day or so, maybe you really are using the latest release.

Lastly (but probably unimportant) you might first get rid of the
warning message. If you are using the permissions module then
configure it correctly by placing the file 'permissions.allow'
where OpenSIPS expects it.

Regards,
Brian

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


Re: [OpenSIPS-Users] CDRtool freeradius mysql error

2009-12-23 Thread Saúl Ibarra Corretgé
On 23/12/09 4:40 PM, osiris123d wrote:
>
> It still isn't working.  The radacctMM table is never created in the
> radius database.  I have logging turned on in MySQL and I never see the
> radius user execute the INSERT command to create the database.  Can you
> explain to me when exactly does the radacctMM database get created?
> That way I could pinput what is going on and why it's not working.
>

The tables get created by the stored procedure. Enable binary logging of 
stored procedures to see if you are getting an error there.


Regards,

-- 
Saúl Ibarra Corretgé
AG Projects

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


[OpenSIPS-Users] Opensips 1.6.1 dos not start on Ubuntu 9.1 64bits

2009-12-23 Thread Antonio Anderson M. de Souza
Dear All,

I've installed the Opensips 1.6.1 on my Ubuntu 9.10 64bits form the source,
the installation was done without any problem.

Opensips abnormally stops during the initialization of Dialplan module
(follows logs bellow)

Dec 23 13:38:30 asouza-laptop opensips[7233]: NOTICE:core:main: version:
opensips 1.6.0-notls (x86_64/linux)
Dec 23 13:38:30 asouza-laptop opensips[7233]: INFO:core:main: using 32 Mb
shared memory
Dec 23 13:38:30 asouza-laptop opensips[7233]: INFO:core:main: using 1 Mb
private memory per process
Dec 23 13:38:30 asouza-laptop opensips[7233]: INFO:sl:mod_init: Initializing
StateLess engine
Dec 23 13:38:30 asouza-laptop opensips[7233]: INFO:tm:mod_init: TM -
initializing...
Dec 23 13:38:30 asouza-laptop opensips[7233]: INFO:maxfwd:mod_init:
initializing...
Dec 23 13:38:30 asouza-laptop opensips[7233]: INFO:usrloc:ul_init_locks:
locks array size 512
Dec 23 13:38:30 asouza-laptop opensips[7233]: INFO:textops:mod_init:
initializing...
Dec 23 13:38:30 asouza-laptop opensips[7233]: INFO:xlog:mod_init:
initializing...
Dec 23 13:38:30 asouza-laptop opensips[7233]: INFO:acc:mod_init:
initializing...
Dec 23 13:38:30 asouza-laptop opensips[7233]: INFO:auth:mod_init:
initializing...
Dec 23 13:38:30 asouza-laptop opensips[7233]: INFO:auth_db:mod_init:
initializing...
Dec 23 13:38:30 asouza-laptop opensips[7233]: INFO:alias_db:mod_init:
initializing...
Dec 23 13:38:30 asouza-laptop opensips[7233]: INFO:uac:mod_init:
initializing...
Dec 23 13:38:30 asouza-laptop opensips[7233]: INFO:avpops:avpops_init:
initializing...
Dec 23 13:38:30 asouza-laptop opensips[7233]:
WARNING:permissions:parse_config_file: file not found:
/usr/local/etc/opensips/permissions.allow
Dec 23 13:38:30 asouza-laptop opensips[7233]: WARNING:permissions:mod_init:
default allow file (/usr/local/etc/opensips/permissions.allow) not found =>
empty rule set
Dec 23 13:38:30 asouza-laptop opensips[7233]:
WARNING:permissions:parse_config_file: file not found:
/usr/local/etc/opensips/permissions.deny
Dec 23 13:38:30 asouza-laptop opensips[7233]: WARNING:permissions:mod_init:
default deny file (/usr/local/etc/opensips/permissions.deny) not found =>
empty rule set
Dec 23 13:38:30 asouza-laptop opensips[7233]: WARNING:core:mk_net: invalid
network address/netmask combination fixed...
Dec 23 13:38:30 asouza-laptop opensips[7233]: INFO:dialog:mod_init: Dialog
module - initializing
Dec 23 13:38:30 asouza-laptop opensips[7233]: NOTICE:signaling:mod_init:
initializing module ...
Dec 23 13:38:30 asouza-laptop opensips[7233]: INFO:drouting:dr_init:
Dynamic-Routing - initializing
*Dec 23 13:38:30 asouza-laptop opensips[7233]: INFO:dialplan:mod_init:
initializing module...*

The bold line is the last line before the process terminates, but there are
no error in the initialization process.

Does somebody has some clue about thie problem?

Thank you very much,

Antonio Anderson M. Souza
Voice Technology
http://www.antonioams.com
___
Users mailing list
Users@lists.opensips.org
http://lists.opensips.org/cgi-bin/mailman/listinfo/users


Re: [OpenSIPS-Users] CDRtool freeradius mysql error

2009-12-23 Thread osiris123d

It still isn't working.  The radacctMM table is never created in the
radius database.  I have logging turned on in MySQL and I never see the
radius user execute the INSERT command to create the database.  Can you
explain to me when exactly does the radacctMM database get created? 
That way I could pinput what is going on and why it's not working.



Saul Ibarra Corretge wrote:
> 
> Hi,
> 
> On 22/12/09 9:24 PM, osiris123d wrote:
>>
>> Also in the /var/www/CDRTool/setup/radius/radius_accounting.proc file at
>> the
>> very end you have some testing statements
>>
>> when I get into mysql and copy and paste one I get an error
>>
>> mysql -u root -pPASSWORD -h localhost radius
>> Welcome to the MySQL monitor.  Commands end with ; or \g.
>> Your MySQL connection id is 150
>> Server version: 5.0.51a-24+lenny2-log (Debian)
>>
>> Type 'help;' or '\h' for help. Type '\c' to clear the buffer.
>>
>> mysql>  CALL insert_radacct_record (
>>  ->  'radius','3c3b5ff12bf2-m5udeydrj...@snom320-000413241247',
>> '5af53194787eccf1',
>>  ->  'a...@umts.ro', 'a...@umts.ro', '83.149.75.105', '5060',
>> '2006-12-10
>> 12:09:19',
>>  ->  '0', '0', '0', '0', 'sip:3...@umts.ro=3buser=3dphone',
>>  ->  'sip:a...@umts.ro', '200', 'Sip-Session', '', '', '0', '0',
>> '200',
>> 'Invite',
>>  ->  'sip:3...@vm01.dns-hosting.info', 'as5664a60b', '27qems1o2j',
>>  ->  '31208005169', '81.23.228.147', '5060',
>>  ->  'sip:3...@vm01.dns-hosting.info', '', '', 'audio'
>>  ->  );
>> ERROR 1318 (42000): Incorrect number of arguments for PROCEDURE
>> radius.insert_radacct_record; expected 34, got 32
>> mysql>  CALL insert_radacct_record (
>>  ->  'radius','46477473...@blink-41247', '5af53194787eccf1',
>>  ->  'a...@umts.ro', 'a...@umts.ro', '83.149.75.105', '5060',
>> '2009-12-14
>> 12:09:19',
>>  ->  '0', '0', '0', '0', 'sip:3...@umts.ro',
>>  ->  'sip:a...@umts.ro', '200', 'Sip-Session', '', '', '0', '0',
>> '200',
>> 'Invite',
>>  ->  'sip:t...@umts.ro', 'a60bsss', 'qe222ms1o2j',
>>  ->  '208005169', '81.23.228.147', '5060',
>>  ->  'sip:t...@umts.ro', '', '', 'chat'
>>  ->  );
>> ERROR 1318 (42000): Incorrect number of arguments for PROCEDURE
>> radius.insert_radacct_record; expected 34, got 32
>>
> 
> You were right, there was an error in the testing statements, it's 
> already fixed in darcs.
> 
> The error was only in the testing statements, so the system should be 
> working fine for you regardless of that. According to your previous 
> email, your installation is right, so did you have any problem with it 
> after you reinstalled it?
> 
> 
> 
> Regards,
> 
> 
> -- 
> Saúl Ibarra Corretgé
> AG Projects
> 
> ___
> Users mailing list
> Users@lists.opensips.org
> http://lists.opensips.org/cgi-bin/mailman/listinfo/users
> 
> 

-- 
View this message in context: 
http://n2.nabble.com/CDRtool-freeradius-mysql-error-tp4200490p4209195.html
Sent from the OpenSIPS - Users mailing list archive at Nabble.com.

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


Re: [OpenSIPS-Users] Disabling TCP or UDP (RFC forbidden)

2009-12-23 Thread opensipslist

Hello Samuel,

An mer., déc 23, 2009, samuel schrieb:
>TCP is very resource demanding and for those situations where the
>server is not required to work with TCP is very usefull to have the
>option of disabling TCP part.
>
>There are examples, such as embedded platforms with controlled SIP
>UA connecting to it where there's no need for TCP stuff and lots of
>resources are available for other processes.
>
>Not much related to RFCs...
>
Normally the RFC standardization process considers such topics as
'how practical a protocol will be in the network landscape.' No idea
why they wrote 'MUST' and not 'SHOULD' for the parts of implementing
the SIP protocol over both UDP and TCP.

Anyway, I'm guessing that the core OpenSIPS developers (are you
one?) have chosen their policy based on your logic. I don't see
the reason however, that if they're willing to forego the RFC
recommendation for TCP that they shouldn't do the same for UDP.
That would at least be more intuitive.

Regards,
Brian

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


Re: [OpenSIPS-Users] mediaproxy DB

2009-12-23 Thread Saúl Ibarra Corretgé
Hi,

On 22/12/09 10:30 AM, Darshak Modi wrote:
> Ok. But in config.ini, I have only radius based accounting.
>
> [Database]
> ; This section needs to be configured if database accounting is enabled
>
> ; Database URI in the form: scheme://user:passw...@host/database
> ;dburi = mysql://mediaproxy:mediapr...@localhost/mediaproxy
>
> Do I need to enable this?
>

Yes, the radius accounting just adds a few attributes, but if you want 
the whole media session information displayed in CDRTool (the media 
trace) you need to enable the database backend, and MediaProxy itself 
will generate the database for you.

> AND in CDRTool-global.inc I have to set the username/pass as specified
> above?
>
>
> class DB_mediaproxy extends DB_Sql {
>var $Host = "sipdb";
>var $Database = "mediaproxy";
>var $User = "mediaproxy";
>var $Password = "mediaproxy";
>var $Halt_On_Error ="yes";
> }
>

Yes, you need to specify a user which an access the database in which 
the media_sessions table is.


Regards,


-- 
Saúl Ibarra Corretgé
AG Projects

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


Re: [OpenSIPS-Users] CDRtool freeradius mysql error

2009-12-23 Thread Saúl Ibarra Corretgé
Hi,

On 22/12/09 9:24 PM, osiris123d wrote:
>
> Also in the /var/www/CDRTool/setup/radius/radius_accounting.proc file at the
> very end you have some testing statements
>
> when I get into mysql and copy and paste one I get an error
>
> mysql -u root -pPASSWORD -h localhost radius
> Welcome to the MySQL monitor.  Commands end with ; or \g.
> Your MySQL connection id is 150
> Server version: 5.0.51a-24+lenny2-log (Debian)
>
> Type 'help;' or '\h' for help. Type '\c' to clear the buffer.
>
> mysql>  CALL insert_radacct_record (
>  ->  'radius','3c3b5ff12bf2-m5udeydrj...@snom320-000413241247',
> '5af53194787eccf1',
>  ->  'a...@umts.ro', 'a...@umts.ro', '83.149.75.105', '5060', '2006-12-10
> 12:09:19',
>  ->  '0', '0', '0', '0', 'sip:3...@umts.ro=3buser=3dphone',
>  ->  'sip:a...@umts.ro', '200', 'Sip-Session', '', '', '0', '0', '200',
> 'Invite',
>  ->  'sip:3...@vm01.dns-hosting.info', 'as5664a60b', '27qems1o2j',
>  ->  '31208005169', '81.23.228.147', '5060',
>  ->  'sip:3...@vm01.dns-hosting.info', '', '', 'audio'
>  ->  );
> ERROR 1318 (42000): Incorrect number of arguments for PROCEDURE
> radius.insert_radacct_record; expected 34, got 32
> mysql>  CALL insert_radacct_record (
>  ->  'radius','46477473...@blink-41247', '5af53194787eccf1',
>  ->  'a...@umts.ro', 'a...@umts.ro', '83.149.75.105', '5060', '2009-12-14
> 12:09:19',
>  ->  '0', '0', '0', '0', 'sip:3...@umts.ro',
>  ->  'sip:a...@umts.ro', '200', 'Sip-Session', '', '', '0', '0', '200',
> 'Invite',
>  ->  'sip:t...@umts.ro', 'a60bsss', 'qe222ms1o2j',
>  ->  '208005169', '81.23.228.147', '5060',
>  ->  'sip:t...@umts.ro', '', '', 'chat'
>  ->  );
> ERROR 1318 (42000): Incorrect number of arguments for PROCEDURE
> radius.insert_radacct_record; expected 34, got 32
>

You were right, there was an error in the testing statements, it's 
already fixed in darcs.

The error was only in the testing statements, so the system should be 
working fine for you regardless of that. According to your previous 
email, your installation is right, so did you have any problem with it 
after you reinstalled it?



Regards,


-- 
Saúl Ibarra Corretgé
AG Projects

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


[OpenSIPS-Users] Load balancer - releasing resources

2009-12-23 Thread Peter P GMX
Hello,

we use OpenSIPS as a load balancer in front of a Freeswitch cluster. We
use the load_balancer module for load_balancing and redirecting requests
to this 2 machines.
For each machine we have defined a number of resources (e.g. 3000 for
each server). After a while these resources are full, so the load
balancer module does not balance any more.
Here some extract from the routing:
if ($si=~"^xxx.xx.xxx.xxx") {
# redirect external gateways to the right server
load_balance("1","external");
$ru = "sip:" + $rU + "@" + $dd + ":" + $dp;
sl_send_reply("302", "redirect");
exit;
} else {
} else {
# load balance all registered phones through OpenSIPS
load_balance("1","internal");

 }

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

My main question is: Does OpenSIPS automatically release the load
balancer resources after a while? Or does it release when a SIP session
is ended?
We have now set the resources to 3 but we do not know for how
long they may last.

Best regards
Peter

 

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


Re: [OpenSIPS-Users] Disabling TCP or UDP (RFC forbidden)

2009-12-23 Thread samuel
TCP is very resource demanding and for those situations where the server is
not required to work with TCP is very usefull to have the option of
disabling TCP part.

There are examples, such as embedded platforms with controlled SIP UA
connecting to it where there's no need for TCP stuff and lots of resources
are available for other processes.

Not much related to RFCs...

Sam

2009/12/18 

>
> Hello list,
>
> Somewhere I read that OpenSIPS 1.6.0 allows to disable TCP but not
> UDP because UDP is required by the SIP RFC, so I looked at the RFCs.
>
>  RFC 2543 states that 'UDP and TCP should be implemented.'
>  RFC 3261 states that 'UDP and TCP must be implemented.'
>
> It would seem intuitive that OpenSIPS developers force the OpenSIPS
> runtime to conform to the most recent RFC, meaning that neither UDP
> nor TCP listening is possibly disabled.
>
> ...or the developers allow the admin (config file editor) to disable
> either UDP or TCP. This could be because the developers want to
> support the oldest RFC for backwards compatibility for example,
> or because they want to allow the admin to make the decision
> themselves.
>
> But the current release of OpenSIPS does not allow UDP to be
> disabled, while allowing TCP to be disabled. Can somebody explain
> why this policy was chosen or what is wrong with my logic?
>
> Regards,
> Brian
>
> ___
> Users mailing list
> Users@lists.opensips.org
> http://lists.opensips.org/cgi-bin/mailman/listinfo/users
>
___
Users mailing list
Users@lists.opensips.org
http://lists.opensips.org/cgi-bin/mailman/listinfo/users


Re: [OpenSIPS-Users] opensips 1.6.1 crashes on NOTIFY?

2009-12-23 Thread Alexander
  Any ideas? I'm afraid to touch something and make things worse :)

22 декабря 2009 г. 14:23 пользователь Alexander  написал:

>   What about this one:
>
> Program terminated with signal 11, Segmentation fault.
> [New process 15892]
> #0  0x00e1fddb in t_lookup_request (p_msg=0x81d2f20, leave_new_locked=1) at
> ../../mem/../hash_func.h:65
> 65  for (p=s2->s; p<=(end-4); p+=4){
> (gdb) bt
> #0  0x00e1fddb in t_lookup_request (p_msg=0x81d2f20, leave_new_locked=1) at
> ../../mem/../hash_func.h:65
> #1  0x00e21859 in t_newtran (p_msg=0x81d2f20) at t_lookup.c:1051
> #2  0x00e243a0 in w_t_newtran (p_msg=0x81d2f20, foo=0x0, bar=0x0) at
> tm.c:1006
> #3  0x080545dd in do_action (a=0x81cc30c, msg=0x81d2f20) at action.c:967
> #4  0x08057308 in run_action_list (a=0x81cc30c, msg=0x81d2f20) at
> action.c:139
> #5  0x080af2be in eval_expr (e=0x81cc378, msg=0x81d2f20, val=0x0) at
> route.c:1240
> #6  0x080aed39 in eval_expr (e=0x81cc3a4, msg=0x81d2f20, val=0x0) at
> route.c:1553
> #7  0x080aeccf in eval_expr (e=0x81cc3d0, msg=0x81d2f20, val=0x0) at
> route.c:1558
> #8  0x080533c2 in do_action (a=0x81cc770, msg=0x81d2f20) at action.c:689
> #9  0x08057308 in run_action_list (a=0x81cc770, msg=0x81d2f20) at
> action.c:139
> #10 0x080554a7 in do_action (a=0x81c85b4, msg=0x81d2f20) at action.c:119
> #11 0x08057308 in run_action_list (a=0x81c85b4, msg=0x81d2f20) at
> action.c:139
> #12 0x080554dd in do_action (a=0x81c868c, msg=0x81d2f20) at action.c:706
> #13 0x08057308 in run_action_list (a=0x81c868c, msg=0x81d2f20) at
> action.c:139
> #14 0x08056625 in do_action (a=0x81c86f8, msg=0x81d2f20) at action.c:712
> #15 0x08057308 in run_action_list (a=0x81c86f8, msg=0x81d2f20) at
> action.c:139
> #16 0x08056625 in do_action (a=0x81c8764, msg=0x81d2f20) at action.c:712
> #17 0x08057308 in run_action_list (a=0x81c8764, msg=0x81d2f20) at
> action.c:139
> #18 0x08056625 in do_action (a=0x81c87d0, msg=0x81d2f20) at action.c:712
> #19 0x08057308 in run_action_list (a=0x81c87d0, msg=0x81d2f20) at
> action.c:139
> #20 0x08056625 in do_action (a=0x81c883c, msg=0x81d2f20) at action.c:712
> #21 0x08057308 in run_action_list (a=0x81c883c, msg=0x81d2f20) at
> action.c:139
> #22 0x08056625 in do_action (a=0x81c88a8, msg=0x81d2f20) at action.c:712
> #23 0x08057308 in run_action_list (a=0x81c88a8, msg=0x81d2f20) at
> action.c:139
> #24 0x080554dd in do_action (a=0x81ca360, msg=0x81d2f20) at action.c:706
> #25 0x08057308 in run_action_list (a=0x81bd578, msg=0x81d2f20) at
> action.c:139
> #26 0x080576a3 in run_top_route (a=0x81bd578, msg=0x81d2f20) at
> action.c:119
> #27 0x0809ddf2 in receive_msg (
> buf=0x8192380 "NOTIFY sip:62.117.120.98 SIP/2.0\r\nVia: SIP/2.0/UDP
> 194.190.163.139:5061;branch=z9hG4bK-d5a4f117\r\nFrom: 206401 <
> sip:206...@62.117.120.98 
> >;tag=d825811556491d55o0\r\nTo:
> \r\nCall-ID: d42b6"..., len=347, rcv_info=0xbfd71e84) at
> receive.c:162
> #28 0x080e5056 in udp_rcv_loop () at udp_server.c:492
> #29 0x08070adf in main (argc=3, argv=0xbfd72094) at main.c:821
>
> 22 декабря 2009 г. 13:10 пользователь Anca Vamanu написал:
>
> Hi Alexander,
>>
>> Unless you modified the sources, this is not the right backtrace. The
>> line numbers do not correspond with the ones in the trace.
>>
>> Regards,
>>
>> --
>> Anca Vamanu
>> www.voice-system.ro
>>
>>
>> Alexander wrote:
>> >   Oh, found one. Seems to be right core file. GDB says:
>> >
>> > #0  0x080fbb52 in parse_params (_s=0xec, _c=695, _h=0x81d44bc,
>> > _p=0x1d4) at parser/../trim.h:61
>> > #1  0x080f135f in parse_msg (buf=0xb61eacc4 "э>\035\bп╛\036╤",
>> > len=135861088, msg=0x305) at parser/msg_parser.c:567
>> > #2  0x080ed9c7 in aaa_prot_bind (aaa_url=0xb61eacac, prot=0x80) at
>> > aaa/aaa.c:85
>> > #3  0x003b9205 in ?? ()
>> > #4  0xb61eacac in ?? ()
>> > #5  0x0080 in ?? ()
>> > #6  0x003e2df4 in ?? ()
>> > #7  0x371f3654 in ?? ()
>> > #8  0x0007 in ?? ()
>> > #9  0x08180e85 in _tr_buffer ()
>> > #10 0x08180e81 in _tr_buffer ()
>> > #11 0x in ?? ()
>> >
>> > 2009/12/22 Alexander mailto:goa...@gmail.com>>
>> >
>> >   I have no core file for now:
>> >
>> >
>> > Dec 22 11:02:08 srv opensips[26182]: INFO:core:handle_sigs: core
>> > was not generated
>> >
>> >   Strange - "ulimit -c unlimited" and calls to setrlimit() in
>> > OpenSIPS produce no core file.
>> >
>> >   NOTIFY packets come from clients. Also, Opensips sometimes sends
>> > keepalive NOTIFY packets, but my route(5) is called inside "uri ==
>> > myself" section.
>> >
>> > 2009/12/22 Anca Vamanu mailto:a...@opensips.org
>> >>
>> >
>> > Hi Alexander,
>> >
>> > Can you please investigate the core with gdb and print here
>> > the output.
>> > It seems awkward to me that you expect to receive Notifies and
>> > reply to
>> > them. Wat kind of notifies are those? Sent by clients or the
>> > presence
>> > server?
>> >
>> > Regards,
>> > Anca
>> >
>> >
>> >
>> > Alex

Re: [OpenSIPS-Users] cvs for mediaproxy and cdrtools

2009-12-23 Thread Saúl Ibarra Corretgé
Hi Gabriel,

> Thanks, it would be great to have the darcs repositories for the
> packages that you host at http://ag-projects.com/debian, that way if we
> can build older versions if he most recent doesn't work on the Linux we
> choose to use.
>
> Again thanks for your help
>

IIRC most of the packages there have a public darcs repository. 
FreeRADIUS doesn't because the original source was very slightly 
modified (just added a patch to account failures and OpenSIPS and 
MediaProxy dictionaries).

Anyway, packages are built with source, so you may do apt-get source and 
then debuild to build your own packages.

If you find I missed something just let me know.


Regards,

-- 
Saúl Ibarra Corretgé
AG Projects

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