Skip to main content

Unable to import database from ssh command line

Comments

2 comments

  • mtindor
    Run command mysql -u theUser_theDBu -p theUser_mynewdatabase < mydumpfile.sql What Did I missed? What I did wrong? Thanks

    Are you positive that mydumpfile.sql has content in it. If you ran the command that you say you ran, and you received no errors, and you were sent back to the prompt afterwards, that's an indication to me that the database import did work. Now, if you go and look at theUser_mynewdatabase and find that it is empty, that suggests to me that the import SQL file that you used contained no data. Otherwise, if there were any errors during the process, you would have received some sort of message from MySQL stating what the issue is/was. Mike
    0
  • cPanelMichael
    Hello, The previous post is correct. Check to verify the SQL file you are importing includes the required data. You can directly view the file with the "cat" command to check (but don't post the output here as it will contain sensitive data):
    cat /path/to/file.sql
    Thank you.
    0

Please sign in to leave a comment.