Gossamer Forum
Home : Products : Gossamer Forum : Discussion :

moving to a new server

Quote Reply
moving to a new server
Sorry to bother you but I cannot find the required information amoung all those posts. I need to move an existing V1.2.0 from server A to server B (changed ISP). My questions are as follows:

1) I am able to SQL Dump with mysqlman. But I am not able to import that dump when clicking on a table an "import" within mysqlman on the new server after a clean v1.2.0 installation. How to move my sql data ?

2) The new server uses a temp. URL before the old URL will be transfered which will be entered at installation process time. Any problems with that ? Later I just plan to change pathes inside the admin section.

3) How to move my old config ? Most files have checksums now and I seem to be unable to just copy my config/data.pm onto the new server. Is the path info also stored inside that file ? How to transfer all markup tags without the hassle to generate them again ?

Could someone please give me some hints as I cannot seem to get it to do what I need to.. Crazy
Quote Reply
Re: [blackjack] moving to a new server In reply to
I just moved to a new server and one of the things that worked without a hitch were all of my GT installations. I have root access so that helps, not sure if you can do this without.

Basically I rsync-ed everything from my old server to the new server. The main bits to worry about to keep GT products happy was to rsync the home directories (ie /home/mydir or where ever you keep your cgi scripts and web content) and the mysql databases (usually in /var/lib/mysql).

By moving the mysql databases directly I didn't have to worry about importing/exporting, etc. You might do this with a terminal command like the following on the new server:

Code:
rsync -avz -e ssh root@oldserver.com:/var/lib/mysql/ /var/lib/mysql

The '-avz' tells rsync to preserve just about all file attributes in during the copy (ie permissions, owner, group, timestamp). The '-e ssh' tells rsync to use a secure shell so the tranfer is encrypted. The 'root@oldserver.com:/var/lib/mysql/' tells rsync to log in to olderserver.com as root (you will be prompted for a password after entering the rsync command) and that is should copy everything in the /var/lib/mysql/ directory. The ending / is important. The last bit, '/var/lib/mysql', tells rsync where to put the copied material on the local server. The lack of a closing / is important. You can get complete documentation with 'man rsync'.

Hope that helps. Not sure if there is an easy answer if you don't have root access. You probably can't use this method to copy the mysql databases, buy you can probably still use it to copy your home directory as you should be the owner.

cheers,
Michael Coyne
seaturtle.org
Quote Reply
Re: [mcoyne] moving to a new server In reply to
Thank you for your detailed help. Cool

Unfortunately I do neither have shell access, nor do I have root access Crazy. So I am forced to export the sql database somehow and more important to import it into the news servers sql database.

Any ideas ?
Quote Reply
Re: [blackjack] moving to a new server In reply to
If they are both unix servers, you could try using the mysqldump command through Tools -> Fileman -> Command. To do so, enter this in the Fileman command field:

Code:
mysqldump --opt -uusername -ppassword gforum >gforum.dump.mysql; echo "Done"

Replace the red parts with the appropriate information (the last one is the database name). That will create a gforum.dump.mysql file. Download this file, and upload it to the new server. On the new server, go into Fileman -> Command again, and run:

Code:
mysql -uusername -ppassword gforum <gforum.dump.mysql; echo "Done"

However, before you do this, you want to make sure that the old installation has been upgraded to 1.2.0 so that the 1.2.0 database changes are present.

You will probably also want to copy over the gforum/admin/attachments directory, as it contains all the actual attachments that have been made to posts and messages.

Jason Rhinelander
Gossamer Threads
jason@gossamer-threads.com
Quote Reply
Re: [Jagerman] moving to a new server In reply to
Great solution, thanks. Meanwhile I was able to import the sql database via mysqlphp (or how was its name ?).. it worked out even if I had to split the whole thing into bits as the app was unable to import larger files.. but now I am done, thanks for your help ! Cool
Quote Reply
Re: [Jagerman] moving to a new server In reply to
I just moved my forum v1.8 to a new server and was able to upload a mysql dump from my old installation. Everything appears to be there in checking the forum contents and user lists. However, I cannot log in. When I try I get this message:

Can't call method "fetchrow_arrayref" on an undefined value at GForum::Authenticate::auth_create_session line 513.

Any help in resolving this error would be appreciated.

Regards
Don McRitchie

Webmaster
Lansing Heritage Website

Last edited by:

warc1: Jul 10, 2003, 1:50 AM
Quote Reply
Re: [warc1] moving to a new server In reply to
Some information that might be of use to any other novices, like myself, that want to move their forum to a new server. I discovered the following by trial and error. Therefore, I may not have stubled across the easiest way of doing a transfer and more experienced users can jump in to correct me. In fact, the following may have caused the error I am now experiencing. However, this is what got me to the point that at least my database is installed on the new server.

To use a mysql dump to move the contents of the database, I had to first set up the Gossamer installation on the new server including setting up the new database. In my case, I called the new database "forumd". This created a blank database with the table structure in place. A straight import using the command line listed in a previous post would not work since it errored out in trying to create tables that already exist. Therefore, the tables had to be cleared in the new database. I found I could do this using MySQLman in Gossamer Forum by clicking "drop" beside each table in the database until it was empty.

I used FTP to upload the text file dump (I called it mysqldmp.txt) of my old database to the new server. I uploaded it to the root directory of my web taking note of the path name displayed in my FTP client. In my case, the path name was /home/lansingheritage/www. I then used the freeware program PuTTY to intiate an SSH connection to import the data from the text file. I did this instead of using a command line in MySQLman because I couldn't find one in v1.9 that is included with Gossamer V1.8. After logging into the server, the command line to import the MySQL dump became:

mysql -uusername -ppassword forumd </home/lansingheritage/www/mysqldump.txt; echo "Done"

This worked with the exception of the error reported above that I hope can be addressed shortly.

Regards

Don McRitchie
Webmaster
Lansing Heritage Website

Last edited by:

warc1: Jul 10, 2003, 9:18 AM
Quote Reply
Re: [warc1] moving to a new server In reply to
In case its of use to anyone else, I fixed the problem described above. Dropping the tables from the initial setup so I could import the MySQL dump without errors resulted in three tables missing from the final installation. I went into Admin and selected Setup and then SQL Server. I made sure the radio button beside "Create new default Gossamer Forum tables in this database but do not overwrite any existing data" was selected and then clicked "Submit Changes". Everything works now.

Regards

Don McRitchie
Webmaster
Lansing Heritage Website