So I need to import a sqldump.sql or better said update the existing one. I went the route suggested here
because I get a fatal error in Adminer (the db is just 140mb in size…)
Fatal error : Allowed memory size of 268435456 bytes exhausted (tried to allocate 150604992 bytes) inC:\Program Files (x86)\LocalWp\resources\extraResources\adminer\adminer.php on line98
So I did the following:
Copy the sql file to the site root. That location should be something like: ~/Local Sites/sitename/app/public/
Right-click on the site in Local and select “Open site shell”
Within the terminal that opens, import the sql file using this command:
wp db import name-of-sql-file.sql
And I’m getting this what ever I do:
Error: Failed to get current SQL modes. Reason: ERROR 2003 (HY000): Can’t connect to MySQL server on ‘localhost’ (10061)
That documentation contains the same process that the original poster and I both used which produced the error.
I am just trying to import the database into the site where I have cloned my code base repository. I don’t need to import wp-content, just the database. Please help.
This doesn’t really help. We’re following the exact steps you folks recommend in your documentation and it’s not working. Can your team help us understand how we can get past this error? We can’t be the only folks that have faced this error.
I understand @tnaughton , however, the error is fairly generic so it’s tough to pinpoint. It could be related to something specific in your machine/OS and not necessarily a setting within the Local app. As noted in the link I shared there could be a handful or several different reasons for it.
In order for us to take a deeper look could you share your Local Log? For us to be able to troubleshoot thoroughly, please click the Download Local Logs button from the Support tab in Local. This will generate a zip archive that contains the Local log along with some other diagnostic information to help quickly zero in on any issues that Local is encountering.
I’m getting this error on a blank WordPress install.
What issue or error are you experiencing?
Fatal error: Allowed memory size of 268435456 bytes exhausted (tried to allocate 130023456 bytes) in C:\Users..\AppData\Local\Programs\Local\resources\extraResources\adminer\adminer.php on line 98
What steps can be taken to replicate the issue? Feel free to include screenshots, videos, etc
Importing 26.7 MB sql.gz database created by WP Migrate Lite
System Details
Local Version:
Version 8.1.0+6514
Operating System (OS) and OS version:
Windows 11 Pro
Security Reminder
Local does a pretty good job of scrubbing private info from the logs and the errors it produces, however there’s always the possibility that something private can come through. Because these are public forums, always review the screenshots you are sharing to make sure there isn’t private info like passwords being displayed.
If the Local Site Shell was able to correctly identify the Local Database port on Windows computers, this particular problem would be eliminated for Windows users.
Hi @buzztone - You are correct. I checked and we do have a bug filed going back to this comment from Ben that I shared earlier. I’ll send a note to the dev team that you and others have been coming across this again.
@Nick-B sorry for showing my frustration. I appreciate your team getting back to us. I followed the steps from buzztone and was able to load one one my sites. Thanks again.
Glad to hear it @tnaughton! Thank you for the follow up here. @Mike8040 let us know if you still have any issues or if that workaround fixes things up on your end as well.