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@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@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
>>>>>
>>>>>
>>>>>
>>>>>
>>>>>
>>>>>