The business process outsourcing (BPO) and call center sector across Pakistan—employing tens of thousands of agents in Lahore, Karachi, Rawalpindi, and Faisalabad—relies heavily on Vicidial, the premier open-source contact center suite. Vicidial handles predictive outbound dialing, inbound customer support queues, call recording, and real-time campaign reporting.
However, many BPO operators face voice degradation: audio clipping, Robotic Voice (jitter), dropped calls, and slow agent screen pops. These issues often stem not from international SIP carriers, but from deploying Vicidial on virtual private servers without real-time kernel timer synchronization, unoptimized Asterisk threading, or I/O bottlenecked MariaDB storage.
Deploying Vicidial on a performance-tuned Cloud VPS in Pakistan with hardware-clock pass-through and pure NVMe storage enables call centers to scale dozens of simultaneous agents per node with crystal-clear audio and zero dropped calls.
Understanding the Three Core Components of Vicidial
+---------------------------------------------------------------------------------+
| VoIP Telephony Grid |
| (SIP Carriers & Remote Agents) |
+---------------------------------------+-----------------------------------------+
| SIP UDP Port 5060 & RTP (10000-20000)
v
+---------------------------------------------------------------------------------+
| Asterisk PBX Core (Voice Engine) |
| - Channels, Codecs (G.711 / G.729), RTP Audio Streams |
| - Dahdi Dummy Timing Engine (1000Hz Invariant Clock) |
+---------------------------------------+-----------------------------------------+
| Real-time Call Event Logging
v
+---------------------------------------------------------------------------------+
| MariaDB Database Engine (RAM-Heavy) |
| - vicidial_list (Leads), vicidial_log, vicidial_live_agents |
| - In-Memory Query Buffers & High-IOPS NVMe Redo Logs |
+---------------------------------------+-----------------------------------------+
| Web Interface Calls
v
+---------------------------------------------------------------------------------+
| Apache & PHP FastCGI (Agent Portal) |
| - Real-Time Screen Pops, WebRTC Audio / Softphone Bridge |
+---------------------------------------------------------------------------------+
Vicidial relies on three tightly coupled subsystems:
- Asterisk Telephony Engine: Requires microsecond timer precision via the Dahdi kernel timing module (
dahdi_dummy). Without a stable 1000Hz hardware timer, conference bridges (MeetMe) suffer severe audio packet jitter. - MariaDB Database: Handles high-frequency updates every second as agents dial, pause, and log dispositions. A slow storage subsystem causes database locks and freezes agent dashboards.
- WebRTC / Web Gateway: Serves the agent interface and streams real-time audio directly to the browser via Opus or G.711 codecs.
Step-by-Step Installation: Vicidial on Linux VPS
Step 1: Install Kernel Headers and Dahdi Timing
Asterisk conferencing requires real-time kernel timing. On AlmaLinux or Rocky Linux:
dnf install -y kernel-devel kernel-headers dahdi-tools dahdi-linux
modprobe dahdi
modprobe dahdi_dummy
Verify that the timing source is active:
dahdi_test -v
Required Benchmark Output:
Opened pseudo dahdi interface, measuring accuracy...
99.998% 99.997% 99.999% 99.998%
Accuracy must remain above 99.98% to prevent audio distortion across concurrent SIP calls.
Step 2: Tune Asterisk SIP RTP Settings
Edit /etc/asterisk/rtp.conf to expand UDP port ranges and reduce jitter buffers:
[general]
rtpstart=10000
rtpend=20000
rtpchecksums=no
strictrtp=yes
probation=8
In /etc/asterisk/sip.conf, optimize transport and codec handling for Pakistani telecom routes:
[general]
context=trunkinbound
allowguest=no
bindport=5060
bindaddr=0.0.0.0
srvlookup=yes
disallow=all
allow=ulaw
allow=alaw
allow=g729
nat=force_rport,comedia
directmedia=no
qualify=yes
Step 3: Hardening MariaDB for Predictive Dialing
A predictive campaign dialing at a 3:1 ratio generates massive table churn. Edit /etc/my.cnf.d/server.cnf:
[mysqld]
# Allocate 50-70% of available RAM to InnoDB Buffer Pool
innodb_buffer_pool_size = 4G
innodb_log_file_size = 512M
innodb_flush_log_at_trx_commit = 2 # Flushes logs once per second, massively reducing NVMe write latency
innodb_flush_method = O_DIRECT
# Table and Connection Limits
max_connections = 500
table_open_cache = 4096
tmp_table_size = 128M
max_heap_table_size = 128M
# Query Cache Disabled (Deprecated and causes thread locking in high concurrency)
query_cache_type = 0
query_cache_size = 0
Restart MariaDB to apply the new memory parameters:
systemctl restart mariadb
Bandwidth & Hardware Sizing Guidelines for Call Centers
| Agent Capacity | Concurrent Calls (at 3:1 Ratio) | Recommended Hardware Tier | Bandwidth Requirement (G.711) |
|---|---|---|---|
| 10 to 15 Agents | ~45 Simultaneous Channels | 4 vCPU / 8 GB RAM (Cloud VPS) | 4 Mbps Symmetric |
| 25 to 40 Agents | ~120 Simultaneous Channels | 8 vCPU / 16 GB RAM (Cloud VPS) | 12 Mbps Symmetric |
| 50 to 100 Agents | ~300 Simultaneous Channels | Bare-Metal 16-Core Server | 30 Mbps Symmetric |
| 100+ Agents (Cluster) | 500+ Simultaneous Channels | Multi-Server Distributed Cluster | 50+ Mbps Dedicated Fiber |
When scaling past 50 active seats, split Vicidial into a dedicated telephony host (Asterisk) and a dedicated database/web host deployed on high-core Dedicated Servers in Pakistan.
Low-Latency Network Routing Across Pakistan
Because SIP voice packets travel over UDP, packet loss exceeding 1% or latency fluctuating above 150ms produces noticeable conversation lag. Hosting your Vicidial instance on local infrastructure interconnected with the Pakistan Internet Exchange (PKIX) ensures:
- Low Ping to Local Agent Softphones: Sub-10ms round-trip latency to residential agents working remotely across Lahore, Karachi, and Islamabad.
- Direct Subsea Transit to Global Carriers: Fast, direct IP routes via IMEWE, SMW4, and PEACE cables to European and North American SIP termination providers.
For related communications infrastructure, explore our guide on Self-Hosting RustDesk Remote Desktop Server on Cloud VPS. If your operations require enterprise bare-metal performance, explore our fleet of high-concurrency Dedicated Servers.
Power your BPO contact center with pure NVMe storage, unthrottled gigabit bandwidth, hardware timer synchronization, and 99.99% uptime tailored for high-concurrency VoIP operations.
