Monday, February 5, 2018

List Custom Fields: Not Authorized to View This Section

A client requested additional fields to be added. He wanted to have 4 additional fields added for First and Last name of 2 additional contact persons.

However, upon clicking "List Custom Fields", it showed "You are not authorized to view this section".

*There's not much information available on the List Custom Fields topic so I'm not sure if this section will fulfill the requirements of our client.

Upon googling "admin_lists_custom.php not authorized", I found this on Github.
if ( ($LOGcustom_fields_modify < 1) or ($LOGuser_level < 8) )
{
echo "You are not authorized to view this section\n";
exit;
}
Knowing this, I made sure of that:

  • My User Level is above "8" - User 6666 is 9 by default.
  • My Custom Fields Modify (in Admin Interface Options) is set to "1" - User 6666 is set to 0 for this by default.


With these changes, I was able to access the List Custom Fields section.



Now, I have a different problem (localhost connection) with submission of my entries but this post will be for another day.

Notes: Not all versions of Vicidial have the List Custom Fields option. It may be better to consider re-purposing existing fields.

Tuesday, August 15, 2017

Install Backup Vicidial on Digital Ocean

As a back up, I've installed an instance of Vicidial in the cloud through Digital Ocean. I haven't used it yet full time, as I still have my on-premise servers working. It just helps me sleep at night knowing that I have a back up for emergencies. I've tested only a few calls on this and it seems to work fine. I haven't used it full-blown yet so I don't know how well it performs with 5 concurrent users.

Droplet Requirements:

  • Minimum Memory: 1 GB or higher
  • Disk Space: 30 GB or higher
  • OS: CentOS 6.8 x64
For the location of the server, I chose somewhere in North America, because my vendor's VOIP servers are located in United States. I figured that would help with lessening data travel time which prevents choppy calls and delayed voices. (Comment below if you think this logic is wrong.)

Afterwards I just followed the installation instructions on Ray Solomon's website. For me, it was easier to follow than the striker24x7 version. At first try, it took me the whole day, but on the second try I was able to finish in half a day. It's not entirely updated, like some of the installers of the components have a newer version, so just make sure to check the links if there are newer versions and change the download addresses accordingly.

If you find it useful and if you are happy with the outcome, check out Ray Solomon's Amazon wishlist at the bottom of his webpage. I hope he's enjoying the Bayou Seasoning Injector I sent.

P.S. When you're done installing, don't forget to set your iptables properly to block off the hackers!

Update June 2022: The Ray Solomon Website is gone but wayback machine has a copy of it, thankfully! I hope this helps you!

Tuesday, June 13, 2017

Schedule Daily Job on Deletion of Old Recordings

I previously wrote an entry on freeing up space in Vicidial by deleting old recordings and log files (see here). Previously, I didn't have to do this frequently. Now, I have to perform this every 2-3 days thanks to the high volume of calls.

With that, I learned that scheduling this job daily saves me a lot of time from having to do this manually by editing the cron file.

Type in SSH: 
crontab -e

Add to the bottom then save
### remove WAV files and remove log file daily at after office hours
30 18 * * * rm -f /var/spool/asterisk/monitorDONE/ORIG/*.wav
30 18 * * * rm -f /var/log/httpd/*
35 18 * * * sudo reboot

For this job I've scheduled, it's set to delete old WAV files and logs at 6:30pm then reboot at 6:35pm every day. For more info on the how to add jobs in cron, check here.



Change Logo in Vicidial to Own Company Logo

If you'd like to customize or personalize Vicidial for your company, you can change the Vicidial Logo into your Company Logo. If you have multiple Vicidial Servers in your company and would like to help the agents differentiate them, changing the logo is also one way of helping them distinguish if they're in the right place.

For the first step, I looked for the location of the 2 logo image files and saved it. See below for the images. For mine, one image file is for the front page/login/agent screen, while the other one is for the administration pages. Different versions have different locations and image types!

Logos in Front Page, Log In, Agent Screen
Linux Location: /var/www/html/agc/images/vdc_tab_vicidial.gif

Logos in Administration
Linux Location: /var/www/html/vicidial/vicidial_admin_web_logo.gif

For the second step, I made my logo files fit the dimension of 220 pixels to around 60 pixels and saved it both as vdc_tab_vicidial.gif and vicidial_admin_web_logo.gif -- it must be the same name, so you won't have to tweak the PHP Files. For other versions, the original image file is in .PNG, so you have to save yours in .PNG. I just use regular ol' MS Paint.

For the third step, I used WinSCP to find the folders where the logos need to be (see step 1 in determining the address). I replaced the old logo files with the new ones. It was a lot easier for me to upload files using WinSCP rather than SSH. If you can do it through SSH (unlike me), you won't need WinSCP anymore.



Finally, once you've replaced the logos, use CTRL + SHIFT + R to reload the page with the new logo! For this example, I made a little rainbow colored "Hello World".



Thursday, April 6, 2017

Call Forwarding Inbound DID

With the holidays coming up, I needed to forward calls from our Vicidial into an external number.

Under the Inbound DID Settings:
  • Set "DID Route" to EXTEN
  • Set "Extension" to dialplan prefix + countrycode + area code + number

Unfortunately, I tested it and found that there is a significant delay with the sounds. On top of that, there is a long silence. I need to find out why there is a long silence and if I can replace that with ringing so the caller doesn't feel like he/she got dropped.

To be continued...

Source:
http://www.vicidial.org/VICIDIALforum/viewtopic.php?f=4&t=25793

Friday, February 24, 2017

Deleting Recordings from a Specific Date in Vicidial

How does one delete recordings from a specific date? It's a good thing that vicidial recordings are named by date. In my case, the recordings we use are in MP3 format.

For example here, if I wanted to delete all MP3's from March 19, 2016, I just need to use the command below:
rm -f /var/spool/asterisk/monitorDONE/MP3/20160319*.mp3
It would be helpful in freeing up space if the original .WAV files are also deleted since they eat up a lot of space. This isn't a date-specific command since we only need the MP3's.
rm -f /var/spool/asterisk/monitorDONE/ORIG/*.wav 

To free up more space, check here:
http://simplevicidial.blogspot.com/2016/04/no-mysqlsock-because-root-partition-is.html 

*Another thing I learned: Sometimes, you just need to reboot to free up space.

Wednesday, February 15, 2017

8 Sockets Detached Only in Asterisk, Can't call Softphone

After my hard drive was full again from recordings, I deleted the extra recordings and then rebooted. After this, the users told me that their X-Lite (our softphone) wasn't being called into the conference anymore.

For those unfamiliar, every time the agent logs into the website of Vicidial, the softphone will ring and will join a conference. Vicidial will dial numbers and when it gets an answered call, it will connect this phone call to the conference.

Upon checking using the "screen -ls" command, there are only 8 sockets detached (vs the usual 9). I found that "astsend" was missing. I assume this is the socket that "sends" the calls to the softphones.

I found 2 suggestions on how to fix it:

1. Recompile Asterisk - I don't know how to do this exactly, but might be worth looking into for those who know how to do this.

2. Perform a Mysql Repair - Thankfully, this was the solution that worked for me! Turns out, when deleting unwanted recordings, it also damaged the mysql database.
mysqlcheck --auto-repair asterisk
sudo reboot
After performing the mysql repair and rebooting, Asterisk now calls my X-lite again.

Sunday, January 22, 2017

No More Leads in the Hopper for Campaign

Early this morning, I had to free up some space by deleting unneeded .WAV files. Later in the day, we found out that we couldn't make any outbound calls for all of the campaigns (but we could still receive inbound calls). The error was "No more leads in the hopper for campaign: <campaign name>". This was the same error message regardless of if it was Manual Dialing or Predictive Dialing.



I found the way to identify the issue through Support ALG's blog (see link below).
https://supportalg.blogspot.com/2015/06/how-to-fix-error-this-campaign-has-zero.html

It was the 2nd method that helped me identify the error:
/usr/share/astguiclient/AST_VDhopper.pl --debugX
Sorry, I was only able to get a partial screenshot

Because of this, I was able to identify that the /asterisk/vicidial_list table had crashed. After googling "table vicidial list is marked as crashed", I found this vicidial.org forum thread:
http://www.vicidial.org/VICIDIALforum/viewtopic.php?t=20206

Scrolling down below, I found this command (first when mysql has no password, second has password - you'll only need one of them):
mysqlcheck --auto-repair asterisk vicidial_list
mysqlcheck --auto-repair asterisk vicidial_list -p

Now after running the mysqlcheck, I logged out of and in to the campaign, and I can dial outbound calls again!

Tuesday, November 22, 2016

Long Silence at the Start of Inbound Calls

It's my first time setting up an inbound call and I ran into a problem where after the initial 2 rings, there's a long silence before the greeting plays. The longest was 17 seconds!

If I were the customer and there was no sound for 17 seconds, I'd hang up immediately. Customers hanging up mid-way isn't a good thing, of course.

Here are the steps I did to remedy the situation:
  1. Make sure the DID points to the IP address you need: It will take longer to route the calls to the right place if you have 2 or more servers. I had our DID provider remove the 4 other unnecessary IP addresses which shaved off 10 seconds.
  2. [Update: Don't do this! I ended up having a lot of outbound calls dropped because asterisk couldn't find this file] Remove sip-silence.gsm from the sequence: Observing asterisk logs, when an inbound call arrives, sip-silence.gsm is played twice before the first greeting. I'm too scared to tinker with the asterisk script (it's a really long text of code) and remove the 2 lines of sip-silence. Instead, I just renamed sip-silence.gsm into sip-silence2.gsm so it would skip playing that file. This shaved off another 3 seconds. Aside from removing sip-silence.gsm, I was thinking of replacing it with a ringing sound. However, I can't find the default ringing sound in the asterisk folder, so I chose to just remove sip-silence.gsm instead.
From 17 seconds of long silence, I was able to cut it down to 4 seconds of silence.

Tuesday, November 8, 2016

Converting Sound Files to WAV for Vicidial

I felt like I should post what settings I put in to convert sound files to .wav for Vicidial (For call menus and voicemail greeting). I did it the last time, but I forgot it today. Now, I'm taking down notes so I won't forget in the future.

Link to Online Converter:
http://audio.online-convert.com/convert-to-wav

Settings Needed:

  • Change Bit Resolution: 16 Bit
  • Change Sampling Rate: 8000 Hz
  • Change Audio Channels: Mono
  • PCM Format (Under advanced options): PCM Unsigned 8-bit
Anything else higher than this won't work.

Monday, August 22, 2016

Audio Store is Just A White Box

I encountered the "plain white box" error upon clicking any link in the administration which mentions "audio chooser". I also mysteriously found that by clicking this and having the white box issue, the disk space runs out quickly and I have to delete the logs.

By following the instructions here, I was able to fix the problem.
http://striker24x7.blogspot.com/2014/06/vicidial-goautodial-audio-store-white.html

Turns out, the directory that Vicidial was pointing to did not exist. I needed to create the folder and made sure the permissions were okay.

Now, upon clicking the Audio Chooser, this pops up!

P.S. Striker 24x7 - I <3 you!



Wednesday, July 27, 2016

There is a time synchronization problem with your system [Unsolved]

While calls were happening, the system stopped calling. The error message was "There is a time synchronization problem with your system, please tell your system administrator".

It could be a number of errors, but according to our provider, it was because our RAM wasn't working anymore. The server was 2 years old and was used every weekday since then.

When I replaced the RAM, it was working again for a while. But then the problem came back.

Until now, I still don't know why the error happens and I haven't been able to get back to it.

Tuesday, April 5, 2016

No MySQL.sock because Root Partition is 100% Full

Last week our Vicidial Server crashed and our agents couldn't make calls anymore. After restarting the server and trying to do the ol' rename-mysql.sock solution, I found that the mysql.sock file was missing. What gives??!

When I try to access the agent page in Vicidial, the error was: "MySQL connect ERROR: Can't connect to local MySQL server through socket '/var/lib/mysql/mysql.sock' (2)". Normally, I would follow the process of renaming or deleting the existing mysql.sock file then restart the mysql service. However, this time, there was no mysql.sock. (Impt: Please DO NOT delete the mysql! They are not the same as mysql.sock!)

After checking with the provider, turns out that the root partition is already full. Here are the steps that the provider gave to resolve the issue.

Steps and SSH commands:
  1. Find out how much space you have left.
    SSH Command: df -h
    In the Admin Page, go to "Reports" and scroll down and look for "Disk". It should provide the percentage of use.
  2. Delete unwanted files. In this case, you can delete the .WAV duplicates. It won't delete your .MP3 recordings.
    SSH Command:
    rm -f /var/spool/asterisk/monitorDONE/ORIG/*.wav
    rm -f /var/log/httpd/*
  3. Restart the server via SSH. Do not just push the power button or pull the plug.
    SSH Command: sudo reboot
And there you go! If that still doesn't work but you have the mysql.sock file already, follow the old process of renaming or deleting the existing mysql.sock file then restart the mysql service. 

Sunday, February 14, 2016

Using a Back-up Vicidial Server

As part of risk management of operations, there may be times when your main Vicidial Server conks out. Because I want to be proactive and not get caught with my pants down, I got a second Vicidial Server.

I want to share with you what I do.

First, I do a MySQL dump of the primary server then upload the MySQL back-up to the secondary server. For me, it's not mission-critical to have an exact duplicate, so I just do this weekly. For some, they may prefer to do this hourly or daily. 

Second, since my primary and secondary server do not have the same IP address, I do the IP-address-update command ("/usr/share/astguiclient/ADMIN_update_server_ip.pl") in Linux SSH. The mysql-migration will copy the primary server's IP address in the mysql database to the secondary server, so it's important to adjust it back to the correct IP address.

These 2 steps can be created as batch-jobs so you don't have to manually do this if you prefer.

There you have it! Hope this was helpful.

Tuesday, October 27, 2015

ERROR: sounds_list CENTRAL SOUND CONTROL IS NOT ACTIVE:

I'm setting up an inbound campaign and I wanted to use a recording we made for our voice mail. When selecting the audio-chooser, I encountered this message when I was selecting an audio-prompt for when there's nobody available to answer.
"ERROR: sounds_list CENTRAL SOUND CONTROL IS NOT ACTIVE:"

Steps to Fix:
  1. Go to Admin >> System Settings
  2. Change the following items:
    - "Central Sounds Control Active" and select "1" instead of "0".
    - "Allow Voicemail Greeting Chooser" and set to "1"
    - "Sounds Web Server" to whatever IP address you are currently using. Make sure it's not the default "127.0.0.1".
  3. Click on the Audio Store in the Admin System Settings in the left menu. The most striking message there should be "We STRONGLY recommend uploading only 16bit Mono 8k PCM WAV audio files(.wav) "
  4. Upload the audio file for the recording.
  5. Go to the voice mail entry and there will be an option for "Voicemail Greeting" with "audio chooser" at the right side. Click on "audio chooser" and select the .wav file you just uploaded.


Source:



Friday, October 2, 2015

MySQL Connect Error in Vicidial

Because my UPS failed, my Vicidial Server did not get to shutdown properly when the power flickered for a second. This caused the MySQL error and I can't get past anything after clicking "Agent" or "Administration".

Here's what I did in the Linux Command Line:
mv /var/lib/mysql/mysql.sock /var/lib/mysql/mysql.sock.bak
service mysqld start

After that, it was okay. Keep this piece of code close to you, if you expect power outages to happen... or if you're too lazy to use "sudo poweroff". See reason for this code at the source from stackoverflow.com

Update:



Source: http://stackoverflow.com/questions/20407292/centos-another-mysql-daemon-already-running-with-the-same-unix-socket

Changing the Static Internal Network IP Address of the Vicidial Server | Sorry, there are no available sessions

We did a revamp of the entire office network, so the old internal network IP addresses had to change. When the vendor installed our Vicidial Server, he preset it with the old one. 

Here's how I did the changes (2 important steps):

1. In Linux Shell Scripting Command Line, type the following:
sudo ifconfig eth0 <new IP address> netmask 255.255.255.0

Check afterwards if the IP address has been updated by typing:
ifconfig
Source:  http://www.howtogeek.com/118337/stupid-geek-tricks-change-your-ip-address-from-the-command-line-in-linux/


2. Next, still in Linux Shell Scripting Command Line, type the following to change the same IP address in the Vicidial Database:
/usr/share/astguiclient/ADMIN_update_server_ip.pl
After that, just follow the prompts. What I did was to keep pressing Enter and it knew what IP address was the old one and which one was the new one.

This second step is important, because it will re-point the Vicidial Database internal network IP addresses to the new one. If you forget to do this, you'll get the error "Sorry, there are no available sessions" when you log in as an agent.

Source: http://striker24x7.blogspot.com/2014/01/sorry-there-are-no-available-sessions.html

Introduction to this Blog

I am starting this blog because I'm sick of seeing solutions that I can't follow. I'm also sick of seeing so much jargon on the internet and following through forums!

I'm not technical expert. I'm not going to have everything in this blog. I don't even think I'm the right person to ask! However, I would like to contribute to the world so that normal folks like me won't have to go through hell in deciphering what people are talking about in forums.

Each entry will be entitled how I would search for solutions to a problem. Solutions will come with links to other people's blogs or forums that I found helpful in resolving the problem (need to give credit where it is due).

With this blog, I hope I can help the world make sense of Vicidial. Feel free to write comments and ask questions. No guarantee that I will be able to help, but hope for the best!

If this does help you, give me a shout out in the comments section! Just so I know someone's finding this helpful.