Any one can share the working ser.cfg that supports NAT+RTPPROXY+MYSQL. I am trying to install public SER server but couldn,t get this all running. My project deadline is approaching. I would really appreciate if any of you help me to get this straight.
Sajjad.
---------------------------------
Do you Yahoo!?
The all-new My Yahoo! � Get yours free!
All, I'm trying to detect a + in my URI's. I tried various things but
none seem to work, note I'm not using the + as a delimiter, example:
+16365551212(a)blah.blah.com
I read the docs but I can't seem to get it to catch. Thanks.
Hi Andrei,
Thanks very much for your reply.
>
> Could you try the unstable (cvs HEAD) version? There are some SYSV lock
> fixes in it which were not backported to stable.
>
I will try it soon and report results. .
(note: all builds are done with OPENBSD_IS_AOUT=no
all tests are run as a non-priv user although running as root
produces identical behaviors but also occassionally huge core
dumps)
First I should mention the /dev/random on OpenBSD 3.2/sparc is reserved
for non-existant hardware random number generators; I realize that
you fall back to other methods but would it make sense to use one of
the other available /dev/*random* devices in OpenBSD?
Next, an experiment was to build it with 'posix sems' support;
when run as 'ser -m 8 -E -ddddddddd' I get:
0(32138) WARNING: could not read from /dev/random (5)
0(32138) read 0 from /dev/random
0(32138) seeding PRNG with 1100941542
0(32138) test random number 760286759
0(32138) ERROR: shm_mem_init: could not initialize lock
0(32138) shm_mem_destroy
0(32138) destroying the shared memory lock
0(32138) could not initialize shared memory pool, exiting...
Too much shared memory demanded: 8388608
0(32138) shm_mem_destroy
0(32138) destroying the shared memory lock
note: '-m 1' in the command line produces the same behavior
/var/log/messages:
Nov 19 18:09:48 nat1 ser.posix-sems: WARNING: could not read from
/dev/random (5)
Nov 19 18:09:48 nat1 ser.posix-sems: ERROR: shm_mem_init: could not
initialize lock
Nov 19 18:09:48 nat1 ser.posix-sems: could not initialize shared memory
pool, exiting...
Next, I discovered that OpenBSD 3.2 pthreads exists and fixed problems
from the 2.x releases. I was able to build 'ser' with pthreads using
the '-pthread' switch in the gcc command-line at link time.
Now, here are the results from running the 'pthreads' version:
$ ser -E -m 8 -ddddddddd
0(11853) WARNING: could not read from /dev/random (5)
0(11853) read 0 from /dev/random
0(11853) seeding PRNG with 1100922221
0(11853) test random number 2107379106
0(11853) shm_mem_init: success
0(11853) DEBUG: register_fifo_cmd: new command (print) registered
0(11853) DEBUG: register_fifo_cmd: new command (uptime) registered
0(11853) DEBUG: register_fifo_cmd: new command (version) registered
0(11853) DEBUG: register_fifo_cmd: new command (pwd) registered
0(11853) DEBUG: register_fifo_cmd: new command (arg) registered
0(11853) DEBUG: register_fifo_cmd: new command (which) registered
0(11853) DEBUG: register_fifo_cmd: new command (ps) registered
0(11853) DEBUG: register_fifo_cmd: new command (kill) registered
Listening on
127.0.0.1 [127.0.0.1]:5060
10.0.0.100 [10.0.0.100]:5060
172.16.5.1 [172.16.5.1]:5060
216.251.177.106 [216.251.177.106]:5060
Aliases: domesys.cybertheque.org:5060 nat1.dome1-wap1:5060 nat1:5060
nat1.cybertheque.net:5060 localhost:5060 localhost.cybertheque.net:5060
Here are the major problems:
1. '-D' doesn't prevent forking to background
2. no fifo is created regardless of the 'fifo=' statement in 'ser.cfg'
or the command-line '-i' argument
3. no additional debug information is logged to syslog or stderr than
what is printed above (the only syslog message is "can't read from
/dev/random")
Permissions are correct for creating a fifo in the specified directory
(I ususally use /tmp).
'ser -c' reports 'ser.cfg' is ok.
The build of the 'ser' executable had no warnings; the only changes I
made were to Makefile.defs for the build environment and to 'locking.h':
66,69d65
< /* Addn'l defines -- MSG */
< #ifndef L_CRIT
< #define L_CRIT 2
< #endif
74d69
< #include <sys/errno.h>
These were necessary to complete the build.
I would appreciate any advice before I start peppering the code with
printfs.
Regards,
Michael Grigoni
Cybertheque Museum
Hi,
There is a README file in each module directory. However there is no such a
file in the root directory to show all built-in variables and functions. Ser
admin guide 0.11 has some info but is a bit outdated.
Can someone please document this? Or at least show where to find them in the
source files?
Thanks,
Richard
Please can you give me an example on how to use
dbtext with authentication modules?
when I run ser I receiving
0(0) preload_udomain(): Error while doing db_query
0(0) register_udomain(): Error while preloading domain 'location'
0(0) domain_fixup(): Error while registering domain
Thank You
--
___________________________________________________________
Sign-up for Ads Free at Mail.comhttp://promo.mail.com/adsfreejump.htm
Hi ,I am a student studying in VoIP and implementing my theory in SER.
I try to access mysql database to get some information, but have a problem aboout paramaters of exe_msg.
My goal is :count the number of contact addresses that certain user registered, and take
this is my solution:
exec_msg(' Count="select count(contact) from location where username=\"$SIP_HF_CONTACT\" "'
CountResult=`mysql -user -pheslo -e "$Count" ser`;
')
What is the result of "CountResult" ?
I suppose originally that it will be the the number of the query, but it seems not.........
If not, what it will be? How can I get my answer what I want to get ?
Looking for all of the documents, I still can't find the information about how to access databases with exec_msg function.
Hoping someone can give me some advises ^^.
Thannks in advance.
Lee
Hi,
I am wondering whether anyone has/knows a good interface to search the
SERUSERS mailing list archives. Currently, the archive is organized as one
page for each calendar month. When I search on one page using the "Find"
menu of IE explorer, it only covers the specific month. Does any one know
how to search the entire archive with a single operation?
Thanks,
Haipeng
Hello list.
I have found the problem with the call. I was missing to match the
uri. So, now i don't have the problem that i mentioned, but i'm still
unable to make calls between my two registered endpoints, in different
domains. Can someone guide me on this issue?
Thanks in advance
Ricardo.-
-----Mensaje original-----
De: Ricardo Martinez [mailto:rmartinez@redvoiss.net]
Enviado el: Lunes, 22 de Noviembre de 2004 17:19
Para: SER Users (E-mail)
Asunto: [Serusers] Serving Multiple Domain in one SER.
Hello again.
I need come back on this post. Thanks to Daniel Mierla i was able
to register in one SER two clients with different domains. I think that i
am missing something because i can't make calls between this two clients.
This is the error from the debug :
3(15752) SIP Request:
3(15752) method: <INVITE>
3(15752) uri: <sip:5555832352@sip1.mydomain.com>
3(15752) version: <SIP/2.0>
3(15752) parse_headers: flags=1
3(15752) Found param type 232, <branch> = <z9hG4bK-d0c66b36>; state=16
3(15752) end of header reached, state=5
3(15752) parse_headers: Via found, flags=1
3(15752) parse_headers: this is the first via
3(15752) After parse_msg...
3(15752) preparing to run routing scripts...
3(15752) DEBUG : is_maxfwd_present: searching for max_forwards header
3(15752) parse_headers: flags=128
3(15752) end of header reached, state=9
3(15752) DEBUG: get_hdr_field: <To> [51];
uri=[sip:5555832352@sip1.mydomain.com]
3(15752) DEBUG: to body [<sip:5555832352@sip1.mydomain.com>
]
3(15752) get_hdr_field: cseq <CSeq>: <101> <INVITE>
3(15752) DEBUG: is_maxfwd_present: value = 70
3(15752) DEBUG: add_param: tag=a7b8327a12a17f9bo0
3(15752) end of header reached, state=29
3(15752) parse_headers: flags=256
3(15752) DEBUG: get_hdr_body : content_length=422
3(15752) found end of header
3(15752) find_first_route(): No Route headers found
3(15752) loose_route(): There is no Route HF
3(15752) parse_headers: flags=64
3(15752) check_via_address(64.76.148.244, 64.76.148.244, 0)
3(15752) parse_headers: flags=-1
3(15752) DEBUG: t_addifnew: msg id=2 , global msg id=0 , T on
entrance=0xffffffff
3(15752) parse_headers: flags=-1
3(15752) parse_headers: flags=60
3(15752) t_lookup_request: start searching: hash=654, isACK=0
3(15752) DEBUG: RFC3261 transaction matching failed
3(15752) DEBUG: t_lookup_request: no transaction found
3(15752) DBG: callback type 2, id 3 entered
3(15752) parse_headers: flags=44
3(15752) DEBUG: noisy_timer set for accounting
3(15752) SER: new INVITE
3(15752) parse_headers: flags=-1
3(15752) check_via_address(64.76.148.244, 64.76.148.244, 0)
3(15752) WARNING:vqm_resize: resize(0) called
3(15752) DEBUG: reply sent out. buf=0x80ea668: SIP/2.0 1...,
shmem=0x402e7488: SIP/2.0 1
3(15752) DEBUG: t_reply: finished
3(15752) DEBUG: mk_proxy: doing DNS lookup...
3(15752) get_record: lookup(_sip._udp.sip1.mydomain.com, 33) failed
3(15752) sip_resolvehost: no SRV record found for sip1.mydomain.com, trying
'normal' lookup...
3(15752) check_via_address(64.76.148.244, 64.76.148.244, 0)
3(15752) DEBUG: add_to_tail_of_timer[4]: 0x402e5d90
3(15752) DEBUG: add_to_tail_of_timer[0]: 0x402e5da4
3(15752) SER: new transaction fwd'ed
3(15752) DEBUG:destroy_avp_list: destroing list (nil)
Looking at this i come up with a question. How does it suppose that
intra-domain call works?. For example i have two domains and one client in
each of them.
Domain1 :sip1.mydomain.com
User1 : 1234(a)sip1.mydomain.com
and
Domain2 : sip2.mydomain.com
User2 : 5678(a)sip2.mydomain.com
If User1 calls to User2, the INVITE is like :
<INVITE>
uri: <sip:5678@sip1.mydomain.com>
I guess SER look for the user 5678 in the sip1.mydomain.com domain, but this
user is Registered in the domain2 (sip2.domain.com), so it will never find
the user and the call will fail. How SER knows in which domain table look
for a user?
For intra-domain calls do i have to append the domain of the destination
client?.
I hope that someone can help me.
I'm also attaching my ser.cfg, i guess that i'm missing something. (it's a
little bit edited)
#
# $Id: ser.cfg,v 1.21.2.2 2003/10/13 22:53:06 jiri Exp $
#
# simple quick-start config script
#
# ----------- global configuration parameters ------------------------
debug=9 # debug level (cmd line: -dddddddddd)
fork=yes
log_stderror=yes # (cmd line: -E)
#Uncomment these lines to enter debugging mode
#fork=no
#log_stderror=yes
check_via=yes # (cmd. line: -v)
dns=no # (cmd. line: -r)
rev_dns=no # (cmd. line: -R)
port=5060
#children=4
fifo="/tmp/ser_fifo"
fifo_mode=0666
# ------------------ module loading ----------------------------------
# Uncomment this if you want to use SQL database
#loadmodule "/usr/local//lib/ser/modules/mysql.so"
loadmodule "/usr/local//lib/ser/modules/sl.so"
loadmodule "/usr/local//lib/ser/modules/tm.so"
loadmodule "/usr/local//lib/ser/modules/rr.so"
loadmodule "/usr/local//lib/ser/modules/maxfwd.so"
loadmodule "/usr/local//lib/ser/modules/usrloc.so"
loadmodule "/usr/local//lib/ser/modules/registrar.so"
loadmodule "/usr/local//lib/ser/modules/textops.so"
loadmodule "/usr/local//lib/ser/modules/exec.so"
# Para trabajar con NAT
loadmodule "/usr/local//lib/ser/modules/mediaproxy.so"
loadmodule "/usr/local//lib/ser/modules/domain.so"
loadmodule "/usr/local//lib/ser/modules/dbtext.so"
# Uncomment this if you want digest authentication
# mysql.so must be loaded !
loadmodule "/usr/local/lib/ser/modules/auth.so"
#loadmodule "/usr/local/lib/ser/modules/auth_db.so"
loadmodule "/usr/local/lib/ser/modules/auth_radius.so"
loadmodule "/usr/local/lib/ser/modules/group_radius.so"
loadmodule "/usr/local/lib/ser/modules/acc.so"
# ----------------- setting module-specific parameters ---------------
# ----------------- setting module-specific parameters ---------------
# -- rr params --
# add value to ;lr param to make some broken UAs happy
modparam("rr", "enable_full_lr", 1)
# module authorization
modparam("auth_radius","radius_config","/usr/local/etc/radiusclient/radiuscl
ient.conf")
modparam("auth_radius","service_type",15)
#module accounting
modparam("acc","radius_config","/usr/local/etc/radiusclient/radiusclient.con
f")
modparam("acc","log_level",1)
modparam("acc", "service_type", 15)
modparam("acc", "radius_flag", 1)
modparam("acc", "radius_missed_flag", 3)
modparam("acc", "failed_transactions", 1)
modparam("acc", "report_ack", 0)
#group radius
modparam("group_radius","radius_config","/usr/local/etc/radiusclient/radiusc
lient.conf")
modparam("group_radius", "use_domain", 1)
#module mediaproxy
modparam("mediaproxy", "natping_interval", 60)
modparam("mediaproxy", "mediaproxy_socket", "/var/run/mediaproxy.sock")
#modparam("mediaproxy", "sip_asymmetrics",
"/usr/local/etc/ser/sip-asymmetrics-clients")
#modparam("mediaproxy", "rtp_asymmetrics",
"/usr/local/etc/ser/rtp-asymmetrics-clients")
modparam("registrar", "nat_flag", 5)
#module usrloc
modparam("usrloc", "use_domain", 1)
#module domain
modparam("domain", "db_url", "/usr/local/etc/ser/domaintables")
modparam("domain", "domain_table", "domain")
modparam("domain", "domain_col", "domain")
#module registrar (Con estos parametro haces que el location lookup priorize
solo los mas recientes contacts.
modparam("registrar", "append_branches", 0)
modparam("registrar", "desc_time_order", 1)
modparam("registrar", "use_domain", 1)
# ------------------------- request routing logic -------------------
# main routing logic
route {
..skipped....
if (uri=="sip:sip1.mydomain.com") {
if (method=="REGISTER") {
....
save("location");
break;
}; # FIN DE CHEQUEO DE REGISTRO
# lookup("aliases");
...
if ( (uri=~"^sip:0.@){
log(1,"FORWARDING : Llamada hacia plataforma
H.323\n");
route(1);
break;
};
# Llamadas SIP locales
if (!lookup("location")) { #Usuarios que no estan en
"location" database.
route(4);
break;
};
setflag(3);
.....
} else if (uri=="sip:sip2.mydomain.com"){
if (method=="REGISTER") {
.....
save("location");
break;
}; # FIN DE CHEQUEO DE REGISTRO
.....
if ((uri=~"^sip:0.@*)){
log(1,"FORWARDING : Llamada hacia plataforma
H.323\n");
route(1);
break;
};
# Llamadas SIP locales
if (!lookup("location")) { #Usuarios que no estan en
"location" database.
route(4);
break;
};
setflag(3);
...
};
append_hf("P-hint: USRLOC\r\n");
if (!t_relay()) {
sl_reply_error();
break;
};
} /* end of initial routing logic */
#--------- Route 1 hacia SIPQUEST -------------------------------
route[1]
{
......
if (!t_relay()) {
sl_reply_error();
break;
};
}
#------- Route 3 : Trafico de Internet hacia la PSTN -------------------
route[3] {
.....
if(!t_relay()) {
sl_reply_error();
break;
};
}
#------ Route 4 : Llamadas a usuarios Off-line ------------------------
route[4] {
if (!t_newtran()) {
sl_reply_error();
};
if (!t_reply("404", "Not Found IT!")) {
sl_reply_error();
};
break;
}
# ---------------------------- Begin On-Reply Routes
--------------------------
onreply_route[1] {
.......
};
}
# ------------------------------ End On-Reply Routes
--------------------------
Thanks in advance.
Ricardo.-
_______________________________________________
Serusers mailing list
serusers(a)lists.iptel.org
http://lists.iptel.org/mailman/listinfo/serusers