Home

QueueMetrics

image

Contents

1. ssscccecccccceeceesseeeecececeeseeaseeseeeeeees 11 Running QueueMetrics to monitor a cluster of Asterisk ServeYs cccccccceeeeeeeeeeees 13 Installing Qloaderd on the Asterisk S rvePS cccccccsssssssseeeeececeeeeaeenseseeeeecceeessaaaeeses 13 Setting up QUCUCMETTICS cc cesssssseecccccceeccceesseeeccccceeeesceessseeecccceeessauaaasseeeeeeeeeeeaea 13 Tips and tricks tor loader dj ii5 cciestsatitniiaientraiainiaatinwaiauninmaniauniamuion 16 Checking how much data is in the database on a daily baSis ccccccccccceeeeeeeeeees 16 Optimizing queue lor access time yi dececcisierscinrnvarividesaxisdersunvndavecstrisiseaiavdusceveiibasnindeveiwens 16 Getting NGOs jcnupryanavrnasigiiemie a sew wai eiedeseioosuunsauenea emanate 17 File QM_mysql_cluster_100 doc Version 16 09 07 Loway Page 3 of 17 research Understanding MySQL storage and clustering QueueMetrics works by parsing an ACD event file called queue_log that Asterisk produces during its normal operations QueueMetrics is built to run with two different storage models e The Flat Ffile storage model lets the data reside in a file on the Asterisk server and is the default mode e The MySQL storage model uploads the data to a database using a small loader script called Qloaderd and has QueueMetrics read it back from that database Running through a flat file storage is usually enough for small call centers having both Asterisk and Queu
2. Loway QueueMetrics call center monitor Understanding MySQL storage and clustering in QueueMetrics AUTHOR LOWAY VERSION 1 0 DATE SEPTEMBER 16 2007 Loway di Lorenzo Emilitri Via Ligornetto 17a 6854 San Pietro Switzerland Loway Page 2 of 17 research Index Understanding MySQL storage and clustering ccccceccececccceeceeeesseeeeceeeeeeseaeeeeeeeeees 3 Enabling MYSQL storage assii osa iana ESA OEE ETNA N 3 Understanding MySQL storage a cisscsersnsiacndcacrisearasdiaadionaaasiaadansaaarinrinadimdiasimaviadin 4 Installing Qlbaderd cncadewimnronedawtmiimumemmramniumesumusoreummmemuemns 4 Installing on TrixBox or other CentOS based Linux distroS cccccceeeeeeeeeeeees 4 Manual Qloaderd iste lations sasssisaseessacssaiasannioossavasswnsacnsanmssaniaunstwasaectdvssaveitensaratinaisa 5 Customizing LIGA CELE iissccaiivistiavssnciseradintverseceisivs tec siennaansbriaderaasteusoeisaadinaceiarsbnniads 6 Starting and stopping Qloaderd oes cesesacesesesdvevesevessaavesdsevevesesesevesestaestvesasessaasevereresesess 7 Testing if data is actually being uploaded cecccccccccccceeeceesssseeeeceeceeeeeeaeeseeeeeees 8 Setting up QueueMetrics esosssseeeeeeeessssssseetrrerssssssssetrererssssseecereessssssseetreeresesssseeeeee 9 Changing the defaults cccccccccccccccccccccsssseeeccccceeeeseeesseececcceeesseuausseececeseeeseuaegeess 10 Using the QueueMetrics database inspector
3. Loway Page 9 of 17 research e For each queue we get an idea of how many records it generated i e how big it was As a rough estimate consider that each call generates an average of around three or four records but this is very dependent on how your call center is set up As your Asterisk system runs and data is uploaded into the database you should see the figures for the number of records rise between repetitions of the same query If the figures stand still or you do not see you partition at all this means that Qloaderd is not uploading data Setting up QueueMefbrics Setting up QueueMetrics is very straightforward if you click on Run custom reports and enter sql P001 as the filename you can check if your partition P001 contains data for the queue you just selected Demo Admin Administrator r B Your Logo QueueMetrics cali center monitor Oa sae iia ae Custom report analysis Queue oo All x Agent x Location E x Start Date 7 September v 2007 B o0 x End Date 14 September 2007 ha loo Wo File sql Poo1 Time zone offset No offset Join multi stint calls No E E Run custom report Start realtime monitoring Just remember to configure the queues you want to report on before running this test File QM_mysql_cluster_100 doc Version 16 09 07 Loway Page 10 of 17
4. centers in a simple way just by adding more inexpensive hardware to handle more calls and by putting yourself in a situation where a problem on a server will not take down the whole call center but just a fraction of it Enabling MySQL storage In order to enable MySQL storage you have to e Install Qloaderd on your Asterisk server and point it to the main QueueMetrics database File QM_mysql_cluster_100 doc Version 16 09 07 Loway Page 4 of 17 research e Tell QueueMetrics to run reports from the database Understanding MySQL storage In order to set up the system we first have to understand the concepts involved e The QueueMetrics database is a MySQL database loaded with the QueueMetrics default database schema This is usually installed with QueueMetrics as it is needed to make it work and can be on any machine as QueueMetrics will connect to it through a TCP IP socket When we refer to the database in the context of MySQL storage we are usually thinking about a table called queue_log that s where Asterisk log information is uploaded to e The database is logically divided into one or more partitions these are virtual tables all living within one single physical table Partitions are useful as they let you have more than one Asterisk queue data set living in the same database This is useful e g for testing or for sending multiple queue_log data sets to the same physical database for clusters You can call a partit
5. e The manager entry refers to the Asterisk manager API interface for that machine and is written as tcp login password server This is needed for Live monitoring and to login logoff pause agents Make sure there is a matching entry in the file etc asterisk manager conf on each server e The queuelog file refers to which partition the data for this server will be pulled from The format is the same as the sql partition format we previously encountered File QM_mysql_cluster_100 doc Version 16 09 07 Loway Page 15 of 17 research e The monitored_calls entry points to a disk share where call recordings for this machine are found This makes it possible to listen to calls through the QueueMetrics browser interface e The other entries should be left blank Now change the following property This is the default queue log files default queue_log_file cluster LL And restart QueueMetrics Now all queries you run are run on the whole cluster and the real time monitoring is run on the whole cluster as well For more detail on clustering in QueueMetrics see the section Monitoring clusters with QueueMetrics in the QueueMetrics user manual File QM_mysql_cluster_100 doc Version 16 09 07 Loway Page 16 of 17 research Tips and tricks for Qloaderd Checking how much data is in the database on a daily basis If you want a breakdown by day of the contents of the each partition you can run the f
6. not running If we click on the details of a partition we see a screen like the following one Details for partition rt N rows in partition 91 104 Queues Queue Entries qi q2 Agents 9 216 9 216 Agent Entries Agent 01 Agent 02 Agent 03 Agent 04 5184 6 912 6 336 6 912 From 2007 06 21 06 26 2007 06 21 06 26 From 2007 06 21 06 26 2007 06 21 06 26 2007 06 21 06 26 2007 06 21 06 26 To 2007 06 23 06 25 2007 06 23 06 25 To 2007 06 23 06 25 2007 06 23 06 25 2007 06 23 06 25 2007 06 23 06 25 Days Days 2 0 days 2 0 days 2 0 days 2 0 days 2 0 days 2 0 days This graphs show which are the queues and the agents available on the partition and also shows the oldest and most recent records regarding each queue or each agent File QM_mysql_cluster_100 doc Version 16 09 07 Loway Page 13 of 17 research Running QueueMef trics to monitor a cluster of Asterisk servers By using the Qloaderd mechanism it is possible to have a number of distinct Asterisk servers each uploading data to a different partition of the same QueueMetrics database This makes it possible to run an analysis that spans the whole cluster and not just one single Asterisk server To set up a cluster of Asterisk servers to be monitored through QueueMetrics you should adhere to the following deployment rules e Agent names must be unique throughout the call center that is you cannot have an
7. not possible to connect to the database very likely your server database user password or access grants are wrong File QM_mysql_cluster_100 doc Version 16 09 07 Loway Page 8 of 17 research Please note that in case of an error it will simply try again this way no matter what happens to your database Qloaderd will try again and again until it can establish a working connection and will then upload data Tous can natap or restart Qlvaderd using ne Tollowing commands 2 etc init d q loaderd stop Testing if data is actually being uploaded To make sure that data is being uploaded correctly you should log on to the database server gt open the MySQL shell and issue a oan like select partition queue count as n_ records rom queue_log roup by partition queue rder by partition queue The result should look something like partition queue n_records P003 myqueue 9 P003 NONE 121 P003 queue abc 2096 P003 queue test 1341 P003 UNK 17 P01 qq group 33000 P01 cust rajax 204 POL NONE 8139 RT NONE 8064 RT ql 9216 RT q2 9216 ll rows in set 0 16 sec This report shows e That we are using three distinct partitions P003 P01 and RT You will at first find only one e For each partition we see the Asterisk queue names involved plus the special keyword NONE File QM_mysql_cluster_100 doc Version 16 09 07
8. research Changing the defaults Of course you ll want QueueMetrics to automatically use the partition you choose as its default data source you can do this easily by editing the file configuration properties and setting This is the default queue log file i default queue_log_file sql gt POOL eee After restarting QueueMetrics the MySQL storage source will be used as a default File QM_mysql_cluster_100 doc Version 16 09 07 Loway Page 11 of 17 research Using the QueueMeftrics database inspector As it is not always easy to understand how much data is in the database QueueMetrics offers a database inspection tool to easily see which data is available You can enter it by clicking on the Mysql storage information link from the Edit QueueMetrics settings section if you do not find that link make sure your admin user holds the key USR_MYSQL If it takes a while to enter the page this is perfectly normal in order to produce the data seen through the inspector it performs a series of table scans As adding the correct indexes for faster analysis would use a lot of disk space and slow down the database system considerably versus an occasional use of the inspector they were not included with QueueMetrics 5 o Demo Admin Administrator oi 2 Your Logo QueueMetrics call center monitor gs sn H i Current storage info Total number of rows in table 151 253 Total tab
9. Agent 101 working on Asterisk server A and another Agent 101 working on Asterisk server B as their data would be mixed and it would be quite hard to tell who did what e Queue names may be shared over more than one server and QUEUEMETRICS will report on that queue as if it had been processed on one big single box e As the real time monitoring is per queue you can run real time monitoring on a queue by queue basis no matter on which physical servers those queues are hosted on or if they are hosted on more than one server This deployment makes it possible to grow your call center by adding more Asterisk servers as needed to handle the traffic Important in order to run a clustered version of QueueMetrics you need to use a special cluster licence key If you need to test this feature before purchasing you should ask for a cluster temporary key as the ordinary temporary keys do not natively support cluster mode Installing Qloaderd on the Asterisk servers To get started you must install Qloaderd on each Asterisk server and get sure that it is uploading data to the main QueueMetrics database Each server must uploading data to a distinct partition e g if you have three servers you could upload to partitions named S1 S2 and S3 In short each instance of Qloaderd is configured exactly as if it was in the single server MySQL storage model Setting up QueueMefbrics Setting QueueMetrics to work with clust
10. eMetrics living on the same server This is okay for small setups like 10 20 agents where the size of the quewe_log file will hardly ever reach the tens of megabytes On the contrary if you run a larger setup the advantages of the MySQL storage model become more important and worth the extra setup e You can install QueueMetrics on a separate server from the main Asterisk server This means that as your Asterisk server grows busier you don t want to risk that someone running a monster analysis through QueueMetrics might slow it down e You get a lot of added flexibility you can have MySQL Asterisk and QueueMetrics live on different servers and choose the best deployment model according to your actual usage load You can also create hot backup scenarios with a secondary QueueMetrics server that will take over in case the primary server should be down and you can take full advantage of the database s replication model to handle high load and high availability requirements e You get better efficiency MySQL is optimized to maximize disk access efficiency when dealing with a subset of the whole data e g getting today s information for just one queue will not need scanning your whole ACD history e You can have multiple Asterisk servers sending data to the same QueueMetrics instance and you can use that one instance to report on all activity through all servers we call this clustering This makes it possible to build very large call
11. ering requires a little effort as we must provide it with all information necessary to contact and distinguish each Asterisk server and perform its duties e g logging on agents File QM_mysql_cluster_100 doc Version 16 09 07 Loway Page 14 of 17 research We have to edit the configuration properties file and define the machines that make up our cluster by giving each a short name This name might be the same as the partition name or might be different as you best see fit In the following example we will setup a cluster of two machines one called aleph with its data uploaded on partition P001 and one called trix with its data uploaded to partition P002 Cluster to poll for RT data list of pipe separated members of the cluster cluster servers aleph trix This sets up a cluster made up of two Asterisk servers called aleph and trix For each box we then create an entry like the following one for aleph manager tcp dial 12345 10 10 3 5 aleph queuelog sql1 P001 aleph monitored_calls z qm_streamcall server_aleph aleph callfilesdir aleph audioRpcServer agentSecurityKey manager tcp admin amp111 127 0 0 1 queuelog sql P002 monitored_calls z qm_streamcall server_trix pled callfilesdir audioRpcServer agentSecurityKey The explanation of the entries is
12. ion any name you like as long as it does not exceed 5 characters e Qloaderd is a small Perl script that will upload the data Asterisk produces to one chosen partition It is built to be lightweight and pretty smart in case it is restarted it will automatically detect which data is already present in the database and upload only missing data It lives on the Asterisk server and points to the MySQL server QueueMetrics uses in order to run it you must decide a partition for it to upload data to If multiple copies of Qloaderd are run at once each copy must point to its own partition or data corruption will surely happen e QueueMetrics will access MySQL data by using a special file name that is usually sql partition In order to see what is going on with your database QueueMetrics offers a special MySQL storage inspection mode to see which partitions are available which are active and how much data is in them Installing Qloaderd First you have to install Qloaderd and then you ll have to configure it to suit your needs Installing on TrixBox or other CentOS based Linux distros If you run TrixBox or any other CentOS RHEL base Linux distro you can install Qloaderd very easily using the supplied yum package manager wget P etc yum repos d http yum loway ch loway repo yum install qloaderd i File QM_mysql_cluster_100 doc Version 16 09 07 Loway Page 5 of 17 research If in the future you ll want to
13. le QM_mysql_cluster_100 doc Version 16 09 07 Loway Page 6 of 17 research Customizing Qloaderd Before using Qloaderd you must tell it e The name and address of the MySQL database server e On which partition is it supposed to upload data to e The Asterisk log file it must upload e Its own error log file To set the name and address of the MySQL server edit the file usr local qloader qloader pl and change the following lines as needed F 1345 queuemetrics queuemetrics Javadude Please make sure that the MySQL server will allow connecting from the Asterisk server this can usually be obtained by running on the database server an SQL statement like Where the string 10 10 3 100 in the example is the internal IP address of the Asterisk box we re installing Qloaderd on To set the other parameters edit the file etc init d qloaderd and change the following parameters Ppartition P001000 EE queuelog var log asterisk queue_log If you are unsure what to set the partition to just leave it to P001 for the moment The queuelog parameter is the name of the file Asterisk produces and it is to be uploaded File QM_mysql_cluster_100 doc Version 16 09 07 Loway Page 7 of 17 research The logfile parameter is a log file where Qloaderd will write its activity to and that you can consult to debug problems Starting and stopping Qloaderd To test if eve
14. le space 15 9 M Data 11 2 M Indexes 4 7 M Partition Entries N calls From To Days of data Last heartbeat CERE 14 024 646 2007 05 29 05 04 2007 08 21 08 00 84 0 days 2007 08 21 08 15 ute 52 518 9 349 2007 06 28 06 00 2007 07 24 07 01 26 5 days 2007 07 29 07 32 P004 48 8 2007 08 19 08 25 2007 09 14 09 56 258days 2007 09 14 09 56 258 Pa 53 541 326 2006 01 17 01 36 2007 08 23 08 43 583 0days 2007 08 23 08 43 a 18 6 2007 08 30 08 20 2007 08 30 08 21 Oj days 2007 03 30 08 21 i rt 31 104 4608 2007 06 21 06 26 2007 06 23 06 25 20days 2007 06 23 06 25 m Note the Number of Calls shown here is meant as a rough estimate and may differ from the one actually shown by the reports From this page we see which partitions are available for analysis For each partition we can see e The total number of entries available e An estimated number of calls e The date of the oldest and most recent call entry e How many days does the data span over File QM_mysql_cluster_100 doc Version 16 09 07 Loway research Page 12 of 17 e The last heartbeat if there is no data to upload e g at night the Qloaderd will in any case upload a Heartbeat record every 15 minutes This makes it visible that even if there is no recent data in it a working Qloaderd is currently uploading data on that partition If there is no new data and the last heartbeat is over 20 minutes old this very likely means that the Qloaderd process is
15. ollowing query SELECT partition FROM_UNIXTIME time_id SY m d as date count as n_rows FROM queue_log GROUP BY partition FROM_UNIXTIME time_id i IME partition date n_rows P01 20070329 4216 P0O1 20070411 5 P0O1 20070412 3 rt 20070508 9365 rt 20070509 13248 rt 20070510 3883 6 rows in set 0 45 sec And will tell you how many rows were uploaded per partition per day Optimizing queue_log access time If you want to make QueueMetrics access to the database faster you can run the following query to reorganize data on disk ALTER TABLE queue_log ER BY partition time_id unique_row_count This query might take a very long time to complete if the database is big and will lock the table until completion so it should be run in a moment when the system is idle e g at night through a cron job File QM_mysql_cluster_100 doc Version 16 09 07 Loway Page 17 of 17 research Getting help If you still are having problems installing or running QueueMetrics we suggest you check out the following resources The QueueMetrics FAQ at http queuemetrics com faq jsp are a collection of common solved problems that many people experienced with QueueMetrics If you are struck by an error message this is the first place to look at The official QueueMetrics User Manual can be
16. read online at http queuemetrics com manual jsp and provides very detailed documentation on all aspects of QueueMetrics The QueueMetrics forums at http forum queuemetrics com will help you in pinpointing your problems and getting community support They will also be helpful in seeing what other people are doing with QueueMetrics AstRecipes is a wiki collecting Asterisk recipes aimed mostly at call center users see http astrecipes net You may want to contact Loway if your problems are still unsolved see http queuemetrics com contact jsp for all relevant contact information File QM_mysql_cluster_100 doc Version 16 09 07
17. rything is in order you can now start Qloaderd by running It should start up and start writing to its own log file To see if everything is okay you just run And it should output something like Fri Sep 14 09 33 24 2007 QueueMetrics MySQL loader Revision 1 Fri Sep 14 09 33 24 2007 Partition P001 PID 2827 TZ offset 0 Heartbeat after 900 s Pri Sep 14 09 33 24 2007 Now connecting to DB qm14 on 10 10 3 5 as user queuemetrics with password queuemetrics Pri Sep 14 09 33 24 2007 Ignoring all timestamps below 0 As you can see it states what it is trying to do and will start uploading data Every 100 lines of uploaded data or 900 seconds of Asterisk ACD inactivity it will output a reference line that tells how much data it has uploaded in the current usage session If you see something like Fri Sep 14 09 25 49 2007 QueueMetrics MySQL loader Revision 1 Fri Sep 14 09 25 49 2007 Partition P001 PID 2749 TZ offset 0 Heartbeat after 900 s Fri Sep 14 09 25 49 2007 Now connecting to DB log_code on 10 10 3 5 as ser ldap with password ldappo Fri Sep 14 09 25 49 2007 ERROR FOUND Fri Sep 14 09 25 49 2007 Error type dr pI Fri Sep 14 09 25 49 2007 Statement 4 4 Jj c Fri Sep 14 09 25 49 2007 Error Unknown database log_code 2007 Waiting 15s before reattempting to connect fan I BBS de oS This means that it was
18. upgrade it you will do it by running The installation process installs all necessary components and dependencies Qloaderd itself and starts it immediately Qloaderd is installed in usr local qloader and its startup script is installed as etc init d qloaderd If you just installed Qloaderd it using yum skip to section Customizing Qloaderd Manual Qloaderd installation In order to download the Qloaderd package go to the Downloads page on QueueMetrics website Make sure you have the following packages available in your system as Qloaderd will use Perl s DBI to connect to MySQL hae _ libdbi drivers Unpack the Qloaderd tar ball and copy the file qloader p1 to a location of your choice we suggest usr local qloader Run the following commands to make sure the file is executable cd usr local qloader i SOSOSS dos2unix qloader pl We also provide a plain vanilla startup script that can be installed in your local startup directory in order to start Qloader automatically It may require a bit of tweaking but it will run on all Linux distributions You should very likely copy it from Other initscript to etc init d on your system Run the following commands to make sure the file is executable dos2unix etc init d qloaderd _chmod x E etc i init Eai d gloaderd In anaes to have the service started on boot use the onmi Or what is equivalent for your distribution Fi

Download Pdf Manuals

image

Related Search

QueueMetrics queuemetrics queuemetrics login queuemetrics s2g queuemetrics agent login queuemetrics ssg queuemetrics live queuemetrics documentation queuemetrics ssl queuemetrics shop queuemetrics nginx

Related Contents

VGN-AR590E  UM10459 User manual for the BGU7007 GPS LNA evaluation board    [English] 10 MB  u lrlvl e 9 s fl 0 L g D:.A - e  Jabra BIZ 1900 Duo  User Manual ALFA 21 and ALFANET 21  Harbor Freight Tools 94515 User's Manual  Diagnostica, Ispezione e Localizzazione  manual - blackspiral.org  

Copyright © All rights reserved.
Failed to retrieve file