coppermine-gallery.com/forum

Support => cpg1.4.x Support => Older/other versions => cpg1.4 miscellaneous => Topic started by: davelu on September 10, 2006, 09:07:13 PM

Title: Bridging MYSQL Databases
Post by: davelu on September 10, 2006, 09:07:13 PM
Hey,

The gallery that runs on my site is almost short on Mysql space, and i want to know whether it's possible to bridge two mysql databases togther so it would act as one. The limit that's set on 1and1 is 100mb, and i already used 70+% of the 100mb, so i'm a bit worried. The space is mostly occupied by comments, which there are about 3341 comments, and i have no intentions of closing the gallery's comment board. You can view the gallery here. (http://www.emmawatson.ca/CoppGallery)

I called up 1and1 and they said they couldn't do anything about it. >_<

Thanks!
-Dave
Title: Re: Bridging MYSQL Databases
Post by: davelu on September 11, 2006, 12:00:32 AM
awww no help  :o ;) c'mon
Title: Re: Bridging MYSQL Databases
Post by: Sami on September 11, 2006, 12:04:51 AM
What do you want to do?
Are you trying to use any other mysql server instead of 1and1 server if yes then you need to create a backup from your db and restore it under new server and also you should have remote access permission on new server ...
Title: Re: Bridging MYSQL Databases
Post by: davelu on September 11, 2006, 12:12:29 AM
What i want to do is to have two databases working as one. so i would have more space. Is that possible? \



EDIT: Is it possible to reroute the database that the comments are written in? Instead of writing in the main database where everything else is at, could i call it from another database?
Title: Re: Bridging MYSQL Databases
Post by: kegobeer on September 11, 2006, 03:27:29 AM
No, you can't have two databases working as one.  Ask your host to increase your database storage, or get another database host.
Title: Re: Bridging MYSQL Databases
Post by: Joachim Müller on September 11, 2006, 06:42:03 AM
Quote from: davelu on September 11, 2006, 12:00:32 AM
awww no help  :o ;) c'mon
This is not a hotline!
http://coppermine-gallery.net/demo/cpg14x/docs/faq.htm#lamesupport
Title: Re: Bridging MYSQL Databases
Post by: Nibbler on September 11, 2006, 08:26:05 AM
You should be able to do that if both dbs are on the same server and accessible by the same mysql user. Modify include/init.inc.php to redefine the comments table and give the existing coppermine db user rights to the new db.

$CONFIG['TABLE_COMMENTS']   = $CONFIG['TABLE_PREFIX'].'comments';

becomes

$CONFIG['TABLE_COMMENTS']   = "`new_db_name`." . $CONFIG['TABLE_PREFIX'].'comments';