SEO Software
Closed Thread
Results 1 to 4 of 4

Thread: Transfering mysql database to another server without backup

  1. #1

    Default Transfering mysql database to another server without backup

    I want to Transfe mysql database to another server without backup is it possible using some script? Or I have to do it manually?


  2. SEO Software

  3. #2

    Default

    Its not possible without backup.You have to take backup at your end only.And also you have to do manually only

  4. #3

    Default

    While you're right as far as I know, anything that is done manually that does not require user input can be automated through the use of the cron command:

    server #1 - [where the backup is being taken]

    mysqldump --add-drop-table -h mysqlservername -u dbocodex -p yourpassword > filename.sql

    [ insert your rsync, ftp, or scp commands here ]

    server #2 - [where the backup is being restored]

    mysql -h secondmysqlservername -u mysqlusername
    -p databasename < filename.sql

  5. #4

    Default

    To move a mysql db you will need a backup. So you either need command line access or a very easy tool to use is phpMyAdmin, which most hosts offer through cPanel.

    But to move a db you do need a dump file as jcy1978 gave you instructions on how to get from the command line.

    From phpMyAdmin select the database
    Click the Export tab
    Make sure the Data box is check and Complete inserts
    Check the box Save as file
    Then click go

    This will download the __DB__.sql file which you will use to import into the new db on the other server.

    Mark

Closed Thread

Similar Threads

  1. backup server?
    By ankur0412 in forum Dedicated Servers
    Replies: 1
    Last Post: 11-15-2009, 04:42 AM
  2. PHP and mysql backup
    By valendino in forum PHP Help
    Replies: 0
    Last Post: 08-25-2009, 09:36 AM
  3. One local server MySQL
    By antonemarian in forum Databases
    Replies: 4
    Last Post: 08-13-2009, 05:14 AM
  4. Webhosting with Sql server database
    By nikon in forum Web Hosting Forums
    Replies: 1
    Last Post: 03-25-2009, 11:37 PM
  5. Backup Mysql database
    By techkid in forum PHP Help
    Replies: 1
    Last Post: 01-03-2009, 09:06 AM

Tags for this Thread

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts