This guide will focus on some less known but very useful tools that the Uniloader provides.
If you have a 24-hour call center, or want to upload backed up queue_log files, continue reading.

What is QueueMetrics?

QueueMetrics is a highly scalable monitoring software that lets you track agent productivity, payrolls, measure targets, conversion rates, ACD, IVR, Music on hold, generate outbound campaign statistics and monitor realtime processes with customizable wallboards.

You can measure all contact center activities with more than 200 different metrics and manage realtime processes with extensions and calls control, live alarms, whisper mode, spy and barge mode.

Queue-Replicate: replicate existing extensions on the queue, for 24-hour call centers

Uniloader is able to perform maintenance operations on the queues of an Asterisk system.

In case of a 24-hour call center (using Dynamic agents), you might notice that the realtime view and Wallboard will refresh at midnight. This means that the Agents will “disappear” from the Wallboard, and reappear once they have picked up a call on the queue.

If you want to change this behavior, you can use the “Queue-Replicate” tool.

Queue-Replicate will log agents off from a queue and will then log them back in, using the same name and state interface (if they are paused they will reappear paused).

This tool can be used manually, or you can set a cronjob like so:

# At one minute past midnight, replicate Asterisk presence
1      0       *       *       *       uniloader asterisk queue-replicate --host "127.0.0.1" --login cxpanel --secret cxmanager*con --dry-run 0

While this is not something we suggest, sometimes smaller call centers do not really care about agent tracking and want agents to always remain logged on.

NOTE: This does not work correctly if your QueueMetrics runs in Hotdesking mode, as Hotdesking events are not correctly replicated.

How to use it

NAME:
   uniloader asterisk queue-replicate - Replicates agent presence events

USAGE:
   uniloader asterisk queue-replicate [command options] [arguments...]

DESCRIPTION:
   Removes agents from queues as specified by the agent/queue
filters and then adds them in again, so that agent presence events
are replicated on the queue_log.

This is meant to be run as a cron job soon after the midnight, so that
agents that do not log in every day still appear on  the real-time page.

DO NOT USE if you are running in hotdesking mode, as hotdesking agents
will not be replicated correctly.

OPTIONS:
   --queues, -q   A regexp that details which queue ids to match, e.g. '^3..$'
   --agents, -a   A regexp that details which agents to match, e.g. '^SIP/\d+$' or '^.+?/523$'
   --host "127.0.0.1"   Your Asterisk server
   --port "5038"  The AMI port on Asterisk
   --login     The AMI user as defined in manager.conf
   --secret       The AMI secret [$AMISECRET]
   --dry-run, -d "1" When 1, this is a dry run. Set to 0 to perform changes on the PBX.

Example:

uniloader asterisk queue-replicate --host "127.0.0.1" --login cxpanel --secret cxmanager*con --dry-run 0

Queue-Kick: log off all (or some) extensions

This tool is useful in case your (dynamic) Agents forget to log out from the queue at the end of their shift, and you want to remove them from the queue in bulk, or specific agents.

Agents are unpaused before being logged off.

This is also useful to forcibly log off agents that managed to log in using impossible extensions or agent codes, in this case it can be run manually on demand or, for the hardest cases, scripted to run every few minutes to forcibly resolve such cases.

By using a regular expression for queues and/or agents, you can target a set of specific entities, e.g. all queues that start with 3, or all agents with a space in their name.

How to use it

NAME:
   uniloader asterisk queue-kick - Removes agents from queues

USAGE:
   uniloader asterisk queue-kick [command options] [arguments...]

DESCRIPTION:
   Removes all agents matching the agent/queue filters
specified as regular expressions on the command line.

This is meant to be run  as a cron job at the end of the work day.

OPTIONS:
   --queues, -q   A regexp that details which queue ids to match, e.g. '^3..$'
   --agents, -a   A regexp that details which agents to match, e.g. '^SIP/\d+$' or '^.+?/523$'
   --host "127.0.0.1"   Your Asterisk server
   --port "5038"  The AMI port on Asterisk
   --login     The AMI user as defined in manager.conf
   --secret       The AMI secret [$AMISECRET]
   --dry-run, -d "1" When 1, this is a dry run. Set to 0 to perform changes on the PBX.

Example:

uniloader asterisk queue-kick --host "127.0.0.1" --login cxpanel --secret cxmanager*con --dry-run 0

Uploading one, or all, queue_log files

If you are missing the data from a single queue_log file, from your QueueMetrics database, you can use this simple script (works only in DirectAMI-Live mode, basically for the hosted solution of QueueMetrics):

uniloader --src "/var/log/asterisk/queue_log-xxx" upload --uri "https://my.queuemetrics-live.com/INSTANCE" --login webqloader --pass PASSWORD --token ""

You will need to have:

src ⇾ path to the queue_log file
uri ⇾ URL for the QueueMetrics instance
login ⇾ in most cases it's "webqlaoder"
pass ⇾ "webqloader" password

If you want to add all the queue_log files from your PBX, you can use this script:

for FILE in $( find /var/log/asterisk -type f -iname "queue_log*" -printf "%T+ %p\n" | sort | awk '{print $2}' ) ; do uniloader --src "${FILE}" upload --uri https://my.queuemetrics-live.com/INSTANCE --token "" --pass "PASSWORD" --forced-upload ; done

Like above, you will need to have:

find ⇾ path to the queue_log folder
uri ⇾ URL for the QueueMetrics instance
pass ⇾ "webqloader" password

QueueMetrics References

QueueMetrics software is available on premise or as a cloud hosted service for FreePBX, Yeastar S PBX, Grandstream, Issabel, FusionPBX and many other Asterisk distros.

For more technical information please refer to the User Manual.

Visit www.queuemetrics.com for a free 15 days full-featured trial.

keyboard_arrow_left Back