Page 1 of 1

vicialnow how to separate the database MYSQL

PostPosted: Wed Apr 07, 2010 1:48 pm
by cyberchoy123
Hi moderators,

I'm quiet a newbie and wanted to separate my VICIDIALNOW database to a separate or a dedicated database. Can you provide me on what are the things i should do. I have already installed a new VICIDIALNOW and all i need to do is to change the database in astguiclient.conf which is done, but i get Time Sync Error.

PostPosted: Wed Apr 07, 2010 5:56 pm
by williamconley
you should have all your servers (mysql and otherwise) using the same NTP source. preferably a server in your office (which may or may not then sync to an external national source).

the database needs to be transferred and permissions need to be in place so that you can access it from your existing installation.

the simplest method to test it is to "simulate" what the server will do. from your linux command line, enter
Code: Select all
mysql asterisk --host=xxx.xxx.xxx.xxx --user=cron -p
you will hopefully be prompted for your cron password (which i hope you have and i further hope is not still 1234 except for "testing" purposes :))

In case it's necessary: replace xxx.xxx.xxx.xxx with the ip address of your new mysql server.

if this does not work, you will need to create a cron user and give it permission to log in and perform its necessary functions from the IP address of the Vicidial server. The specific command set for this is contained in the Scratch Install instructions distributed with all Vicidial source.

PostPosted: Thu Apr 08, 2010 11:58 am
by cyberchoy123
i have already tested and run the command in my other server

mysql asterisk --host=xxx.xxx.xxx.xxx --user=cron -p

and it works i can update delete and add rows to it.

Here is the setup 10.10.20.20 - WEB/ASTERISK 10.10.20.51 - MYSQL.

both are on the same timezone but still i get time sync error.

PostPosted: Fri Apr 09, 2010 3:36 am
by gardo
It's recommended to also have your workstations synchronize to the same time server.

PostPosted: Fri Apr 09, 2010 1:18 pm
by cyberchoy123
its now fix. just needs to have sync with the other server. Thanks moderators.

PostPosted: Fri Apr 09, 2010 1:51 pm
by williamconley
to be clear on your solution: was it that the MySQL server needed to sync to the Asterisk/Apache server or was it the agents workstations syncing to the Asterisk/Apache server that resolved your problem? (there will be others reading this post for about a year ... good information to post)

solution

PostPosted: Tue Apr 13, 2010 9:33 am
by cyberchoy123
Fixing Time Sync Error in a Separate Database Server

1.stop NTP server

root@vici:# service ntpd stop

2. edit ntp.conf

root@dialer1:# vi /etc/ntp.conf

3. Make sure that the following are in the file ntp.conf:

server 0.north-america.pool.ntp.org
server 1.north-america.pool.ntp.org
server 2.north-america.pool.ntp.org
server pool.ntp.org
server 127.127.1.0


4. sync the time with the NTP server

root@vici:# ntpdate pool.ntp.org

5. restart the NTP Server

root@vici:# service ntpd start


Do this for both servers. Asterisk & Database

PostPosted: Tue Apr 13, 2010 11:15 am
by williamconley
williamconley wrote:to be clear on your solution: was it that the MySQL server needed to sync to the Asterisk/Apache server or was it the agents workstations syncing to the Asterisk/Apache server that resolved your problem?
I hate assuming, but i'm assuming that means the syncing the SERVERS solved your issue.

i also had a client this week whose vicibox redux opensuse clustered server was overloaded (assumption here again) and the ntp service failed.

it synced up to a point and just "stopped" early in the morning under heavy load. it took a while to get out of sync (/var/log/ntp) but eventually it did and the auto-dial function simply stopped working.

since the server was in use and could not be rebooted, a manual time setting (to within 1 second of the mysql server) brought the auto-dial function back online immediately.