Rv: Re: Rv: Re: [Serusers] accounting accuracy

Iqbal iqbal at gigo.co.uk
Sat Jul 23 14:03:55 CEST 2005


has_totag check for this, this will remove all your re-invites

Iqbal

On 7/23/2005, "sermail at systemsrm.co.uk" <sermail at systemsrm.co.uk> wrote:

>Here is my two pence ( having just found a problem with my accounting ! ) :-
>
>SER timestamps the first INVITE the same as the first ACK, so the start of
>the call is correct.
>
>The last BYE is timestamped with the end of the call. So the difference IS
>the duration of the call.
>
>The catch is that if your UA has session timers enabled, then they will send
>out further INVITES to SER every 3 minutes in my case. SER responds with
>additional ACKs. This is a mechanism to ensure the call stays up.
>
>The problem is that you need to ignore all these other INVITEs and ACKs
>which have the same called anyway.
>
>So make sure you measure duration between the FIRST INVITE and the last and
>only BYE.
>
>This caught me out for a bit ! !
>
>
>Hope this helps.
>
>
>Simon
>ONSip.org Editor
>
>-----Original Message-----
>From: serusers-bounces at iptel.org [mailto:serusers-bounces at lists.iptel.org] On
>Behalf Of Jon Mansey
>Sent: 22 July 2005 20:11
>To: serusers at lists.iptel.org
>Subject: RE: Rv: Re: Rv: Re: [Serusers] accounting accuracy
>
>Regarding accounting using INVITE, unless Im mistaken, the billable
>talk-time of a call is between the ACK after the invite, ie when the call
>actually goes live, and the BYE. If you bill from the INVITE, you would be
>billing for ringing time also, maybe error messages etc.
>
>Having said that I notice that SER accounting doesn't log the INVITE
>immmediately as it is sent from the caller, it in fact logs it almost
>simultaneously just before the ACK, so the difference in accounting is
>probably minimal if your account is driven from the acc module and not from
>the actual event.
>
>This may not be your issue because you say the error is in favor of your
>provider.
>
>In order to tell which INVITEs resulted in billable calls, you have to do
>missed-call accounting so as to ignore the invites that resulted in 4xx
>failures. Only INVITE/ACK pairs with a matching BYE are billable.
>
>jm
>
>> -----Original Message-----
>> From: serusers-bounces at lists.iptel.org
>> [mailto:serusers-bounces at lists.iptel.org] On Behalf Of Iqbal
>> Sent: Friday, July 22, 2005 11:51 AM
>> To: Nhadie
>> Cc: serusers at lists.iptel.org
>> Subject: Re: Rv: Re: Rv: Re: [Serusers] accounting accuracy
>>
>>
>> You can, but from what I have heard (when I looked at it a few months
>> ago) it was pretty useless, so I would avoid it.
>>
>> If you have alot of BYE, then that is where the difference
>> is, all those
>> INVITES without a BYE you are not accounting for, but the gateway
>> provider always gets a BYE. Now you need to work out why you are not
>> getting the BYE, either the gateway is not sending them to
>> you, which I
>> find strange, or if they are sending you are not
>> recording...which again
>> is strange because you would either record none, OR all.
>>
>> Maybe the calle is not hanging up the call for whatever
>> reason, if that
>> is the case no BYE will get sent, but what your gateway
>> provider should
>> do is to send you a BYE if their is a period of inactivity,
>> if they dont
>> , u might need to find other clever solutions, by using
>> session-timers,
>> to ask for re-invites from the user, and if you dont get
>> them, insert a
>> BYE yourself.
>>
>> Iqbal
>>
>> PS I have cc'd this to the list, just in case others have
>> similar problems,
>>
>> Nhadie wrote:
>>
>> >I see some INVITES that doesn't have a BYE. sip_status are 200 don't
>> >know if that's a cmplete call are not, but there's really alot.
>> >
>> >by the way it's in the favor of the provider, tough luck for me.
>> >
>> >can I just simply implement an open source billing system?
>> like trabas
>> >www.trabas.com.
>> >
>> >--------- Mensagem Original --------
>> >From: Iqbal <iqbal at gigo.co.uk>
>> >To: Nhadie <nhadie at cbcpworld.com>
>> >Cc: serusers at lists.iptel.org
>> >Subject: Re: Rv: Re: [Serusers] accounting accuracy
>> >Date: 23/07/05 10:35
>> >
>> >
>> >
>> >>The fields seem to be correct at a first glance, as long as you are
>> >>matching INVITE and BYE, it should be okay. I presume your not
>> >>allowing users to do anything like call forwarding, if you are the
>> >>accounting fields for that are slightly different.
>> >>
>> >>10% diff per month is alot, is it in the favour of the gateway...if
>> >>its in your favour...dont tell anyone :-)
>> >>
>> >>Is the number of calls to a particular country add up, i.e
>> ser shows
>> >>10 calls to India, does the gateway also, is there a particular
>> >>country destination which is showing the largest incorrect minutes.
>> >>
>> >>When you hang up a call, have u checked to see how quickly the BYE
>> >>hits your acc table, and what the time stamp on it is,
>> especially if
>> >>the callee hangs up, i.e the BYE comes from the gateway. Do
>> you have
>> >>any unmatched calls, i.e INVITES without a BYE, if so how
>> >>
>> >>
>> >many.
>> >
>> >
>> >>Any problems with power failures i.e endpoints not being
>> able to send
>> >>a
>> >>
>> >>
>> >BYE.
>> >
>> >
>> >>Iqbal
>> >>
>> >>PS I haven't been knighted as yet, hence you dont need to call me
>> >>Sir...but I am petitioning the Queen as soon as I get a chance :-)
>> >>
>> >>Nhadie wrote:
>> >>
>> >>>We are averaging 17000 minutes a month. The gateway
>> provider will
>> >>give
>> >>
>> >>
>> >us a
>> >
>> >
>> >>>weekly report that has number of minutes per country, it's not
>> >>
>> >>
>> >detailed per
>> >
>> >
>> >>>call.
>> >>>
>> >>>actually sir i'm more worried if it's a problem on my billing
>> >>system,
>> >>
>> >>
>> >am I
>> >
>> >
>> >>>using the right fields to extract the data?
>> >>>
>> >>>--------- Mensagem Original --------
>> >>>From: Iqbal <iqbal at gigo.co.uk>
>> >>>To: Nhadie <nhadie at cbcpworld.com>
>> >>>Cc: serusers at lists.iptel.org
>> >>>Subject: Re: [Serusers] accounting accuracy
>> >>>Date: 23/07/05 10:13
>> >>>
>> >>>
>> >>>
>> >>>>Hi
>> >>>>
>> >>>>Are you/is your provider rounding up/down the number of
>> >>minutes,
>> >>
>> >>
>> >or do
>> >
>> >
>> >>>>you get raw CDR from them.
>> >>>>
>> >>>>1000 mins different out of how many total ?, and does the
>> >>gateway
>> >>
>> >>
>> >show
>> >
>> >
>> >>>>more than SER or less each time.
>> >>>>
>> >>>>Have you looked at one call, try making a test
>> call, time it
>> >>on
>> >>
>> >>
>> >your
>> >
>> >
>> >>>>stop watch for 60 secs, and see what ser shows and what the
>> >>
>> >>
>> >gateway shows.
>> >
>> >
>> >>>>
>> >>>>I have run for sometime, and I havent really seen much
>> >>discrepancy
>> >>
>> >>
>> >in
>> >
>> >
>> >>>>the cdrs from upstream gateways...this is not to
>> say it cannot
>> >>
>> >>
>> >happen.
>> >
>> >
>> >>>>
>> >>>>iqbal
>> >>>>
>> >>>>
>> >>>>
>> >>>>Nhadie wrote:
>> >>>>
>> >>>>&gt;Hi list,
>> >>>>&gt;
>> >>>>&gt;I'm having problem with my accounting, I have a SIP
>> >>server
>> >>
>> >>
>> >and I'm
>> >
>> >
>> >>>>
>> >>>>
>> >>>using a
>> >>>
>> >>>
>> >>>>&gt;commercial gateway provider where I can terminate
>> >>calls. >>&gt; >>&gt;Unfortunately,
>> there's a big
>> >>discrepancy on the number of
>> >>
>> >>
>> >minutes I
>> >
>> >
>> >>>>
>> >>>>
>> >>>see on
>> >>>
>> >>>
>> >>>>&gt;my billing system, compared to the billing of the
>> >>gateway
>> >>
>> >>
>> >provider.
>> >
>> >
>> >>>>
>> >>>>
>> >>>Every
>> >>>
>> >>>
>> >>>>&gt;month there's always almost a thousand or
>> more minutes
>> >>
>> >>
>> >diiference.
>> >
>> >
>> >>>>&gt;
>> >>>>&gt;For my billing system, i used the following
>> fields to
>> >>get
>> >>
>> >>
>> >the start of
>> >
>> >
>> >>>>
>> >>>>
>> >>>call,
>> >>>
>> >>>
>> >>>>&gt;sip_method=INVITE sip_status=200 and
>> >>username='username of
>> >>
>> >>
>> >caller',
>> >
>> >
>> >>>>
>> >>>>
>> >>>then to
>> >>>
>> >>>
>> >>>>&gt;get the end of call, sip_method sip_callid totag and
>> >>
>> >>
>> >fromtag. are
>> >
>> >
>> >>>>
>> >>>>
>> >>>these
>> >>>
>> >>>
>> >>>>&gt;correct?
>> >>>>&gt;
>> >>>>&gt;Am I doing something wrong there? Also
>> someone told me
>> >>I
>> >>
>> >>
>> >need a B2BUA
>> >
>> >
>> >>>>
>> >>>>
>> >>>for
>> >>>
>> >>>
>> >>>>&gt;the calls to be accurate, is this true?Hope
>> anyone can
>> >>
>> >>
>> >help me. TIA
>> >
>> >
>> >>>>&gt;
>> >>>>&gt;Regards
>> >>>>&gt;Nhadie
>> >>>>&gt;
>> >>>>&gt;_______________________________________________
>> >>>>&gt;Serusers mailing list
>> >>>>&gt;serusers at lists.iptel.org
>> >>>>&gt;http://lists.iptel.org/mailman/listinfo/serusers
>> >>>>&gt;
>> >>>>&gt;.
>> >>>>&gt;
>> >>>>&gt;
>> >>>>&gt;
>> >>>>
>> >>>>
>> >>>>
>> >>>>
>> >>>>
>> >>>>
>> >>>>
>> >>>
>> >>>
>> >>>.
>> >>>
>> >>>
>> >>>
>> >>
>> >>
>> >>
>> >>
>> >>
>> >>
>> >>
>> >
>> >
>> >.
>> >
>> >
>> >
>>
>> _______________________________________________
>> Serusers mailing list
>> serusers at lists.iptel.org http://lists.iptel.org/mailman/listinfo/serusers
>>
>
>_______________________________________________
>Serusers mailing list
>serusers at lists.iptel.org
>http://lists.iptel.org/mailman/listinfo/serusers
>
>_______________________________________________
>Serusers mailing list
>serusers at lists.iptel.org
>http://lists.iptel.org/mailman/listinfo/serusers
>
>




More information about the sr-users mailing list