VICIdial agent shows LAGGED
As VICIdial prints it
LAGGED
Where it appears. In the Agent LAGGED Report and the LAGGED Summary of the Admin Utilities page. An agent who was waiting for calls sees "Your session has been paused" on the agent screen.
To the point
LAGGED is the pause code the dialer writes when an agent's browser has sent no update for 30 seconds. It pauses the agent so no call is sent to a screen that is not answering.
What it means
While an agent is logged in, the agent screen calls the web server once a second, and each call writes to the agent's row in the live agents table. The database stamps the row with the time of that write.
The dialer's auto-dial process looks for agents on its server who are not paused and whose row is more than 30 seconds old. For each one it marks the agent's current log entry with the sub-status LAGGED and the pause type SYSTEM, opens a new log entry, sets the agent to PAUSED and adds a LOGOUT event to the user log.
The agent is paused, not removed: the live agent row stays where it is. When the browser reaches the server again it finds itself paused while it was waiting for calls. After more than ten checks in that state it shows "Your session has been paused" and puts its own display into pause.
Causes
- The agent's browser stopped reaching the web server. Trustane's agent check gives the usual reasons: a tab in the background that the browser slows down, a laptop that went to sleep, and the agent's own internet connection.
- The write did not go through. Each update is a request to the web server and one write to the database. If either stalls for half a minute, no row on that server is refreshed and all its agents are paused together.
- The dialer's clock runs ahead of the database's. The 30 seconds are counted on the dialer's clock and held against a time the database stamped. On a cluster, a dialer that is ahead sees agents as late when they are not.
Checks
- Reports > Admin Utilities. Agent LAGGED Report and LAGGED Summary list the events. Agent Latency Report and Latency Gaps sit on the same line. The Admin Utilities link is at the foot of the Reports page for level 9 users whose group may see it.
- Read the pattern. One agent, again and again, fits cause 1. Many agents in the same minute fit cause 2 or 3.
- Reports, the server table. The + beside SERVER adds each server's time, with PHP Time and DB Time under them. Set the three against each other.
Fix
- For one agent: keep the agent screen in a tab at the front, stop the computer from sleeping, and use a cable in place of Wi-Fi.
- After the alert the agent resumes from pause. The LOGOUT event stays in the user log, though the agent never logged out.
- For a whole floor: find what held up the web server or the database in that minute before changing any agent setting.
- For clocks: see the time synchronization warning.
On a Trustane server
The agent check in the console shows how many seconds ago an agent's screen last reported, and how many LAGGED entries the server logged for that agent in the last 24 hours and the last 7 days.
Related messages
- There is a time synchronization problem with your system: the clocks behind cause 3.
- No one is in your session: the phone dropped, not the browser.
- Your session has been disabled: the agent's row is gone, not just paused.
Sources
Every statement above about VICIdial was read from its own source code at the revision given. An installed server can run another revision: compare before you rely on a line number.
- VICIdial svn r4037, www/agc/conf_exten_check.php, lines 882-894: the write made on every check so the agent "is shown to be alive", tried again on a database error
- VICIdial svn r4037, www/agc/conf_exten_check.php, lines 1029-1032: the same write on the other branch of the check
- VICIdial svn r4037, www/agc/vicidial.php, line 6363: the one second between two checks
- VICIdial svn r4037, extras/MySQL_AST_CREATE_tables.sql, lines 394-408: the live agents table: the database stamps the row on each write
- VICIdial svn r4037, bin/AST_VDauto_dial.pl, lines 3644-3662: agents not paused whose row is older than the cutoff
- VICIdial svn r4037, bin/AST_VDauto_dial.pl, lines 3676-3719: LAGGED and SYSTEM written to the log, a new log entry, the agent set to PAUSED
- VICIdial svn r4037, bin/AST_VDauto_dial.pl, line 3761: the LOGOUT event added to the user log
- VICIdial svn r4037, bin/AST_VDauto_dial.pl, lines 5399-5408: the cutoff: 30 seconds before now on the dialer's clock
- VICIdial svn r4037, www/agc/vicidial.php, lines 8504-8517: "Your session has been paused", after more than ten checks found paused while waiting
- VICIdial svn r4031, www/vicidial/admin.php, lines 52913-52916: the Admin Utilities link and who sees it
- VICIdial svn r4031, www/vicidial/admin.php, line 53982: Agent LAGGED Report, LAGGED Summary, Agent Latency Report and Latency Gaps
- VICIdial svn r4031, www/vicidial/admin.php, lines 52761-52912: the server table with each server's time, PHP Time and DB Time
- Trustane console: the agent check: seconds since the last report, LAGGED entries in 24 hours and 7 days
- Trustane console: the reasons and the advice the check gives a manager