1. No Profile Picture
    Junior Member
    Devshed Newbie (0 - 499 posts)

    Join Date
    Mar 2000
    Rep Power
    When I move my site which uses a MySQL database, how would I move the whole database from the old MySQL server to the new one?
  2. #2
  3. No Profile Picture
    Registered User
    Devshed Newbie (0 - 499 posts)

    Join Date
    Dec 1999
    Badhoevedorp, the Netherlands
    Rep Power
    You could use mysqldump to export the current db to textfile format, and import the output from mysqldump on your new server using the following:
    mysqldump -p mydb --add-drop-table > mydb.sql (on your current server)
    then upload the file mydb.sql to your new server (you could use gzip to compress it)
    mysql -p mydb < mydb.sql (on your new server)

Similar Threads

  1. Cannot Use database located on a web server in VB
    By labamba in forum Visual Basic Programming
    Replies: 9
    Last Post: July 5th, 2004, 06:19 PM
  2. Replies: 5
    Last Post: July 2nd, 2003, 07:54 AM
  3. Replies: 2
    Last Post: November 5th, 2001, 02:40 PM
  4. Moving a database to a different server
    By ashalson in forum MySQL Help
    Replies: 5
    Last Post: July 15th, 2001, 11:31 AM
  5. Replies: 3
    Last Post: July 3rd, 2001, 11:24 AM

IMN logo majestic logo threadwatch logo seochat tools logo