Page 1 of 1

Stand alone Mysql Database

PostPosted: Wed Jan 21, 2015 5:49 pm
by chasejordan1
I am trying to set up a stand alone mysql server that will only have Ubunutu 14.04 and Marian DB on it.

My current db server is a vicibox 6.0 server, marian DB.

My process is as follows... lock tables, dump DB on current server. Then create database on new server (asterisk) add all the permissions and upload database. At this point everything looks fine.

reboot

I then point my Web server and telphone servers to new server.

In the mysql tables all data and settings are fine, but, and this is the problem when I log into the web page the only thing missing is the lists, campaigns, users, phones etc are there, but the lists are empty. How can I trouble shoot this? Or did I do something wrong?

Re: Stand alone Mysql Database

PostPosted: Thu Jan 29, 2015 8:30 am
by DomeDan
Post the export/import process in more detail. (commands etc)
do you get any error messages when you do the import?

Re: Stand alone Mysql Database

PostPosted: Thu Jan 29, 2015 10:39 am
by chasejordan1
My process is as follows... lock tables, dump / export DB on current server. Then create database on new server (asterisk) add all the permissions and upload / import database.

reboot

Re: Stand alone Mysql Database

PostPosted: Thu Jan 29, 2015 7:47 pm
by mav2287
I have done this before and what we did was the following on the working server
Code: Select all
#mysqldump asterisk > /path_to_where_you_want_it/asterisk.sql

Then we put that file on a flash drive and mounted the drive in the new server. We then loaded that DB in by doing the following
Code: Select all
#mysql
mysql> create database asterisk;
Query OK, 1 row affected (0.02 sec)
mysql>exit
# mysql asterisk < /path_to_file/asterisk.sql


That is how I converted one of our single server setups to my first cluster. It should take everything with it from the old DB and be a perfect copy if you do it right.

Also for reference I always like this page for info on mysqldump as well. I use it as quick reference when I space on this stuff http://www.thegeekstuff.com/2008/09/bac ... mysqldump/ it has good information for mysqldump including a 1 liner for what you are trying to do. (I wouldn't do it this way though unless you are sure you know what you are doing)

[local-server]# mysqldump -u root -ptmppassword sugarcrm | mysql \
-u root -ptmppassword --host=remote-server -C sugarcrm1
[Note: There are two -- (hyphen) in front of host]