Forums | Mahara Community
Open Discussion
/
Change database to the new server
25 June 2015, 14:10
Hi all,
I have problem when change database to the new server. After I connect database to new server, I can login the mahara system but I click any menu in system, it is automatically log out. Can any help me in this matter?What steps I should be follow how to change the database mahara?
- anwar
25 June 2015, 15:18
Hi Anwar,
Which version of Mahara are you running?
Has the URL changed?
If so, you'll need to update $cfg->wwwroot in your config.php file. You may also need to update your config table in the database. Search where value = 'your old url' and update accordingly.
Have you created the site data directory - i.e. $cfg->dataroot -> this directory actually exists on your new server?
Also, are you using SSL? It may be an issue with your apache config settings.
If you can provide any more details, it will help us to narrow it down.
Thanks,
Ghada
25 June 2015, 16:31
Thank you for reply Ghada.
I using 1.10.2 version of mahara.
The URL is no change and site data directory still the same path. I just want to put my database to the new server. (before this, the database was in the localhost)
I have dump mysql database and restore to the server. I have updated the database connection details in my config.php file to the new dbhost.
$cfg->dbtype = 'mysql5';
$cfg->dbhost = '<new ip address>';
$cfg->dbport = null;
$cfg->dbname = '<same db name>';
$cfg->dbuser = '<same db name user>';
$cfg->dbpass = '<same db name passwd>';
I'm also not using SSL.
-anwar
25 June 2015, 18:19
Hi Anwar,
Thanks for the information.
Have you checked the log files? Are you getting any errors in them?
Thanks,
Ghada
25 June 2015, 22:13
Hello Anwar,
This won't solve your problem, but please install Mahara 1.10.4. That's the latest security release in the 1.10 series: https://launchpad.net/mahara/1.10/1.10.4 Alternatively, if you want to have the very latest code, please use Mahara 15.04.1: https://launchpad.net/mahara/15.04/15.04.1
You should always install the latest release within a Mahara version to stay on top of security updates and high important bug fixes. :-)
Cheers
Kristina