Go Back   HostGator Peer Support Forums > Public Forums > Pre-Sales Questions

Notices

Reply
 
Thread Tools
  #1  
Old 11-21-2007, 07:44 AM
debrag debrag is offline
Hatchling Croc
 
Join Date: Nov 2007
Posts: 19
Default transfering databases

I have exported my databases from my old host but how do I go about importing them to my new host?

I know in cpanel I create a database & in phpmyadmin I import the database there, but what about the parts of my sites that use the databases? do I need to go into each config file and amend the info as the databases will all have different names & users.

EDIT: I am currently transfering all files via ftp but will back-up my databases at work but will try at home tonight and use the restore fuction on cpanel.

Last edited by debrag; 11-21-2007 at 08:25 AM.
Reply With Quote
  #2  
Old 11-21-2007, 10:25 AM
Goddess Dix's Avatar
Goddess Dix Goddess Dix is offline
King Croc
 
Join Date: Aug 2006
Location: KS, USA
Posts: 1,498
Default Re: transfering databases

Quote:
Originally Posted by debrag View Post
I have exported my databases from my old host but how do I go about importing them to my new host?

I know in cpanel I create a database & in phpmyadmin I import the database there, but what about the parts of my sites that use the databases? do I need to go into each config file and amend the info as the databases will all have different names & users.

EDIT: I am currently transfering all files via ftp but will back-up my databases at work but will try at home tonight and use the restore fuction on cpanel.
yes, you will need to do a little more work. in the mysql area of cpanel, you'll need to create the database and username, and attach the user to the database there. then import your database in phpmyadmin. and tweak your config files.

when naming your database here, remember hg automataically adds your username to the beginning of the db and user names, so if your cpanel login is mylogin, you set up your database to be named db1, then your database will REALLY be named mylogin_db1, and the same with the user. if you set up "myuser" then it gets named mylogin_myuser. tweak your config file accordingly and transfer the files.
Reply With Quote
  #3  
Old 11-21-2007, 01:23 PM
gwyneth's Avatar
gwyneth gwyneth is offline
Supreme Croc
 
Join Date: Sep 2006
Location: up north
Posts: 6,843
Default Re: transfering databases

There's an easier way...within the first 30 days of signing up, HG will transfer it for you.
Reply With Quote
  #4  
Old 11-21-2007, 01:52 PM
debrag debrag is offline
Hatchling Croc
 
Join Date: Nov 2007
Posts: 19
Default Re: transfering databases

I know that but they were having problems with it or something so i've been ftp-ing all the files myself.
Reply With Quote
  #5  
Old 11-21-2007, 04:15 PM
GatorDaveC's Avatar
GatorDaveC GatorDaveC is offline
HostGator Staff
 
Join Date: Mar 2006
Location: Ontario, Canada
Posts: 929
Default Re: transfering databases

Quote:
Originally Posted by debrag View Post
I know that but they were having problems with it or something so i've been ftp-ing all the files myself.
Create all of the dbs & DB users, and I'll import your Database backups for you. Please provide me with a ticket number with which database goes where.
Reply With Quote
  #6  
Old 11-23-2007, 10:10 PM
gwyneth's Avatar
gwyneth gwyneth is offline
Supreme Croc
 
Join Date: Sep 2006
Location: up north
Posts: 6,843
Default Re: transfering databases

Quote:
Originally Posted by GatorDaveC View Post
Create all of the dbs & DB users, and I'll import your Database backups for you. Please provide me with a ticket number with which database goes where.
That, debrag, is a great offer!
Reply With Quote
Reply

Bookmarks

Thread Tools

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off

Forum Jump

All times are GMT -6. The time now is 10:43 PM.