Adding Slave Database to existing cluster

All installation and configuration problems and questions

Moderators: gerski, enjay, williamconley, Op3r, Staydog, gardo, mflorell, MJCoate, mcargile, Kumba, Michael_N

Adding Slave Database to existing cluster

Postby samadsaeed » Sun Mar 03, 2019 2:01 pm

Hello, can we add a slave database to an existing vicidial cluster? setup is like 1 web and DB server and 4 dialers. i have done scratch installation on centos 6.9. its mysql database not mariadb. please let me know how its done thanks.
Vicidial Scratch Install
Centos 6.7 64bits
VERSION: 2.14-679a|BUILD: 180618-2300|asterisk 11.22.0-vici
4 Dialers|1DB & Webserver| 5 Server Cluster|
CPUinfo|Intel(R) Xeon(R) E3-1240v3 @ 3.4GHz|32GB RAM|600x2 SAS|
All Servers are of same configurations.
samadsaeed
 
Posts: 40
Joined: Wed Dec 06, 2017 2:09 pm
Location: GB

Re: Adding Slave Database to existing cluster

Postby williamconley » Wed Mar 06, 2019 3:55 pm

while you call it a "slave" database, and some of the documentation even refers to it as such in certain ways, what you are looking for is a "replication server" or a "replication slave". This is a mysql process that just allows a duplicate of a database to be "pulled" constantly to another mysql database server.

replicating a database server is a mysql process and once created (and properly replicated) there is a setting in admin->system settings to allow use of this server as the reporting server to remove reporting load from the primary (master) mysql server.

you must also ensure that the cron user from all servers has the same access to that database as the master so they can shunt automatically to the replication slave if the report in question is set to use the slave data source.

while it is not in any way necessary to install anything else "vicidial" on the replication server, the easiest way to accomplish replication is with the Vicibox.com iso installer, but failing that you would initially install it as any other server in the cluster and then activate the mysql service and follow standard replication procedures. you may want to have a look at the vicibox-install script and my.cnf settings that would ordinarily be used, but do note that these settings can be related to the version of mysql and OS being used. As an added benefit of using the Vicibox installer ... you'd have another server in the cluster.

Vicidial only works with Master/Slave, not Master/Master. When the DB server reboots, memory tables will be deleted, causing errors during replication. Errors to skip in my.cnf on the slave server:

slave-skip-errors = 1032,1690,1062

An important thing to remember: The Slave can be of a newer MySQL release than the Master. BUT the Master can NOT be a newer release than the slave. The master issues commands, a newer slave will understand them. But an older slave may not know them all, thus it would fail at that moment.

PS: Please include a link to the instruction set you use to build your servers. It helps bring those with the same set together to get any issues resolved.
Vicidial Installation and Repair, plus Hosting and Colocation
Newest Product: Vicidial Agent Only Beep - Beta
http://www.PoundTeam.com # 352-269-0000 # +44(203) 769-2294
williamconley
 
Posts: 20258
Joined: Wed Oct 31, 2007 4:17 pm
Location: Davenport, FL (By Disney!)


Return to Support

Who is online

Users browsing this forum: No registered users and 62 guests