Migrating Coppermine Gallery to another server Migrating Coppermine Gallery to another server
 

News:

CPG Release 1.6.26
Correct PHP8.2 issues with user and language managers.
Additional fixes for PHP 8.2
Correct PHP8 error with SMF 2.0 bridge.
Correct IPTC supplimental category parsing.
Download and info HERE

Main Menu

Migrating Coppermine Gallery to another server

Started by pols1337, April 14, 2013, 02:07:10 AM

Previous topic - Next topic

0 Members and 1 Guest are viewing this topic.

pols1337

Hi,

I need help with moving my Coppermine installation from one host (a shared hosting environment, no Cpanel) to another host (virtual private server, with cPanel).  I can FTP the files over, so all of the pictures and images are the same.  But what do I do about the MySQL databases?  When I export / import from phpMyAdmin, it works ... except when I try to access my gallery, I get the following error:

Coppermine critical error:
Unable to connect to database !

MySQL said: Unknown MySQL server host 'mysql.gip.superb.net' (1)


Where mysql.gip.superb.net is the OLD location for the MySQL server.  I probably need to change it to localhost.  How do I do that on my existing Coppermine database?

pols1337

Actually I just realized I can probably change the [mysql.gip.superb.net] on the new host, no need to change on the old host and then export.  I just don't know where to look in the database. 

Please advise. 

phill104

The file /include/config.inc.php contains all your database details and you can adjust the pointer to your db in there.
It is a mistake to think you can solve any major problems just with potatoes.

ΑndrĂ©

pols1337, it's all described in the docs:
Quote from: http://documentation.coppermine-gallery.net/en/export.htm#moving_serverEdit the database settings
Your new webhost must have provided you with the mySQL access data (you already had to use that data to restore the dump on the new server). That mySQL data usually will differ from the mySQL data on the old webserver, so you will have to edit the file that contains those data. Use a plain text editor (notepad.exe is fine) and edit include/config.inc.php: inside that file, you will find the old mySQL data that you will need to overwrite with the mySQL data for the new server.