hi guys
what are the differences between SIP servers and PBX??
thanks for all
--
=====================================================
Legolas_Bilbao[ID2006][GKR]
Dios creo un equipo Perfecto a los demas los lleno de extranjeros
http://www.forosindicedonkey.comhttp://usuarios.lycos.es/ligaforo/
=====================================================
YEAHHHHHH!
My problem was with the destination database. I didn't understand what was the destination ID, I thought it was just a random one!
I was probably too tired...
Hopefully, tomorrow; it's summer holidays
I owe you a beer!!
Are you going to Rome next September for VoIP conference?
ShowPrice From=sip:101@sd-7501.dedibox.fr To=sip:001305465768 Duration=599876
199.9587
App: audio
Destination: 1305 (TEST INTERNATIONAL)
Customer: default
Connect fee: 0.0000
--
Span: 1
Duration: 11931 s
StartTime: 2007-08-09 15:41:09 (Europe/Paris)
ProfileId: 441 for weekday
RateId: 441 for 8-19h
Rate: 0.0200 / 60 s
Price: 3.9770
--
Span: 2
Duration: 29931 s
StartTime: 2007-08-09 15:41:09 (Europe/Paris)
ProfileId: 441 for weekday
RateId: 442 for 19-24h
Rate: 0.0200 / 60 s
Price: 9.9770
--
Span: 3
Duration: 58731 s
StartTime: 2007-08-09 15:41:09 (Europe/Paris)
ProfileId: 441 for weekday
RateId: 442 for 0-8h
Rate: 0.0200 / 60 s
Price: 19.5770
Yes: "reportMissingRates"=> 1
flavio a écrit :
> Marc,
>
> Is the missing rates parameter of $CDRTool['rating'] equal to 1?
>
> rates.csv
> Ops,Gateway,Domain,Subscriber,Rate Id,Destination,Price,App,Connect
> 2,,192.168.1.160,,442,1305,200,audio,
> 2,,192.168.1.160,,441,1305,200,audio,
Ops,Gateway,Domain,Subscriber,Rate Id,Destination,Price,App,Connect
2,,sd-7501.dedibox.fr,,442,1305,200,audio,
2,,sd-7501.dedibox.fr,,441,1305,200,audio,
>
>
> profiles.csv
> Ops,Gateway,Domain,Subscriber,Profile Id,Rate Id1,00-H1,Rate
> Id2,H1-H2,Rate Id3,H2-H3,Rate Id4,H3-24
> 2,,192.168.1.160,,441,442,8,441,19,442,24,,0
> 2,,192.168.1.160,,442,442,24,442,19,441,24,,0
Ops,Gateway,Domain,Subscriber,Profile Id,Rate Id1,00-H1,Rate Id2,H1-H2,Rate Id3,H2-H3,Rate Id4,H3-24
2,,sd-7501.dedibox.fr,,442,442,24,442,19,442,24,,0
2,,sd-7501.dedibox.fr,,441,442,8,441,19,442,24,,0
>
>
> customer.csv
>
> Ops,Gateway,Domain,Subscriber,WeekDay,Fallback,WeekEnd,Fallback,Timezone,Incr,Minim
>
> 2,,,,441,,442,,Europe/Amsterdam,0,0
Ops,Gateway,Domain,Subscriber,WeekDay,Fallback,WeekEnd,Fallback,Timezone,Incr,Minim
2,,,,441,,442,,Europe/Paris,0,0
>
>
> I have made all the tests dialing 001305...... (Miami). (I have used
> 192.168.1.160 as the domain, change to yourdomain). It normalizes to
> 1305 striping two zeros as specified on cdrlib.phtml. Check if it is
> striping the digits to match the desired destination.
>
> class CDRS {
>
> var $CDR_class = 'CDR';
> var $intAccessCode = '00';
> var $natAccessCode = '0';
>
class CDRS {
var $CDR_class = 'CDR';
var $intAccessCode = '00';
var $natAccessCode = '0';
var $RatingEngineSocket = false;
var $maxrowsperpage = 15;
var $status = array();
var $normalizedField = 'Normalized';
var $DestinationIdField = 'DestinationId';
var $BillingIdField = 'UserName';
var $sipTraceDataSource = 'sip_trace';
var $defaults = array();
var $whereUnnormalized = '';
......................
......................
> Cheers,
>
> Flavio
> ----- Original Message ----- From: "Marc LEURENT" <lftsy(a)free.fr>
> To: "flavio" <flavio(a)asteriskguide.com>
> Sent: Thursday, August 09, 2007 9:41 AM
> Subject: Re: [OpenSER-Users] Re: How can it be simpler and working? CDRTool
>
>
>> Hello flavio,
>> I would be very grateful if you can send me just the .csv of your
>> tables about your internal calls, the simpliest one for you that is
>> working...
>> Best Regards!
>>
>> Marc, desperate
>>
>> Marc LEURENT a écrit :
>>> I've got a running tail -f /var/lig/messages and I haven't seen a
>>> single error...
>>> It's just that it calculates 0.0000 for the price
>>>
>>> I have already added the $CDRTool['rating'] parameter..
>>>
>>> Id don't have the same message:
>>> Aug 9 14:00:02 sd-7501 CDRTool[18946]: ShowPrice Id=3
>>> Timestamp=1186660750 Duration=11 inputTraffic=0 outputTraffic=0
>>> From=sip:106@sd-7501.dedibox.fr
>>> To=6713(a)sd-7501.dedibox.fr Gateway= Application=audio
>>> Aug 9 14:00:02 sd-7501 CDRTool[19627]: Normalization done in 0 s,
>>> memory usage: 9.90 MB
>>> Aug 9 14:00:02 sd-7501 CDRTool[19627]: 1 CDRs, 1 normalized in 0 s @
>>> 0 cps
>>>
>>> But there is no "ConnectFee=0.0000 Span=1 Duration=57 De
>>> stId=1305 domain=192.168.1.160 Profile=441 Period=weekday Rate=441
>>> Interval=8
>>> -19 Cost=0.0200/10 Price=0.1140 " after
>>>
>>> Do I have to activate something else??
>>>
>>>
>>> flavio a écrit :
>>>> Marc,
>>>>
>>>> I'm using 5.1.5 and it is working. Check the /var/log/syslog for errors
>>>> in the normalization process
>>>>
>>>> Something like:
>>>>
>>>> Aug 6 07:18:55 debian CDRTool[3973]: Error: Cannot find rates for
>>>> callid=, d
>>>> omain=192.168.1.160, destination=1305, profile=441, app=audio
>>>>
>>>> The correct in the tests I have made is:
>>>>
>>>> Aug 6 07:47:44 debian CDRTool[3973]: ShowPrice Id=88
>>>> Timestamp=1186400781 Du
>>>> ration=57 inputTraffic=0 outputTraffic=0 From=1000(a)192.168.1.160
>>>> To=001305345
>>>> 6789(a)192.168.1.160 Gateway=192.168.1.118 Application=audio
>>>> Aug 6 07:47:44 debian CDRTool[3973]: ConnectFee=0.0000 Span=1
>>>> Duration=57 De
>>>> stId=1305 domain=192.168.1.160 Profile=441 Period=weekday Rate=441
>>>> Interval=8
>>>> -19 Cost=0.0200/10 Price=0.1140
>>>>
>>>> please activate the following parameter in the global.inc file
>>>> (reportMissingRates).
>>>>
>>>> $CDRTool['rating']=array("priceDenominator" =>
>>>> 10000,"priceDecimalDigits" => 4,"minimumDurationCharged"=>
>>>> 0,"durationPeriodRated"=> 60,"trafficSizeRated"=>
>>>> 1024,"reportMissingRates"=> 1,"minimumDuration"=> 0);
>>>>
>>>> I hope it helps, it took me a long time before to start working.
>>>>
>>>> Cheers
>>>>
>>>> Flavio
>>>>
>>>>
>>>> ----- Original Message ----- From: "Marc LEURENT" <lftsy(a)free.fr>
>>>> To: "flavio" <flavio(a)asteriskguide.com>
>>>> Cc: <users(a)openser.org>
>>>> Sent: Thursday, August 09, 2007 9:01 AM
>>>> Subject: Re: [OpenSER-Users] Re: How can it be simpler and working?
>>>> CDRTool
>>>>
>>>>
>>>>> Yes, I've added all rights to my account...
>>>>> and price is NULL in the database until a Normalize is done! All
>>>>> prices are set to 0.0000 after...
>>>>>
>>>>> And after a
>>>>> Normalize datasource ser_radius, database DB_radius, table
>>>>> radacct200708
>>>>> Aug 9 14:00:02 sd-7501 CDRTool[18946]: ShowPrice Id=3
>>>>> Timestamp=1186660750 Duration=11 inputTraffic=0 outputTraffic=0
>>>>> From=sip:106@sd-7501.dedibox.fr
>>>>> To=6713(a)sd-7501.dedibox.fr Gateway= Application=audio
>>>>>
>>>>>
>>>>>
>>>>>
>>>>> flavio a écrit :
>>>>>> Marc,
>>>>>>
>>>>>> Have you checked your user rights in the CDRTool (is show price item
>>>>>> highlighted?). My CDRtool shown x.xxx in the price and that's was
>>>>>> the
>>>>>> cause.
>>>>>>
>>>>>> Flavio
>>>>>>
>>>>>> ----- Original Message ----- From: "Marc LEURENT" <lftsy(a)free.fr>
>>>>>> To: "Dan-Cristian Bogos" <dan.bogos(a)gmail.com>
>>>>>> Cc: <users(a)openser.org>
>>>>>> Sent: Thursday, August 09, 2007 8:01 AM
>>>>>> Subject: [OpenSER-Users] Re: How can it be simpler and working?
>>>>>> CDRTool
>>>>>>
>>>>>>
>>>>>> I'm starting to fell sorry to bother you like that...
>>>>>> I have changed the database like you said, but it is still not
>>>>>> working...
>>>>>>
>>>>>> ShowPrice From=sip:101@sd-7501.dedibox.fr To=0033677832974
>>>>>> Duration=5923
>>>>>> 0.0000
>>>>>>
>>>>>> Should I try to downgrade to version 5.1.3 like yours?
>>>>>>
>>>>>> ShowMemory
>>>>>> 1 destinations
>>>>>> 1 customers
>>>>>> 1 profiles
>>>>>> 1 rates
>>>>>> 0 holidays
>>>>>> 2 prepaid accounts
>>>>>> 1 sessions
>>>>>> 1 sessions last minute
>>>>>> 1 sessions last hour
>>>>>> 1 sessions last day
>>>>>>
>>>>>>
>>>>>> but in the database, the prepaid account is credited by 10.00
>>>>>> ShowPrepaidAccounts Filter=101(a)sd-7501.dedibox.fr
>>>>>> Account=101(a)sd-7501.dedibox.fr Balance=10040.0000
>>>>>>
>>>>>> ShowCustomers
>>>>>> default
>>>>>>
>>>>>>
>>>>>> ShowAccounts
>>>>>> Error: Invalid request
>>>>>>
>>>>>> MaxSessionTime From=sip:101@sd-7501.dedibox.fr
>>>>>> To=sip:106@sd-7501.dedibox.fr Duration=7200 Lock=1
>>>>>> none
>>>>>>
>>>>>> DebitBalance From=sip:101@sd-7501.dedibox.fr
>>>>>> To=sip:106@sd-7501.dedibox.fr Duration=59
>>>>>> Ok
>>>>>>
>>>>>>
>>>>>>
>>>>>>
>>>>>> Dan-Cristian Bogos a écrit :
>>>>>>> Ok, let's take it in your way. I would rather modify your data into:
>>>>>>>
>>>>>>> Destinations:
>>>>>>> Ops,Gateway,Domain,Subscriber,Destination Id,Description
>>>>>>> 2,,,,131,TEST INTERNATIONAL
>>>>>>>
>>>>>>> Customers:
>>>>>>> Ops,Gateway,Domain,Subscriber,WeekDay,Fallback,WeekEnd,Fallback,Timezone,Incr,Minim
>>>>>>>
>>>>>>>
>>>>>>>
>>>>>>> 2,,,,441,,441,,,1,1
>>>>>>>
>>>>>>> Profiles:
>>>>>>> Ops,Gateway,Domain,Subscriber,Profile Id,Rate Id1,00-H1,Rate
>>>>>>> Id2,H1-H2,Rate Id3,H2-H3,Rate Id4,H3-24
>>>>>>> 2,,,,441,441,8,441,19,441,24,441,0
>>>>>>>
>>>>>>> Rates:
>>>>>>> Ops,Gateway,Domain,Subscriber,Rate Id,Destination,Price,App,Connect
>>>>>>> 2,,,,441,131,2100,audio,0
>>>>>>>
>>>>>>> U did not have a rate id and no App. Without App field for me it
>>>>>>> does
>>>>>>> not calculate either.
>>>>>>>
>>>>>>> DanB
>>>>>>>
>>>>>>>>
>>>>>>>> But, the command ShowPrice returns:
>>>>>>>> ShowPrice From=sip:101@sd-7501.dedibox.fr To=0033677832974
>>>>>>>> Duration=59
>>>>>>>> 0.0000
>>>>>>>>
>>>>>>>>
>>>>>>>> I have a field TrafficRate in the database but doesn't appear on
>>>>>>>> the
>>>>>>>> CDRTool interface
>>>>>>>> I put random values inside
>>>>>>>>
>>>>>>>>
>>>>>>>> Dan-Cristian Bogos a écrit :
>>>>>>>>> My version is:
>>>>>>>>> CDRTool version 5.1.3
>>>>>>>>>
>>>>>>>>> In my rates table I have one more field more which is
>>>>>>>>> TrafficRate. I
>>>>>>>>> see that this one is missing on your side.
>>>>>>>>> Can u also create a default rate table without filling any of the
>>>>>>>>> gateway, subscriber, domain in profiles? This one should match all
>>>>>>>>> the
>>>>>>>>> destinations. Maybe would be useful till u make it work to have
>>>>>>>>> only
>>>>>>>>> the test row and remove anything else to take it gradually.
>>>>>>>>> Also, try querying for price with 00 added in the front of the
>>>>>>>>> destination since this is the default prefix set in CDRTool for
>>>>>>>>> international destinations (without being necessary to be added in
>>>>>>>>> rate or destination table).
>>>>>>>>>
>>>>>>>>> DanB
>>>>>>>>>
>>>>>>>>> On 8/9/07, Marc LEURENT <lftsy(a)free.fr> wrote:
>>>>>>>>>> I have added:
>>>>>>>>>>
>>>>>>>>>> Destination:
>>>>>>>>>> Ops,Gateway,Domain,Subscriber,Destination Id,Description
>>>>>>>>>> 2,,sd-7501.dedibox.fr,,31800,Ma Dst TEST
>>>>>>>>>> 2,,,33677832974,131,TEST INTERNATIONAL
>>>>>>>>>>
>>>>>>>>>> Profiles:
>>>>>>>>>> Ops,Gateway,Domain,Subscriber,Profile Id,Rate Id1,00-H1,Rate
>>>>>>>>>> Id2,H1-H2,Rate Id3,H2-H3,Rate Id4,H3-24
>>>>>>>>>> 2,,sd-7501.dedibox.fr,101(a)sd-7501.dedibox.fr,441,441,8,441,19,441,24,441,0
>>>>>>>>>>
>>>>>>>>>>
>>>>>>>>>>
>>>>>>>>>> 2,,sd-7501.dedibox.fr,106(a)sd-7501.dedibox.fr,441,441,8,441,19,441,24,441,0
>>>>>>>>>>
>>>>>>>>>>
>>>>>>>>>>
>>>>>>>>>> 2,,,33677832974,441,441,22,441,23,441,24,441,0
>>>>>>>>>>
>>>>>>>>>> Rates:
>>>>>>>>>> Ops,Gateway,Domain,Subscriber,Rate
>>>>>>>>>> Id,Destination,Price,App,Connect
>>>>>>>>>> 2,,sd-7501.dedibox.fr,,441,31800,2100,audio,4647
>>>>>>>>>> 2,,sd-7501.dedibox.fr,101(a)sd-7501.dedibox.fr,441,31800,200,audio,2364
>>>>>>>>>>
>>>>>>>>>>
>>>>>>>>>> 2,,sd-7501.dedibox.fr,102(a)sd-7501.dedibox.fr,441,31800,200,audio,245
>>>>>>>>>>
>>>>>>>>>> 2,,,33677832974,441,131,2100,,2426
>>>>>>>>>>
>>>>>>>>>>
>>>>>>>>>>
>>>>>>>>>> ShowPrice From=sip:101@sd-7501.dedibox.fr To=33677832974
>>>>>>>>>> Duration=59
>>>>>>>>>> 0.0000
>>>>>>>>>>
>>>>>>>>>> But it is still not working...
>>>>>>>>>> Could you spent some time sending me a part of yours...
>>>>>>>>>> And are you using CDRTool 5.2.1??
>>>>>>>>>>
>>>>>>>>>> Thanks
>>>>>>>>>>
>>>>>>>>>>
>>>>>>>>>> Dan-Cristian Bogos a écrit :
>>>>>>>>>>> Hi Marc,
>>>>>>>>>>>
>>>>>>>>>>> can u do me a favor and try adding in an international
>>>>>>>>>>> destination in
>>>>>>>>>>> your pricelist and try placing a call to it. See if you get
>>>>>>>>>>> billing
>>>>>>>>>>> calculation for it. I suspect that your billing doesn't match
>>>>>>>>>>> the
>>>>>>>>>>> destination due to prefixes which are normally stripped. Not
>>>>>>>>>>> quite a
>>>>>>>>>>> CDRTool internals expert but my installation simply works for
>>>>>>>>>>> international destinations.
>>>>>>>>>>>
>>>>>>>>>>> DanB
>>>>>>>>>>>
>>>>>>>>>>> On 8/9/07, Marc LEURENT <lftsy(a)free.fr> wrote:
>>>>>>>>>>>> Hello Dan-Cristian,
>>>>>>>>>>>>
>>>>>>>>>>>> I just want a simple thing, that when I'm connecting to the
>>>>>>>>>>>> rating engine using telnet: telnet 127.0.0.1 9024
>>>>>>>>>>>> When I enter such a command, that the price should be != 0:
>>>>>>>>>>>>
>>>>>>>>>>>> ShowPrice From=sip:101@sd-7501.dedibox.fr
>>>>>>>>>>>> To=sip:106@sd-7501.dedibox.fr Duration=59
>>>>>>>>>>>> 0.0000
>>>>>>>>>>>>
>>>>>>>>>>>> Help would be very grateful...
>>>>>>>>>>>> Thanks...
>>>>>>>>>>>>
>>>>>>>>>>>>
>>>>>>>>>>>> The rating engine is requesting the good radaact200708 table (I
>>>>>>>>>>>> have change my globac.inc conf file
>>>>>>>>>>>> "ser_radius"=>array(
>>>>>>>>>>>> "name" => "OpenSER",
>>>>>>>>>>>> "class" => "CDRS_ser_radius",
>>>>>>>>>>>> "table" =>
>>>>>>>>>>>> "radacct".date("Ym"),
>>>>>>>>>>>> ......
>>>>>>>>>>>>
>>>>>>>>>>>> )
>>>>>>>>>>>>
>>>>>>>>>>>>
>>>>>>>>>>>>
>>>>>>>>>>>> Here is a view of the rating tables... And I don't understand
>>>>>>>>>>>> where I'm wrong..
>>>>>>>>>>>>
>>>>>>>>>>>> Destinations:
>>>>>>>>>>>> Ops,Gateway,Domain,Subscriber,Destination Id,Description
>>>>>>>>>>>> 2,,sd-7501.dedibox.fr,,31800,Ma Dst TEST
>>>>>>>>>>>>
>>>>>>>>>>>> Customers:
>>>>>>>>>>>> Ops,Gateway,Domain,Subscriber,WeekDay,Fallback,WeekEnd,Fallback,Timezone,Incr,Minim
>>>>>>>>>>>>
>>>>>>>>>>>>
>>>>>>>>>>>>
>>>>>>>>>>>> 2,,sd-7501.dedibox.fr,101(a)sd-7501.dedibox.fr,441,,442,,Europe/Paris,20,1
>>>>>>>>>>>>
>>>>>>>>>>>>
>>>>>>>>>>>>
>>>>>>>>>>>> 2,,sd-7501.dedibox.fr,106(a)sd-7501.dedibox.fr,441,,442,,Europe/Paris,34,1
>>>>>>>>>>>>
>>>>>>>>>>>>
>>>>>>>>>>>>
>>>>>>>>>>>>
>>>>>>>>>>>> Profiles:
>>>>>>>>>>>> Ops,Gateway,Domain,Subscriber,Profile Id,Rate Id1,00-H1,Rate
>>>>>>>>>>>> Id2,H1-H2,Rate Id3,H2-H3,Rate Id4,H3-24
>>>>>>>>>>>> 2,,sd-7501.dedibox.fr,,441,442,8,441,19,441,24,441,0
>>>>>>>>>>>> 2,,sd-7501.dedibox.fr,,442,442,24,442,0,442,0,442,0
>>>>>>>>>>>>
>>>>>>>>>>>> Rates:
>>>>>>>>>>>> Ops,Gateway,Domain,Subscriber,Rate
>>>>>>>>>>>> Id,Destination,Price,App,Connect
>>>>>>>>>>>> 2,,,,441,31800,2100,audio,0
>>>>>>>>>>>> 2,,,,442,31800,200,audio,0
>>>>>>>>>>>>
>>>>>>>>>>>> Prepaid:
>>>>>>>>>>>> Ops,Account,Balance,Last change,Lock,Start time,Last
>>>>>>>>>>>> price,Max,Destination
>>>>>>>>>>>> 2,101(a)sd-7501.dedibox.fr,10030.0000,2007-08-08
>>>>>>>>>>>> 17:57:00,,0000-00-00 00:00:00,0.0000,0,
>>>>>>>>>>>> 2,106(a)sd-7501.dedibox.fr,20010.0000,2007-08-08
>>>>>>>>>>>> 17:38:09,,0000-00-00 00:00:00,0.0000,0,
>>>>>>>>>>>>
>>>>>>>>>>>>
>>>>>>>>>>>>
>>>>>>>>>>>>
>>>>>>>>>>>> ShowPrepaidAccounts Filter=sd-7501.dedibox.fr
>>>>>>>>>>>> Account=101(a)sd-7501.dedibox.fr Balance=10030.0000
>>>>>>>>>>>> Account=106(a)sd-7501.dedibox.fr Balance=20010.0000
>>>>>>>>>>>>
>>>>>>>>>>>>
>>>>>>>>>>>>
>>>>>>>>>>>>
>>>>>>>>>>>>
>>>>>>>>>>>> And here is my radacct200708 table:
>>>>>>>>>>>> RadAcctId AcctSessionId AcctUniqueId UserName
>>>>>>>>>>>> Realm NASIPAddress NASPortId NASPortType
>>>>>>>>>>>> AcctStartTime AcctStopTime AcctSessionTime
>>>>>>>>>>>> AcctAuthentic ConnectInfo_start ConnectInfo_stop
>>>>>>>>>>>> AcctInputOctets AcctOutputOctets CalledStationId
>>>>>>>>>>>> CallingStationId AcctTerminateCause
>>>>>>>>>>>> ServiceType FramedProtocol FramedIPAddress AcctStartDelay
>>>>>>>>>>>> AcctStopDelay SipMethod SipResponseCode SipToTag
>>>>>>>>>>>> SipFromTag
>>>>>>>>>>>> SipTranslatedRequestURI SipUserAgents
>>>>>>>>>>>> SipApplicationType SipCodecs SipRPID
>>>>>>>>>>>> SipRPIDHeader SourceIP SourcePort CanonicalURI DelayTime
>>>>>>>>>>>> Timestamp DestinationId Rate Price Normalized
>>>>>>>>>>>> BillingId MediaInfo RTPStatistics FromHeader
>>>>>>>>>>>> UserAgent Contact
>>>>>>>>>>>>
>>>>>>>>>>>> "2";"vjyxdmwkbbjajnc(a)192.168.95.50";"336224af44cd989a";"sip:106@sd-7501.dedibox.fr";"sd-7501.dedibox.fr";"88.191.45.91";"5060";;"2007-08-09
>>>>>>>>>>>>
>>>>>>>>>>>>
>>>>>>>>>>>>
>>>>>>>>>>>> 10:55:58";"2007-08-09
>>>>>>>>>>>> 10:56:03";"5";NULL;NULL;;"0";"0";;;"200";"Sip-Session";;;"0";"0";"INVITE";"200";"c0a80101-20e94fd";"nxitc";;;;;;;;;"101(a)sd-7501.dedibox.fr";;"0";;;NULL;"0";;NULL;;;;
>>>>>>>>>>>>
>>>>>>>>>>>>
>>>>>>>>>>>>
>>>>>>>>>>>>
>>>>>>>>>>>>
>>>>>>>>>>>>
>>>>>>>>>>>> And my syslog:
>>>>>>>>>>>>
>>>>>>>>>>>> Aug 9 11:00:03 sd-7501 CDRTool[17377]: Normalize datasource
>>>>>>>>>>>> ser_radius, database DB_radius, table radacct200708
>>>>>>>>>>>> Aug 9 11:00:03 sd-7501 CDRTool[17377]: Lock
>>>>>>>>>>>> ser_radius:radacct200708
>>>>>>>>>>>> Aug 9 11:00:03 sd-7501 CDRTool[17097]: ShowPrice Id=2
>>>>>>>>>>>> Timestamp=1186649758 Duration=5 inputTraffic=0 outputTraffic=0
>>>>>>>>>>>> From=sip:106@sd-7501.dedibox.fr
>>>>>>>>>>>> To=101(a)sd-7501.dedibox.fr Gateway= Application=audio
>>>>>>>>>>>>
>>>>>>>>>>>>
>>>>>>>>>>>>
>>>>>>>>>>>>
>>>>>>>>>>>>
>>>>>>>>>>>>
>>>>>> _______________________________________________
>>>>>> Users mailing list
>>>>>> Users(a)openser.org
>>>>>> http://openser.org/cgi-bin/mailman/listinfo/users
>>>
>
Hello Dan-Cristian,
I just want a simple thing, that when I'm connecting to the rating engine using telnet: telnet 127.0.0.1 9024
When I enter such a command, that the price should be != 0:
ShowPrice From=sip:101@sd-7501.dedibox.fr To=sip:106@sd-7501.dedibox.fr Duration=59
0.0000
Help would be very grateful...
Thanks...
The rating engine is requesting the good radaact200708 table (I have change my globac.inc conf file
"ser_radius"=>array(
"name" => "OpenSER",
"class" => "CDRS_ser_radius",
"table" => "radacct".date("Ym"),
......
)
Here is a view of the rating tables... And I don't understand where I'm wrong..
Destinations:
Ops,Gateway,Domain,Subscriber,Destination Id,Description
2,,sd-7501.dedibox.fr,,31800,Ma Dst TEST
Customers:
Ops,Gateway,Domain,Subscriber,WeekDay,Fallback,WeekEnd,Fallback,Timezone,Incr,Minim
2,,sd-7501.dedibox.fr,101(a)sd-7501.dedibox.fr,441,,442,,Europe/Paris,20,1
2,,sd-7501.dedibox.fr,106(a)sd-7501.dedibox.fr,441,,442,,Europe/Paris,34,1
Profiles:
Ops,Gateway,Domain,Subscriber,Profile Id,Rate Id1,00-H1,Rate Id2,H1-H2,Rate Id3,H2-H3,Rate Id4,H3-24
2,,sd-7501.dedibox.fr,,441,442,8,441,19,441,24,441,0
2,,sd-7501.dedibox.fr,,442,442,24,442,0,442,0,442,0
Rates:
Ops,Gateway,Domain,Subscriber,Rate Id,Destination,Price,App,Connect
2,,,,441,31800,2100,audio,0
2,,,,442,31800,200,audio,0
Prepaid:
Ops,Account,Balance,Last change,Lock,Start time,Last price,Max,Destination
2,101(a)sd-7501.dedibox.fr,10030.0000,2007-08-08 17:57:00,,0000-00-00 00:00:00,0.0000,0,
2,106(a)sd-7501.dedibox.fr,20010.0000,2007-08-08 17:38:09,,0000-00-00 00:00:00,0.0000,0,
ShowPrepaidAccounts Filter=sd-7501.dedibox.fr
Account=101(a)sd-7501.dedibox.fr Balance=10030.0000
Account=106(a)sd-7501.dedibox.fr Balance=20010.0000
And here is my radacct200708 table:
RadAcctId AcctSessionId AcctUniqueId UserName Realm NASIPAddress NASPortId NASPortType AcctStartTime AcctStopTime AcctSessionTime
AcctAuthentic ConnectInfo_start ConnectInfo_stop AcctInputOctets AcctOutputOctets CalledStationId CallingStationId AcctTerminateCause
ServiceType FramedProtocol FramedIPAddress AcctStartDelay AcctStopDelay SipMethod SipResponseCode SipToTag SipFromTag
SipTranslatedRequestURI SipUserAgents SipApplicationType SipCodecs SipRPID SipRPIDHeader SourceIP SourcePort CanonicalURI DelayTime
Timestamp DestinationId Rate Price Normalized BillingId MediaInfo RTPStatistics FromHeader UserAgent Contact
"2";"vjyxdmwkbbjajnc(a)192.168.95.50";"336224af44cd989a";"sip:106@sd-7501.dedibox.fr";"sd-7501.dedibox.fr";"88.191.45.91";"5060";;"2007-08-09
10:55:58";"2007-08-09
10:56:03";"5";NULL;NULL;;"0";"0";;;"200";"Sip-Session";;;"0";"0";"INVITE";"200";"c0a80101-20e94fd";"nxitc";;;;;;;;;"101(a)sd-7501.dedibox.fr";;"0";;;NULL;"0";;NULL;;;;
And my syslog:
Aug 9 11:00:03 sd-7501 CDRTool[17377]: Normalize datasource ser_radius, database DB_radius, table radacct200708
Aug 9 11:00:03 sd-7501 CDRTool[17377]: Lock ser_radius:radacct200708
Aug 9 11:00:03 sd-7501 CDRTool[17097]: ShowPrice Id=2 Timestamp=1186649758 Duration=5 inputTraffic=0 outputTraffic=0 From=sip:106@sd-7501.dedibox.fr
To=101(a)sd-7501.dedibox.fr Gateway= Application=audio
Hello everybody,
I want that openser can call a PSTN number for example:
0296487631. But in the request of INVITE, I see that the callee is
always
0296487631(a)opensersip.test.machine ( and opensersip.test.machine is my
sip server), that means the (uri==myself) is always ture. So this
request of INVITE can not reache the gateway of PSTN. Anybody can give
me some advices? This is my openser.cfg and I use openser+radius+mysql.
Thank you very much!!!
Yin
#
# $Id: openser.cfg 1827 2007-03-12 15:22:53Z bogdan_iancu $
# simple quick-start config script
# Please refer to the Core CookBook at
http://www.openser.org/dokuwiki/doku.php
# for a explanation of possible statements, functions and parameters.
#
# ----------- global configuration parameters ------------------------
debug=3 # debug level (cmd line: -dddddddddd)
fork=yes
log_stderror=no # (cmd line: -E)
children=4
# Uncomment these lines to enter debugging mode
#fork=no
#log_stderror=yes
#
port=5060
# ------------------ module loading ----------------------------------
#set module path
mpath="/usr/local/lib/openser/modules/"
# Uncomment this if you want to use SQL database
loadmodule "mysql.so"
loadmodule "sl.so"
loadmodule "tm.so"
loadmodule "rr.so"
loadmodule "maxfwd.so"
loadmodule "usrloc.so"
loadmodule "registrar.so"
loadmodule "textops.so"
loadmodule "mi_fifo.so"
# Uncomment this if you want digest authentication
# mysql.so must be loaded !
loadmodule "auth.so"
#loadmodule "auth_db.so"
loadmodule "auth_radius.so"
loadmodule "group_radius.so"
loadmodule "acc.so"
# ----------------- setting module-specific parameters ---------------
# -- mi_fifo params --
modparam("mi_fifo", "fifo_name", "/tmp/openser_fifo")
# -- usrloc params --
modparam("usrloc", "db_mode", 0)
modparam("auth_radius|group_radius|acc", "radius_config",
"/usr/local/etc/radiusclient-ng/radiusclient.conf")
modparam("group_radius","use_domain", 0)
modparam("auth_radius", "service_type", 15)
modparam("auth", "secret", "testing123")
modparam("acc", "radius_flag", 1)
modparam("acc", "radius_missed_flag", 2)
modparam("acc", "service_type", 15)
modparam("acc", "radius_extra",
"User-Name=$fU;Sip-Src-IP=$si;Sip-Src-Port=$sp")
# Uncomment this if you want to use SQL database
# for persistent storage and comment the previous line
#modparam("usrloc", "db_mode", 2)
# -- auth params --
# Uncomment if you are using auth module
#
#modparam("auth_db", "calculate_ha1", yes)
#
# If you set "calculate_ha1" parameter to yes (which true in this
config),
# uncomment also the following parameter)
#
#modparam("auth_db", "password_column", "password")
# -- rr params --
# add value to ;lr param to make some broken UAs happy
modparam("rr", "enable_full_lr", 1)
# ------------------------- request routing logic -------------------
# main routing logic
route{
# initial sanity checks -- messages with
# max_forwards==0, or excessively long requests
if (!mf_process_maxfwd_header("10")) {
sl_send_reply("483","Too Many Hops");
exit;
};
if (msg:len >= 2048 ) {
sl_send_reply("513", "Message too big");
exit;
};
#-------set flag for Radius Accounting
#if (!method=="OPTIONS") setflag(3);
if (method=="INVITE"){
log (1, "INVITE MESSAGE RECEIVED - START ACC\n");
setflag(1);
setflag(2);
};
if (method=="BYE"){
log (1, "BYE - STOP ACCOUNTING\n");
setflag(1);
};
if (method=="CANCEL"){
log (1, "CANCEL -STOP ACCOUNTING\n");
setflag(1);
};
if (!method=="REGISTER")
record_route();
if (loose_route()) {
# mark routing logic in request
append_hf("P-hint: rr-enforced\r\n");
route(1);
};
if (!uri==myself) {
append_hf("P-hint: outbound\r\n");
route(1);
if (method=="ACK") {
route(1);
exit;
}else
if (method=="CANCEL"){
route(1);
exit;
}else
if (method=="INVITE")
{
route(3);
exit;
}else
if (method=="REGISTER")
{
route(2);
exit;
};
lookup("aliases");
if (uri!=myself)
{
route(1);
exit;
};
if (!lookup("location"))
{
sl_send_reply("404","Not User PSTN Found");
exit;
};
route(1);
}
if (uri==myself) {
if (method=="REGISTER") {
# Uncomment this if you want to use digest
authentication
if
(!radius_www_authorize("opensersip.test.machine")) {
www_challenge("opensersip.test.machine",
"0");
exit;
};
save("location");
exit;
};
if (method=="INVITE") {
if
(!radius_proxy_authorize("opensersip.test.machine")){
proxy_challenge("opensersip.test.machine","0");
exit;
};
};
lookup("aliases");
if (!uri==myself) {
append_hf("P-hint: outbound alias\r\n");
route(1);
};
# native SIP destinations are handled using our USRLOC
DB
if (!lookup("location")) {
sl_send_reply("404", "Not SIP User Found");
exit;
};
append_hf("P-hint: usrloc applied\r\n");
};
route(1);
}
route[1] {
if (!t_relay()) {
sl_reply_error();
};
exit;
}
route[2] {
# Register Message Handler
sl_send_reply("100","Trying");
if (!radius_www_authorize("opensersip.test.machine")) {
www_challenge("opensersip.test.machine", "0");
exit;
};
if (!save("location"))
{
sl_reply_error();
};
}
route[3] {
if (uri=~"^sip:[0-9]{10}@") {
route(4);
exit;
};
if (!lookup("location")) {
if (uri=~"^sip:[0-9]{10}@") {
route(4);
exit;
};
sl_send_reply("404","User not Found");
exit;
};
route(1);
}
route[4] {
rewritehost("172.20.14.32");
route(1);
}
Hi,
At the top of my config I've put the following snippet for some SEMS
routings:
if(uri =~ ";my_domain=.+")
{
$var(mydom) = $(ru{uri.param,my_domain});
xlog("L_INFO", "domain='$var(mydom)'\n");
$ru = "sip:" + $rU + "@" + $var(mydom);
}
It does nothing more than changing an r-uri
"sip:user@domain;my_domain=otherdomain" to "sip:user@otherdomain". This
works fine for some requests, but then it starts to complain:
xl_get_ruri: ERROR while parsing the R-URI
domain=''
ERROR: parse_uri: bad host in uri (error at char
ERROR: parse_sip_msg_uri: bad uri <sip:user@>
So obviously the transformation $(ru{uri.param,my_domain}) doesn't
return the parameter anymore, but it's present in the r-uri. After a
restart it works again for some requests, then again stops working.
Any hints?
Andreas
Hi all,
I am using Openser 1.2.1 with presence module.
My question:
Is possible to work with different domains in the presence module?
For example:
I have two domains: domain1 and domain2. Its "talk" among itselves.
Did you understand?
Thanks.
Danilo
Hi All,
How we can done conference in SIP ?
We was already see in Tech-invite site but it not
helpfully for us........
Please tell what we do for conference......
Thanks in advance,
Amit Vijayvargiya
Thanks Dan for your reply,
One more thing I want to know can we configure openser to be only
complaint with RFC 2543 for testing purpose it should support RFC 3261.
Thanks,
Vikas C.G.
-----Original Message-----
From: Dan-Cristian Bogos [mailto:dan.bogos@gmail.com]
Sent: Wednesday, August 08, 2007 6:02 PM
To: Vikas CG.
Cc: users(a)openser.org
Subject: Re: [OpenSER-Users] Support for strict routing
Hi there Vikas,
OpenSER supports both types of routing, strict and loose-routing. It
is just a matter of how you decide to handle your request inside
routing scripts. In case of strict-routing, it is about keeping the
RURI intact and let it flow out without calling loose-routing
functions.
Cheers,
DanB
On 8/8/07, Vikas CG. <vikas_cg(a)spanservices.com> wrote:
> Hello everyone,
> Can any body know whether openser supports for strict routing.
> And how can we configure it.
> Thanks,
> Vikas C.G.
>
> _______________________________________________
> Users mailing list
> Users(a)openser.org
> http://openser.org/cgi-bin/mailman/listinfo/users
>