[Asterisk-Users] 2nd call leg status?

Freddi Hansen fh at danovation.dk
Sun Jan 11 09:27:08 MST 2004


>
> Hi Folks,
>
> Wonder whether this question found an answer ?
>
> I too have a similar question that I can't find an answer so far.
>
> Let me first share my dial plan;
>
> exten => _011.,1,Authenticate(/etc/asterisk/auth.txt |a)
> exten => _011.,2,Playback(Pls-wait-while-I-connect)
> exten => _011.,3,Absolutetimeout(3600)
> exten => _011.,4,Dial(H323/${EXTEN:3}@GW_IP_ADDRESS,70)
> exten => _011.,5,NoCDR()  <=====if no answer cdr is not written
> exten => _011.,6,Busy
> exten => _011.,105,NoCDR()  <==== if called party is busy cdr not wirtten
> exten => _011.,106,Busy
> exten => i,1,NoCDR() <====== if authentication failed cdr not written
> exten => i,2,Hangup
>
> Here are my observations
>
> (a) Since Authenticate function is present in my dial paln,  disposition
> fieled in cdr always show Answered, so with that I can't figure out 
> whether
> H323 leg is successfully answered or not.
> (b) If the H323 g/w sends the busy signal then CDR is not written, If the
> g/w rings and timed out then again CDR is not written (as expected we 
> have
> priorities set for extensions)
> (c) Now if the called party is ringing and originating party just 
> hang-up, A
> CDR is written. I have no way to differentiate that with a very short 
> answer
> call.
>
> I think this behavior is a incorrect.
>
> If * answered a call and show up disposition as Answered, then that 
> call is
> a completed call. So there should be one record in the CDR.
>
> Then for the second leg there should be another record, as now * is
> originating a call again and expecting other side(in this case the 
> h323 g/w)
> to respond.
>
> If the both legs are considered as a single call, then cdr should show 
> the
> disposition of the final end point.
>
> Please show me if there is a way that I could generate two records in CDR
> for this kind of a call, or any other solution for this problem.
>
> Cheers
>
> SW


Hi,
I did have the same problem. I simply issue a ResetCDR(w) as the last 
thing before using
the Dial application. This will reset the 'answered' flag and the CDR 
you get from the Dial
will contain the correct value. I do later do a small of backend 
processing to get the correct
A-line time related to the call.
There may be smarter way of doing this but this quick hack works fine 
for me
Freddi








More information about the asterisk-users mailing list