skip to Main Content

I have a .sql file (db) which I am trying to import using myphpadmin and keep getting a time out error.
The file is 46.6 MB (zipped)

Please note I am not on XAMPP but using a Godaddy myphpAdmin platform to manage the database.

What I’ve tried:

  1. Re-downloaded the file as a zip file – and tried importing it. Still failed.

  2. For this option given in phpmyadmin import, I tried UNSELECTING this option > "Allow the interruption of an import in case the script detects it is close to the PHP timeout limit. (This might be a good way to import large files, however it can break transactions.)"….and I also tried importing the db keeping it selected, but this failed. Which should it be?

What else can I do?

2

Answers


  1. Chosen as BEST ANSWER

    nothing worked, except SSH.

    What you need: Database (that you are importing into) username and password Cpanel username and password + IP address (for Putty)

    1. I had to upload the .sql file to a folder on the public_html.

    2. Download pUtty

    3. In putty I needed the IP address (hosting server) as well as the cpanel username and password (so have that handy).

    4. Once in, you have to enter your cpanel's password

    5. Use the "cd" change directory command to change directory to where you have placed your .sql file.

    6. Once there, use the following command:

      mysql -p -u user_name database_name < file.sql*

    (Note: replace 'user_name', 'database_name', and 'file.sql' with the actual name.)**

    You will be prompted for your database password, and then your database will be imported.

    Useful link: https://www.siteground.co.uk/kb/exportimport-mysql-database-via-ssh/


  2. You can try unzipping the file locally and importing the uncompressed .sql file; the overhead of uncompressing the file in memory could be the problem for phpMyAdmin. Generally, though, what Shadow said is correct and you should use some other means for import (like the command-line client). You could also use the phpMyAdmin UploadDir feature to put the file on the file in a special folder that phpMyAdmin can directly access on the server. This can help with a lot of the resource limits the webserver imposes.

    Login or Signup to reply.
Please signup or login to give your own answer.
Back To Top
Search