[asterisk-users] asterisk cdr - remote ip address - SOLVED

marek cervenka cervajs at fpf.slu.cz
Fri Nov 20 12:45:55 CST 2009


for the record
(added to http://www.voip-info.org/wiki/view/Asterisk+cdr+mysql)

some_context
;dial trunk
exten => _X.,1,Dial(SIP/trunk/${EXTEN})

;exten h must be in same context!
exten => h,1,noop("extended CDR")
exten => h,n,set(CDR(hangupcause)=${HANGUPCAUSE})                  ; hangupcause
exten => h,n,set(CDR(peerip)=${CHANNEL(peerip)})                   ; like 10.0.0.5 if behind nat
exten => h,n,set(CDR(recvip)=${CHANNEL(recvip)})                   ; like 194.79.52.192 - public ip
exten => h,n,set(CDR(from)=${CHANNEL(from)})                       ; like sip:1111 at sip.proxy.cz
exten => h,n,set(CDR(uri)=${CHANNEL(uri)})                         ; like sip:1111 at 10.0.0.5
exten => h,n,set(CDR(useragent)=${CHANNEL(useragent)})             ; useragent like Aastra_57i
exten => h,n,set(CDR(codec1)=${CHANNEL(audioreadformat)})          ; codec *
exten => h,n,set(CDR(codec2)=${CHANNEL(audiowriteformat)})         ;
exten => h,n,set(CDR(llp)=${CHANNEL(rtpqos,audio,local_lostpackets)})   ; lost packets by local end **
exten => h,n,set(CDR(rlp)=${CHANNEL(rtpqos,audio,remote_lostpackets)})  ; lost packets by remote end
exten => h,n,set(CDR(ljitt)=${CHANNEL(rtpqos,audio,local_jitter)})      ; the same for jitter
exten => h,n,set(CDR(rjitt)=${CHANNEL(rtpqos,audio,remote_jitter)})

* i dont know if the same channel can have different audioreadformat and 
audiowriteformat. imho not

** RTPAUDIOQOS isnt ok. check 
http://lists.digium.com/pipermail/asterisk-biz/2009-November/031910.html

known problem:
it is only for caller. i dont know how to log call leg B


>> -----Original Message-----
>> From: asterisk-users-bounces at lists.digium.com
>> [mailto:asterisk-users-bounces at lists.digium.com] On Behalf Of marek cervenka
>> Sent: Monday, November 16, 2009 8:50 AM
>> To: asterisk-users at lists.digium.com
>> Subject: [asterisk-users] asterisk cdr - remote ip address
>>
>> hi,
>>
>> i want add info about remote party ip address to the asterisk cdr table
>>
>> can you recommend me "the system way"?

---------------------------------------
Marek Cervenka
=======================================




More information about the asterisk-users mailing list