SitePoint Sponsor

User Tag List

Results 1 to 2 of 2
  1. #1
    SitePoint Guru
    Join Date
    Mar 2004
    Posts
    639
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    How to convert MySQL datafile to .SQL file?

    Hello,

    My Windows 2008 server crashed and now I need to transfer website to Ubuntu hosting. The problem is I do not have good MySQL backup.

    I've made a search and found \MySQL Datafiles\ibdata1 file. I wonder how can I convert it to .sql file, so I could import it into the new database? Is it possible?

  2. #2
    Follow Me On Twitter: @djg gold trophysilver trophybronze trophy Dan Grossman's Avatar
    Join Date
    Aug 2000
    Location
    Philadephia, PA
    Posts
    20,578
    Mentioned
    1 Post(s)
    Tagged
    0 Thread(s)
    If you set up your my.cnf/my.ini configuration identically, you can just copy the entire MySQL data directory ("MySQL Datafiles") to the new server.

    To "convert it to .sql" you need the data in a running MySQL server. You'd then run the mysqldump tool to query the live server and write the data to a .sql file.


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
  •