Tecnicas monitoreo reportes con Asterisk
Upcoming SlideShare
Loading in...5
×
 

Tecnicas monitoreo reportes con Asterisk

on

  • 5,864 views

 

Statistics

Views

Total Views
5,864
Views on SlideShare
5,857
Embed Views
7

Actions

Likes
1
Downloads
129
Comments
0

2 Embeds 7

https://twitter.com 6
http://a0.twimg.com 1

Accessibility

Categories

Upload Details

Uploaded via as Adobe PDF

Usage Rights

© All Rights Reserved

Report content

Flagged as inappropriate Flag as inappropriate
Flag as inappropriate

Select your reason for flagging this presentation as inappropriate.

Cancel
  • Full Name Full Name Comment goes here.
    Are you sure you want to
    Your message goes here
    Processing…
Post Comment
Edit your comment

Tecnicas monitoreo reportes con Asterisk Tecnicas monitoreo reportes con Asterisk Presentation Transcript

  • Técnicas para monitoreo y reportes con Asterisk Nicolás Gudiño asternic@gmail.com 4K Conference 2011 Buenos Aires Nicolás Gudiño - http://www.asternic.bizTuesday, December 6, 2011
  • Técnicas para monitoreo y reportes con Asterisk 4K Conference 2011 Agenda Archivos de registro / logs Call Detail Records / CDR Registro actvidad de colas / queue_log Channel Event Logging / CEL Asterisk Manager Interface / AMI Nicolás Gudiño - http://www.asternic.bizTuesday, December 6, 2011
  • Técnicas para monitoreo y reportes con Asterisk 4K Conference 2011 Archivos de registro - Logs Ideales para depuración de problemas /etc/asterisk/logger.conf ;console => notice,warning,error ;console => notice,warning,error,debug ;messages => notice,warning,error full => notice,warning,error,debug,verbose Nicolás Gudiño - http://www.asternic.bizTuesday, December 6, 2011
  • Técnicas para monitoreo y reportes con Asterisk 4K Conference 2011 Archivos de registro - Logs/var/log/asterisk/full [2011-11-18 15:42:36] VERBOSE[13927] pbx.c: -- Executing [s@macro-dial-one:37] Dial ("Local/605@from-queue-8891;2", "SIP/605,25,trM(auto-blkvm)") in new stack [2011-11-18 15:42:36] VERBOSE[13927] netsock2.c: == Using SIP RTP TOS bits 184 [2011-11-18 15:42:36] VERBOSE[13927] netsock2.c: == Using SIP RTP CoS mark 5 [2011-11-18 15:42:36] VERBOSE[13927] app_dial.c: -- Called SIP/605 [2011-11-18 15:42:36] VERBOSE[13887] app_queue.c: -- Local/605@from-queue-8891;1 is ringing [2011-11-18 15:42:36] VERBOSE[13928] app_mixmonitor.c: == Begin MixMonitor Recording Local/605@from-queue-8891;2 [2011-11-18 15:42:36] VERBOSE[13927] app_dial.c: -- SIP/605-00000094 is ringing [2011-11-18 15:42:36] VERBOSE[13887] app_queue.c: -- Local/605@from-queue-8891;1 is ringing [2011-11-18 15:42:37] VERBOSE[13927] app_dial.c: -- SIP/605-00000094 is ringing Fecha Nivel Thread Módulo Detalle Nicolás Gudiño - http://www.asternic.bizTuesday, December 6, 2011
  • Técnicas para monitoreo y reportes con Asterisk 4K Conference 2011 Archivos de registro - Logs Revisando últimas líneas de log #> tail -n 1000 /var/log/asterisk/full Filtrando logs para depuración #> grep 13928 /var/log/asterisk/full [2011-11-18 15:42:36] VERBOSE[13928] app_mixmonitor.c: == Begin MixMonitor Recording ... [2011-11-18 15:43:14] VERBOSE[13928] app_mixmonitor.c: == MixMonitor close filestream [2011-11-18 15:43:14] VERBOSE[13928] app_mixmonitor.c: == Executing [/var/lib/asterisk/... [2011-11-18 15:43:14] VERBOSE[13928] app_mixmonitor.c: == End MixMonitor Recording ... Nicolás Gudiño - http://www.asternic.bizTuesday, December 6, 2011
  • Técnicas para monitoreo y reportes con Asterisk 4K Conference 2011 Archivos de registro - Logs Comandos de consola Recargar configuración #> asterisk -rx “logger reload” Rotación de logs #> asterisk -rx “logger rotate” Ajuste de nivel de verbosidad #> asterisk -rx “core set verbose 10” Ajuste de nivel de depuración #> asterisk -rx “core set debug 3” Nicolás Gudiño - http://www.asternic.bizTuesday, December 6, 2011
  • Técnicas para monitoreo y reportes con Asterisk 4K Conference 2011 Call Detail Records - CDR Registro histórico de llamados Tarifación / facturación Análisis de volumen de llamados Estadísticas de uso Auditoría Nicolás Gudiño - http://www.asternic.bizTuesday, December 6, 2011
  • Técnicas para monitoreo y reportes con Asterisk 4K Conference 2011 Call Detail Records - CDR Diferentes back-ends csv manager radius sqlite odbc, etc Back-end mysql disponible en addons Nicolás Gudiño - http://www.asternic.bizTuesday, December 6, 2011
  • Técnicas para monitoreo y reportes con Asterisk 4K Conference 2011 Call Detail Records - CDR /etc/asterisk/cdr.conf [general] unanswered=no endbeforehexten=no [csv] usegmtime = yes ; log date/time in GMT loguniqueid = yes ; log uniqueid. loguserfield = yes ; log user field. accountlogs = yes ; create separate log file for each account code. Default is "yes" Nicolás Gudiño - http://www.asternic.bizTuesday, December 6, 2011
  • Técnicas para monitoreo y reportes con Asterisk 4K Conference 2011 Call Detail Records - CDR Campo de Usuario (userfield) Set(CDR(userfield)=Value) Puede usarse para guardar información extra en un registro CDR como ser: Tecla pulsada en IVR, nombre de grabación Cualquier variable de canal /etc/asterisk/cdr_mysql.conf [global] userfield=1 Nicolás Gudiño - http://www.asternic.bizTuesday, December 6, 2011
  • Técnicas para monitoreo y reportes con Asterisk 4K Conference 2011 Call Detail Records - CDR /var/log/asterisk/cdr-csv/Master.csv "","19524742","609","from-did-direct","""19524742"" <19524742>","SIP/zapuser-00000179","Local/FMPR-609@from- internal-b2c7;1","Dial","Local/FMPR-609@from-internal&Local/ FMGL-606@from-internal,22,trM(auto-blkvm)","2011-11-24 09:18:10","2011-11-24 09:18:26","2011-11-24 09:18:44", 34,18,"ANSWERED","DOCUMENTATION","1322126290.637","" "","19524742","605","from-internal-xfer","""19524742"" <19524742>","SIP/609-0000017a","SIP/605-0000017c","Dial","SIP/ 605,25,trM(auto-blkvm)","2011-11-24 09:18:44",,"2011-11-24 09:18:59",15,0,"NO ANSWER","DOCUMENTATION","1322126301.642","" Nicolás Gudiño - http://www.asternic.bizTuesday, December 6, 2011
  • Técnicas para monitoreo y reportes con Asterisk 4K Conference 2011 Call Detail Records - CDR Información util pero a veces incompleta Hay inconsistencias cuando se transfieren llamadas No es util para determinar el flujo de un llamado Nicolás Gudiño - http://www.asternic.bizTuesday, December 6, 2011
  • Técnicas para monitoreo y reportes con Asterisk 4K Conference 2011 Call Detail Records - CDR Asternic CDR Reports Nicolás Gudiño - http://www.asternic.bizTuesday, December 6, 2011
  • Técnicas para monitoreo y reportes con Asterisk 4K Conference 2011 Call Detail Records - CDR Asternic CDR Reports Módulo de FreePBX - GPL http://www.asternic.biz/downloads/asternic-cdr-reports Nicolás Gudiño - http://www.asternic.bizTuesday, December 6, 2011
  • Técnicas para monitoreo y reportes con Asterisk 4K Conference 2011 Actividad de colas - queue_log Registro detallado de actividad de colas Estadísticas de call center Eficiencia de agentes Nivel de servicio Auditoría Nicolás Gudiño - http://www.asternic.bizTuesday, December 6, 2011
  • Técnicas para monitoreo y reportes con Asterisk 4K Conference 2011 Actividad de colas - queue_log /var/log/asterisk/queue_log 1321903401|1321903368.260|101|NONE|ENTERQUEUE||asterisk|1 1321903417|1321903368.260|101|Soporte Paula|RINGNOANSWER|15000 1321903438|1321903368.260|101|Soporte Paula|RINGNOANSWER|15000 1321903449|1321903368.260|101|Soporte Paula|CONNECT|48|1321903443.267|5 1321904957|1321903368.260|101|Soporte Paula|COMPLETEAGENT|48|1508|1 1321945326|NONE|NONE|NONE|CONFIGRELOAD| 1321964669|1321964645.270|100|NONE|ENTERQUEUE||44438722|1 1321964685|1321964645.270|100|Soporte Paula|RINGNOANSWER|15000 1321964714|1321964645.270|100|Soporte Paula|RINGNOANSWER|15000 1321964738|1321964645.270|100|Soporte Paula|CONNECT|69|1321964727.277|10 1321964795|1321964645.270|100|Soporte Paula|COMPLETECALLER|69|57|1timestamp cola info adicional uniqueid agente evento Nicolás Gudiño - http://www.asternic.bizTuesday, December 6, 2011
  • Técnicas para monitoreo y reportes con Asterisk 4K Conference 2011 Actividad de colas - queue_log Asternic Call Center Stats Lite Nicolás Gudiño - http://www.asternic.bizTuesday, December 6, 2011
  • Técnicas para monitoreo y reportes con Asterisk 4K Conference 2011 Actividad de colas - queue_log Asternic Call Center Stats Lite - GPL3 http://www.asternic.biz/downloads/lite Nicolás Gudiño - http://www.asternic.bizTuesday, December 6, 2011
  • Técnicas para monitoreo y reportes con Asterisk 4K Conference 2011 Channel Event Logging - CEL Registro detallado de llamados Híbrido entre queue_log y CDR CDR con esteroides Nicolás Gudiño - http://www.asternic.bizTuesday, December 6, 2011
  • Técnicas para monitoreo y reportes con Asterisk 4K Conference 2011 Channel Event Logging - CEL /etc/asterisk/cel.conf [general] enable=yes apps=all events=ALL dateformat=%F %T Lo mínimo para empezar a usar CEL es habilitarlo con enable=yes y enumerar eventos con events=xxx. Nicolás Gudiño - http://www.asternic.bizTuesday, December 6, 2011
  • Técnicas para monitoreo y reportes con Asterisk 4K Conference 2011 Channel Event Logging - CEL Eventos disponibles en CEL CHAN_START , CHAN_END, ANSWER, HANGUP, CONF_ENTER, CONF_EXIT, CONF_START, CONF_END, APP_START, APP_END, PARK_START, PARK_END, BRIDGE_START, BRIDGE_END, 3WAY_START , 3WAY_END, BLINDTRANSFER, ATTENDEDTRANSFER, TRANSFER, HOOKFLASH, USER_EVENT ¡UN MONTONAZO! Nicolás Gudiño - http://www.asternic.bizTuesday, December 6, 2011
  • Técnicas para monitoreo y reportes con Asterisk 4K Conference 2011 Channel Event Logging - CEL /etc/asterisk/cel_custom.conf [mappings] Master.csv => ${CSV_QUOTE(${eventtype})},${CSV_QUOTE($ {eventtime})},${CSV_QUOTE(${CALLERID(name)})},${CSV_QUOTE (${CALLERID(num)})},${CSV_QUOTE(${CALLERID(ANI)})},$ {CSV_QUOTE(${CALLERID(RDNIS)})},${CSV_QUOTE(${CALLERID (DNID)})},${CSV_QUOTE(${CHANNEL(exten)})},${CSV_QUOTE($ {CHANNEL(context)})},${CSV_QUOTE(${CHANNEL(channame)})},$ {CSV_QUOTE(${CHANNEL(appname)})},${CSV_QUOTE(${CHANNEL (appdata)})},${CSV_QUOTE(${CHANNEL(amaflags)})},$ {CSV_QUOTE(${CHANNEL(accountcode)})},${CSV_QUOTE(${CHANNEL (uniqueid)})},${CSV_QUOTE(${CHANNEL(linkedid)})},$ {CSV_QUOTE(${CHANNEL(peer)})},${CSV_QUOTE(${CHANNEL (userfield)})},${CSV_QUOTE(${eventextra})} Nicolás Gudiño - http://www.asternic.bizTuesday, December 6, 2011
  • Técnicas para monitoreo y reportes con Asterisk 4K Conference 2011 Channel Event Logging - CEL /var/log/asterisk/cel_custom/Master.csv "CHAN_START" "1322126290.417117" "" "from-trunk-sip-zapuser" "" "HANGUP" "1322126306.752231" "609" "macro-dial-one" "AppDial" "ANSWER" "1322126290.433885" "49524742" "ivr-2" "Answer" "CHAN_END" "1322126306.752260" "609" "macro-dial-one" "AppDial" "APP_START" "1322126301.270181" "49524742" "macro-dial" "Dial" "APP_END" "1322126306.752321" "49524742" "macro-dial-one" "Dial" "CHAN_START" "1322126301.270458" "" "from-internal" "" "HANGUP" "1322126306.752498" "49524742" "from-internal" "" "CHAN_START" "1322126301.270551" "" "from-internal" "" "CHAN_END" "1322126306.752534" "49524742" "from-internal" "" "CHAN_START" "1322126301.271182" "" "from-internal" "" "BLINDTRANSFER" "1322126324.863833" "" "macro-dial" "AppDial" "CHAN_START" "1322126301.271246" "" "from-internal" "" "BRIDGE_END" "1322126324.934059" "49524742" "from-internal-xfer" "Dial" "APP_START" "1322126301.286019" "49524742" "macro-dial-one" "Dial" "HANGUP" "1322126324.934099" "" "from-internal-xfer" "AppDial" "CHAN_START" "1322126301.307455" "" "from-internal" "" "CHAN_END" "1322126324.937976" "" "from-internal-xfer" "AppDial" "APP_START" "1322126303.485284" "49524742" "macro-dial" "Dial" "APP_END" "1322126324.938097" "49524742" "from-internal-xfer" "Dial" "CHAN_START" "1322126303.485900" "" "from-internal" "" "APP_START" "1322126324.943018" "49524742" "macro-dial-one" "Dial" "ANSWER" "1322126306.698194" "609" "from-internal" "AppDial" "CHAN_START" "1322126324.943507" "" "from-internal" "" "ANSWER" "1322126306.713192" "49524742" "macro-dial-one" "Dial" "HANGUP" "1322126339.351786" "605" "from-internal" "AppDial" "BRIDGE_START" "1322126306.713233" "49524742" "macro-dial-one" "Dial" "CHAN_END" "1322126339.352030" "605" "from-internal" "AppDial" "ANSWER" "1322126306.713394" "" "from-internal" "AppDial" "APP_END" "1322126339.352151" "49524742" "macro-dial-one" "Dial" "HANGUP" "1322126306.713480" "" "from-internal" "AppDial" "HANGUP" "1322126339.353329" "49524742" "from-internal-xfer" "" "CHAN_END" "1322126306.713512" "" "from-internal" "AppDial" "CHAN_END" "1322126339.354762" "49524742" "from-internal-xfer" "" "HANGUP" "1322126306.714272" "606" "from-internal" "AppDial" "LINKEDID_END" "1322126339.354858" "49524742" "from-internal-xfer" "" "CHAN_END" "1322126306.714476" "606" "from-internal" "AppDial" "APP_END" "1322126306.714525" "49524742" "macro-dial" "Dial" "HANGUP" "1322126306.715063" "49524742" "from-internal" "" events=all "CHAN_END" "1322126306.724464" "49524742" "from-internal" "" "BRIDGE_START" "1322126306.730180" "49524742" "macro-dial" "Dial" "BRIDGE_UPDATE" "1322126306.746361" "" "macro-dial" "AppDial" ¡UN SOLO LLAMADO! Nicolás Gudiño - http://www.asternic.bizTuesday, December 6, 2011
  • Técnicas para monitoreo y reportes con Asterisk 4K Conference 2011 Channel Event Logging - CEL ¡¿Y el screenshot de la aplicación ?! Estoy trabajando en eso. Por lo pronto es una idea. Nicolás Gudiño - http://www.asternic.bizTuesday, December 6, 2011
  • Técnicas para monitoreo y reportes con Asterisk 4K Conference 2011 Asterisk Manager Interface - AMI Interfaz de gestión por socket tcp/5038 Permite controlar asterisk desde una aplicación externa. Recepción de eventos Envío de comandos Orientado a desarrolladores y para ser accedida por aplicaciones. Nicolás Gudiño - http://www.asternic.bizTuesday, December 6, 2011
  • Técnicas para monitoreo y reportes con Asterisk 4K Conference 2011 Asterisk Manager Interface - AMI Es un protocolo simple de texto plano Desde Asterisk 1.6.2 soporta cifrado TLS Este tipo de interfaz no es privativa de Asterisk. Freeswitch dispone de una interfaz similar llamada Event Socket. Nicolás Gudiño - http://www.asternic.bizTuesday, December 6, 2011
  • Técnicas para monitoreo y reportes con Asterisk 4K Conference 2011 Asterisk Manager Interface - AMI /etc/asterisk/manager.conf [general] enabled = yes [admin] secret = claveSuperSecreta deny=0.0.0.0/0.0.0.0 permit=127.0.0.1/255.255.255.0 read = all write = all eventfilter=!Event: RTCPSent eventfilter=!Event: RTCPReceived Nicolás Gudiño - http://www.asternic.bizTuesday, December 6, 2011
  • Técnicas para monitoreo y reportes con Asterisk 4K Conference 2011 Asterisk Manager Interface - AMI Eventos (recepción) Event: Hangup Privilege: call,all Channel: DAHDI/i2/555502341-2864 Uniqueid: 1313184096.179300 CallerIDNum: 555502341 CallerIDName: <unknown> ConnectedLineNum: 555502341 ConnectedLineName: <unknown> Cause: 16 Cause-txt: Normal Clearing Nicolás Gudiño - http://www.asternic.bizTuesday, December 6, 2011
  • Técnicas para monitoreo y reportes con Asterisk 4K Conference 2011 Asterisk Manager Interface - AMI Comandos (envío) Action: MailboxStatus Mailbox: 602@default Action: DBGet Family: CF Key: 606 ActionID: getvar!custom!CF/606 Nicolás Gudiño - http://www.asternic.bizTuesday, December 6, 2011
  • Técnicas para monitoreo y reportes con Asterisk 4K Conference 2011 Asterisk Manager Interface - AMI ¿Que tipo de aplicación podemos desarrollar usando AMI? Nicolás Gudiño - http://www.asternic.bizTuesday, December 6, 2011
  • Técnicas para monitoreo y reportes con Asterisk 4K Conference 2011 Asterisk Manager Interface - FOP2 - www.fop2.com Nicolás Gudiño - http://www.asternic.bizTuesday, December 6, 2011
  • Técnicas para monitoreo y reportes con Asterisk 4K Conference 2011 Desafío: FOP2 + Voz Adobe Flash soporta transmisión de datos continua via xmlsockets Adobe Flash soporta transporte de audio y video en tiempo real usando RTMP (Real Time Messaging Protocol) FOP2 utiliza xmlsockets de Flash para mostrar y controlar estado en tiempo real Entonces, ¿por qué no integrar audio en FOP2 usando RTMP? Nicolás Gudiño - http://www.asternic.bizTuesday, December 6, 2011
  • Técnicas para monitoreo y reportes con Asterisk 4K Conference 2011 Arquitectura FOP2 - RTMP * SIP RTMP UDP 5060 TCP 1935 Servidor Cliente/Navegador Proxy RTMP Asterisk Softphone Web Asterisk puro y duro Mediador / Proxy Softphone WEB Dispositivos SIP Libfreeswitch Javascript Sesion RTMP = Registro SIP Adobe Flash Transcodificación Speex Wideband - Codec Asterisk. Nicolás Gudiño - http://www.asternic.bizTuesday, December 6, 2011
  • Técnicas para monitoreo y reportes con Asterisk 4K Conference 2011 FOP2 - De consola a teléfono Reconversión de la interfaz de usuario, hay que superar la consola e incorporar la funcionalidad de teléfono. Agregado de Dialpad y DTMF Agregado de Acciones: Answer, Hold, Reject Reubicación de botones de control de llamados dentro del llamado activo. Nicolás Gudiño - http://www.asternic.bizTuesday, December 6, 2011
  • Técnicas para monitoreo y reportes con Asterisk 4K Conference 2011 FOP2: de consola a teléfono Dialpad / DTMF Módulo de softphone Selección de entrada de audio Nicolás Gudiño - http://www.asternic.bizTuesday, December 6, 2011
  • Técnicas para monitoreo y reportes con Asterisk 4K Conference 2011 FOP2: de consola a teléfono Reubicación de botones de control Nicolás Gudiño - http://www.asternic.bizTuesday, December 6, 2011
  • Técnicas para monitoreo y reportes con Asterisk 4K Conference 2011 ¿ Preguntas ? Nicolás Gudiño asternic@gmail.com Nicolás Gudiño - http://www.asternic.bizTuesday, December 6, 2011