This isn't a question specific to LCR module, but it could be an LCR or Carrierroute module issue.
Let's say you have to carriers...
Carrier Prefix Cost
---------------------------
Carrier1 1650 0.3
Carrier2 165 0.2
When LCR or Carrierroute try to match a dialed number against a routing entry, they will try and match as much of the number as possible, which makes sense.
However, when you get routes from multiple carriers, they don't always bill on the same prefix boundaries. In my example above, LCR/Carierroute would match against Carrier1 for anything starting with 1650. HOWEVER, since 165 is also applicable (165 means 1650, 1651 and so on), and in this example cheaper, you should route 165 over Carrier 2.
What do people do in this case?
Doug
____________________________________________________________________________________
Be a better friend, newshound, and
know-it-all with Yahoo! Mobile. Try it now. http://mobile.yahoo.com/;_ylt=Ahu06i62sR8HDtDypao8Wcj9tAcJ
Right.... minimising cost is priority #1... and in this particular case the cheapest route is NOT used.
----- Original Message ----
From: Andreas Sikkema <h323(a)ramdyne.nl>
To: users(a)lists.openser.org
Sent: Thursday, March 27, 2008 5:20:08 PM
Subject: Re: [OpenSER-Users] LCR Routing.... Choosing Best Route
On Mar 28, 2008, at 12:38 AM, Douglas Garstang wrote:
> However, when you get routes from multiple carriers, they don't
> always bill on the same prefix boundaries. In my example above, LCR/
> Carierroute would match against Carrier1 for anything starting with
> 1650. HOWEVER, since 165 is also applicable (165 means 1650, 1651
> and so on), and in this example cheaper, you should route 165 over
> Carrier 2.
>
> What do people do in this case?
It's called LCR for a reason, so I think minimizing cost should be
priority 1. Once price has stopped being the differentiator other
factors could be taken into account. Maybe price and other costs have
to aggregated?
--
Andreas Sikkema
_______________________________________________
Users mailing list
Users(a)lists.openser.org
http://lists.openser.org/cgi-bin/mailman/listinfo/users
____________________________________________________________________________________
Looking for last minute shopping deals?
Find them fast with Yahoo! Search. http://tools.search.yahoo.com/newsearch/category.php?category=shopping
Hi all,
I would like to share some experience with uac_replace_from(). Please
anybody correct me if I made any mistake.
I have done tons of test with openser 1.2.3 and 1.3.1 and finally found
the trend as follows:
In 1.2.3 the Header Field From in CANCEL will be the one received from
UAC, no matter what you have done with INVITE, it will remember the
From: prior to all the changes. Parameter from_restore_mode doesn't
apply to this. So you have to write something like if(method=="CANCEL")
uac_replace_from("sometext").
However, in 1.3.1. If you set modparam("uac", "from_restore_mode",
"auto"). TM is smart enough to change From: in CANCEL for you to match
the one in INVITE, even modified by Openser. But the problem in 1.3.1 is
if you set from_restore_mode to none, no matter how you write
uac_replace_from() to your CANCEL request, nothing will happen. Actually
this means in Openser 1.3.1, no matter what you do with
uac_replace_from() to CANCEL, nothing will happen, depends on the module
param it will be either original message or modified message in INVITE.
But you can hardly do anything to CANCEL manually.
Bogdan, this is the behavior you intend to?
Best Regards,
Bai Shi
Ok... I can do it if I use cr_user_rewrite_uri("sip:.*@192.168.1.240", "1") in openser.cfg and then change the username from blank to '.*' (WHERE is that documented?? I only worked it out by tracing port 3306!!!).
But... this isn't feesible. This means that I have to HARD CODE the name of the user in the openser.cfg...
Doug.
----- Original Message ----
From: Douglas Garstang <dougmig33(a)yahoo.com>
To: Ovidiu Sas <osas(a)voipembedded.com>
Cc: users(a)lists.openser.org
Sent: Wednesday, March 26, 2008 9:41:23 AM
Subject: Re: [OpenSER-Users] Carrierroute... Do I almost have it???
Ovidiu,
Ok, so now it's routing but it's not selecting the carrier by matching the source IP address in the subscriber table against the IP address of the incoming INVITE. Is that even possible?
If it's not possible, how do I have a different routing table for each OpenSER system? I was going to use my carrier as my OpenSER instance.... that would have worked...
I have these tables...
mysql> select * from carrierroute;
+----+---------+-------------+--------+------+-------+--------------+----------------+----------------+---------+
| id | carrier | scan_prefix | domain | prob | strip | rewrite_host | rewrite_prefix | rewrite_suffix | comment |
+----+---------+-------------+--------+------+-------+--------------+----------------+----------------+---------+
| 1 | 0 | | 1 | 1 | 0 | 200.1.1.1 |
| | NULL |
| 4 | 0 | | 2 | 1 | 0 | 200.1.1.2 | | | NULL |
| 5 | 0 | | 3 | 1 | 0 | 200.1.1.3
| | | NULL |
| 9 | 1 | | 1 | 1 | 0 | 100.1.1.1 | | | NULL |
| 10 | 1 | | 2
| 1 | 0 | 100.1.1.2 | | | NULL |
| 11 | 1 | | 3 | 1 | 0 | 100.1.1.3 | | | NULL |
+----+---------+-------------+--------+------+-------+--------------+----------------+----------------+---------+
6 rows in set (0.00 sec)
mysql> select * from route_tree;
+----+-----------+
| id | carrier |
+----+-----------+
| 1 | Hong Kong |
| 0 | default |
| 2 | San Jose |
+----+-----------+
mysql> select username, domain, cr_preferred_carrier from subscriber;
+----------+----------------+----------------------+
| username | domain | cr_preferred_carrier |
+----------+----------------+----------------------+
| | 192.168.255.53 | 2 |
| | 192.168.1.240 | 1 |
+----------+----------------+----------------------+
----- Original Message ----
From: Ovidiu Sas <osas(a)voipembedded.com>
To: Douglas Garstang <dougmig33(a)yahoo.com>
Cc: Henning Westerholt <henning.westerholt(a)1und1.de>; users(a)lists.openser.org
Sent: Wednesday, March 26, 2008 6:56:15 AM
Subject: Re: [OpenSER-Users] Carrierroute... Do I almost have it???
On Wed, Mar 26, 2008 at 2:31 AM, Douglas Garstang <dougmig33(a)yahoo.com> wrote:
>
> >I am using this module in production with more then 400k routes loaded
> >for 8 different providers and it is working like a charm.
> >As Henning mentioned, the interface is a little bit cumbersome but usable.
> >You can put all the carriers under the same table and prioritize the
> >gateway based on domains. Like tis you don't need to hardcode
> >anything in the config file.
> >
> >Carrierroute was designed to deal with a big amount of routing rules
> >and it is doing an amazing job.
> >LCR was designed to deal with a limited number of routes/gateways but
> >it has a different level of flexibility and a more mature interface.
> >
> >Carrierroute is a brand new module and for sure it will improve in
> >flexibility as times go by (just like the lcr did along releases).
>
> Ovidiu (or anyone else....)
>
> I think I may almost have it..... If I treat all routes as being in the same
> carrier, I can just use cr_rewrite_uri("1","call_id"), and then
> cr_rewrite_uri("2","call_id") in failure_route[1] and
> cr_rewrite_uri("2","call_id") in failure_route[2], correct? I tested this
> and it seems to work. I guess it's up to me then to populate the
> rewrite_host column with a gateway belonging to the cheapest carrier for
> domain 1, the a gateway from the next cheapest carrier for domain 2 and so
> on. Still sound right?
finally you got it ;)
> Here's where it gets a bit tricky. We have OpenSER running in 6 different
> locations. The gateways we use will differ for each location (we always want
> to use the closest gateway belonging to a carrier). So, I figured I could
> use the 'user' functionality in carrierroute to do this. I could simply put
> the domain (IP address) in the domain column, leave the user blank (we don't
> have users... calls are forwarded from asterisk), and then associate a
> carrier in the cr_preferred_carrier column. You can see all that in my
> subscriber table below.
>
> Doesn't seem to work though. When routing a call, OpenSER complains that it
> can't find a default carrier, and then because it seems not to match the
> incoming call against an entry in the subscriber table, it can't find a
> carrier to use, and fails the call.
add a 'default' carrier into the route_tree table
> So... how would I be able to use the source IP address of the asterisk box
> that sends the calls to OpenSER in the subscriber table so that I could have
> different routing entries for each OpenSER system???
>
> Here's my db tables...
>
>
> mysql> select * from route_tree;
> +----+-----------+
> | id | carrier |
> +----+-----------+
> | 1 | Hong Kong |
> | 0 | San Jose |
> +----+-----------+
>
> mysql> select * from carrierroute order by carrier, scan_prefix, domain;
> +----+---------+-------------+--------+------+-------+--------------+----------------+----------------+---------+
> | id | carrier | scan_prefix | domain | prob | strip | rewrite_host |
> rewrite_prefix | rewrite_suffix | comment |
> +----+---------+-------------+--------+------+-------+--------------+----------------+----------------+---------+
> | 1 | 0 | | 1 | 1 | 0 | 200.1.1.1 |
> | | NULL |
> | 4 | 0 | | 2 | 1 | 0 | 200.1.1.2 |
> | | NULL |
> | 5 | 0 | | 3 | 1 | 0 | 200.1.1.3 |
> | | NULL |
> | 9 | 1 | | 1 | 1 | 0 | 100.1.1.1 |
> | | NULL |
> | 10 | 1 | | 2 | 1 | 0 | 100.1.1.2 |
> | | NULL |
> | 11 | 1 | | 3 | 1 | 0 | 100.1.1.3 |
> | | NULL |
> +----+---------+-------------+--------+------+-------+--------------+----------------+----------------+---------+
>
> mysql> select id, username, domain, cr_preferred_carrier from subscriber;
> +----+----------+----------------+----------------------+
> | id | username | domain | cr_preferred_carrier |
> +----+----------+----------------+----------------------+
> | 1 | | 192.168.255.53 | 0 |
> | 2 | | 192.168.255.54 | 1 |
> +----+----------+----------------+----------------------+
>
>
>
>
>
>
> ________________________________
> Be a better friend, newshound, and know-it-all with Yahoo! Mobile. Try it
> now.
Never miss a thing. Make Yahoo your homepage.
____________________________________________________________________________________
Looking for last minute shopping deals?
Find them fast with Yahoo! Search. http://tools.search.yahoo.com/newsearch/category.php?category=shopping
Parallel posting this to both CDRTool users and OpenSER users, so apologies
to members of both.
I have installed the latest version of CDRTool and running it with OpenSER
1.1.1 for the time being. When looking at the tcpdump of the records
leaving the OpenSER server via radiusclient-ng I am viewing a few 'Unknown
Attribute' statements.
Ex:
Accounting Status Attribute (40), length: 6, Value: Start
Service Type Attribute (6), length: 6, Value: #15
Unknown Attribute (102), length: 6, Value:
Unknown Attribute (101), length: 6, Value:
Username Attribute (1), length: 26, Value: +15552221111(a)x.x.x.x
Calling Station Attribute (31), length: 24, Value:
sip:+15552221111@x.x.x.x
Called Station Attribute (30), length: 32, Value:
sip:+15553334444@x.x.x.x
Unknown Attribute (107), length: 35, Value:
Accounting Session ID Attribute (44), length: 14, Value:
0d487415(a)mysipserver.com
Unknown Attribute (104), length: 10, Value:
Unknown Attribute (105), length: 7, Value:
Unknown Attribute (103), length: 6, Value:
Unknown Attribute (214), length: 15, Value:
Unknown Attribute (215), length: 6, Value:
Unknown Attribute (216), length: 32, Value:
Event Timestamp Attribute (55), length: 6, Value: Thu Mar 27
11:01:23 2008
NAS IP Address Attribute (4), length: 6, Value: x.x.x.x
NAS Port Attribute (5), length: 6, Value: 5060
Accounting Delay Attribute (41), length: 6, Value: 00 secs
I have looked into the dictionary.ser and each of the Attributes are defined
and the dictionary file that is defined in radiusclient.conf has the
$INCLUDE dictionary.ser statement.
Any hints, ideas or links would be appreciated.
--
-- Krom
kyle.romulas(a)gmail.com
Hi,
Who is inchage of replacing the to header in the message (openser/wesip)?
When wesip get the message the to uri is still with the openser IP.
Do I need to do something when the request is INVITE request or these
openser replace it automatically before he send it to wesip?
Please advice. I realy need it soon.
Thanks in advance,
Shie
Hi All,
How i can get the length of called number. i am trying to making routing logic base on length. Please help us how i can get the length i tried the fillowing but did not work.
if (uri:len<=7) {
rewritehostport("192.168.1.1:5060");
route(1);
exit;
};
Regards,
www.Go4Calls.Com
VoIP Forums
_________________________________________________________________
Connect to the next generation of MSN Messenger
http://imagine-msn.com/messenger/launch80/default.aspx?locale=en-us&source=…
-------原始邮件-------
发件人: fang, tian
日期: 2008-3-27 12:59:27
收件人: serusers(a)iptel.org
主题: SER performance bottleneck ?
Hi dear friends,
We tried to benchmarking IPtel SER 0.9.6 on Intel xeon CPU based
computer recently,but we met a problem about poort performance.For example
on a computer configured with Intel 2*sossaman CPU (four cores)+2G ddr2-400
memory+100M Ethernet card, we didn't configure any database,and registered
with only 1-2 users,and we use SIPP 3.0 as the call generator ,but we can
only see about 3,000 calls per second for a very simply built-in scenario
in SIPP(UAC+UAS),and the CPU idle percentage is about 70-80%.if we tried to
increase the call rate ,we got failure calls.
We tried to enlarge the memory to 768M for SER,and limited the ser
processes number on each port from 8 to 4,and we also made some improvement
on config.h & Makefile.defs,but didn't get big improvement on performance .
If anybody could help me on this,I will appreciate a lot.
Thanks
Fang tian.
Hi!
I just tried if openser can handle a service URN in the request URI
(e.g. urn:service:sos which is used for emergency calls (refer to IETF
ECRIT WG)).
Do it stateless with forward() works fine. Doing it statefull with tm
module and t_relay() fails:
DBG:tm:t_newtran: transaction on entrance=(nil)
DBG:core:parse_headers: flags=ffffffffffffffff
DBG:core:parse_headers: flags=78
DBG:tm:t_lookup_request: start searching: hash=20823, isACK=0
DBG:tm:matching_3261: RFC3261 transaction matching failed
DBG:tm:t_lookup_request: no transaction found
ERROR:core:parse_uri: bad uri, state 0 parsed: <urn:> (4) /
<urn:service:sos> (15)
ERROR:core:parse_sip_msg_uri: bad uri <urn:service:sos>
DBG:core:set_err_info: ec: 1, el: 3, ei: 'error parsing r-uri'
ERROR:tm:new_t: uri invalid
ERROR:tm:t_newtran: new_t failed
I wonder, is it really necessary for the tm module to understand the
syntax of the RURI? Of course it is necessary if routing is done based
on the RURI. But if DURI is set, or t_relay("udp:1.2.3.4:5060") is used,
then I think it should work with any uri scheme in RURI.
regards
klaus
i want to integrate ser with asterisk.i try to do that in one
box.asteriskwill communicate 5060 port and ser will communicate 6070
port.two servers work fine in seperatley.but i want to integrate the
asterisk and ser in same machine.please give me some help for this iam very
beginner for this.
thanx
akalanka