Welcome to Geeklog, Anonymous Friday, November 29 2024 @ 11:53 pm EST

Geeklog Forums

Moving GL to anther server?


Status: offline

rv8

Forum User
Regular Poster
Registered: 10/10/02
Posts: 105
Location:Ottawa, Canada

I've been working on a GL 1.3.6 site set up locally, intending to use my machine as a web server. But, now that I've read the fine print on my contract with my ISP, I've decided I need to move it to another server.

I've decided to use http://phpwebhosting.com/. Now I need to figure out how to move my site over there.

I can easily use scp to copy everything except the mysql database. I've got an empty database at phpwebhosting, but it has a different name than the one I have on my local server. Can I import my data into this database, and then change the name in the config.php file? If so, I would really appreciate it if someone could talk me through how to do the export/import. It looks like I'll have to use phpMyadmin to do the import side. I've used GL's backup function to do a backup.

Is there an easier way to move my site?

Thanks,

Kevin


Kevin Horton
 Quote

Status: offline

Dirk

Site Admin
Admin
Registered: 01/12/02
Posts: 13073
Location:Stuttgart, Germany
Well, you're on the right track already :-) Whether you copy over the files from a previous install or start with a fresh one depends on the amount of changes you may have made to Geeklog. You should be able to import the database from the backup on your new host and then simply setup database name, password, etc. in config.php. If possible, you should do the import in MySQL directly (on the command line), since phpMyAdmin may run into timeout restrictions that some hosting services impose on PHP scripts. Another issue only applies if the URL (not the paths) change during the move: The "What's related" links in a story contain the URL of your old site. You may have to change those then (in phpMyAdmin or simply by opening the stories in Geeklog and saving them again without any changes). That should be all ... bye, Dirk
 Quote

Status: offline

rv8

Forum User
Regular Poster
Registered: 10/10/02
Posts: 105
Location:Ottawa, Canada
Thanks for the info Dirk. I ssh'd in to the new server, and was able to run mysql, so I can use it directly. But, I'm a complete novice with mysql - I haven't yet figured out how to import the backup file that GL makes. Can you give me a hint on how to import a database, or a pointer to a good reference? Thanks, Kevin
Kevin Horton
 Quote

Status: offline

rv8

Forum User
Regular Poster
Registered: 10/10/02
Posts: 105
Location:Ottawa, Canada

OK, I got the database populated. I found the mysql on-line docs useful. The mysqldump section said:

The most normal use of mysqldump is probably for making a backup of whole databases. See section 4.4.1 Database Backups.

mysqldump --opt database > backup-file.sql

You can read this back into MySQL with:

mysql database

I had to add a -p option to the mysql command to make it ask for my password.

Now I just need to work through some path issues and I'll be cooking. I'll beg for help tomorrow if I can't beat these paths into submission.


Kevin Horton
 Quote

Status: offline

rv8

Forum User
Regular Poster
Registered: 10/10/02
Posts: 105
Location:Ottawa, Canada
Arrgh blasted GL preview code!! There is something mucked up in preview in html. When I first previewed this comment, I had problems with the < and > symbols in, and they mucked up the html when I did a preview. So, I changed them to &lt; and &gt;, and everything was fine in preview, so I pressed Submit. Well, something went bonzer. So, replace the code section in that example with: The most normal use of mysqldump is probably for making a backup of whole databases. See section 4.4.1 Database Backups. mysqldump --opt database > backup-file.sql You can read this back into MySQL with: mysql database < backup-file.sql
Kevin Horton
 Quote

All times are EST. The time is now 11:53 pm.

  • Normal Topic
  • Sticky Topic
  • Locked Topic
  • New Post
  • Sticky Topic W/ New Post
  • Locked Topic W/ New Post
  •  View Anonymous Posts
  •  Able to post
  •  Filtered HTML Allowed
  •  Censored Content