Hello,
I am trying to import database from Kinsta to local via DevKinsta, but it gives me DK0066 error:
[2024-05-29 10:55:29.432] [error] Error - DK0066: IMPORT_DB_DUMP: Error (1): (ERROR at line 1: Unknown command '\-'.
at *****\DevKinsta\resources\app.asar\main.prod.js:2:757027
at tryCatch (*****\DevKinsta\resources\app.asar\main.prod.js:8:1829201)
at Generator.<anonymous> (*****\DevKinsta\resources\app.asar\main.prod.js:8:1830850)
at Generator.next (*****\DevKinsta\resources\app.asar\main.prod.js:8:1829750)
at asyncGeneratorStep (**\DevKinsta\resources\app.asar\main.prod.js:8:1821046)
at _next (*****\DevKinsta\resources\app.asar\main.prod.js:8:1821345)
at processTicksAndRejections (node:internal/process/task_queues:95:5)
Could you please tell me how to resolve this issue?
I am sorry that you are having issues with your current import using DevKinsta.
Can you please provide us the following information? DevKinsta Version OS Version Docker Desktop Version
Also, have you tried closing Docker and DevKinsta then trying it again?
Can you please send your main.log file via DM so that I can get more information on what caused the issue better?
Hi @taras thank you for sending in the main.log and for the response.
I’ve investigated this further and I see that the error was generated due to line 1 of the backup.sql file that was imported to your site. See the screenshot below:
Can you please edit the backup.sql file and remove these characters \- of line 1?
Save it then try to reimport it to your local site via DevKinsta. Let me know how it goes.
We are also looking into this and will be doing some further testing to know if this is a potential bug or not. We will keep you posted.
My colleagues and I are having the same issue when trying to pull a site from Kinsta, via DevKinsta.
I have tried completely reinstalling DevKinsta and Docker, but I still get the same error, I have also attempted to pull known working sites down, but they are also failing when creating them as a new site.
Given that multiple users are experiencing this issue, it seems like this is a bug.
I’ve removed the 1st line in the backup.sql file. Then in DevKinsta, I did: Sync > Pull from Kinsta (Remote Origin / Live), but I still got the same issue.
Thank you @taras and @Joe for your replies! I was able to replicate this issue with a newly created site in MyKinsta as well. We have escalated this with our development team and we are investigating into this matter further. We will be providing another update as soon as we have more details to share.
We appreciate your patience while our team investigates into the root cause of this issue and develops a fix.
In the meantime if you do have any questions or have any further details you’d like to share please don’t hesitate to reply!
We’ve informed our development team about the issue you’re experiencing. While we currently don’t have an estimated time for when the issue will be fixed, we’ll notify you as soon as it’s resolved.
My colleagues and I experience the same issue (DK0066). Support told me to remove the - characters from the first line and after that reinstall DevKinsta but with no luck. Tested on multiple sites, none of them can be pulled to local DevKinsta.
I just looked into the backup.sql and saw there is one more line at the begining, compared to other sql files from devkinsta sites.
/*!999999- enable the sandbox mode */
So i was able to get my site running.
My setup needs my pw before importing the db. So i was able to jump in after the download, opened backup.sql., removed the first line, saved and then the import was good.
Hi @Wilkes_Booth ! Unfortunately this issue has proven to be more intractable than originally anticipated; we are still working on a fix for this, but we do not yet have an ETA on when that will be available.
Count me in — I’m also encountering the DK0066: IMPORT_DB_DUMP error when importing a database dump in DevKinsta. Here’s the error output:
[2024-07-01 14:35:58.562] [info] [containerExec] Command 'chown -R www-data:www-data /www/kinsta/public/webkeyz' on devkinsta_fpm finished with exit code 0
[2024-07-01 14:35:58.563] [info] [importBackupToDb] Import db
[2024-07-01 14:35:58.563] [info] [dockerUtil/getContainer] Get 'devkinsta_fpm' Docker container
[2024-07-01 14:35:58.902] [info] [containerExec] Command 'mysql -h devkinsta_db -u root -p****** webkeyz < "/www/kinsta/public/webkeyz/backup.sql"' on devkinsta_fpm finished with exit code 1
[2024-07-01 14:35:58.904] [error] Error - DK0066: IMPORT_DB_DUMP: Error (1): (ERROR at line 1: Unknown command '\-'.
at C:\Users\USER_NAME\AppData\Local\Programs\DevKinsta\resources\app.asar\main.prod.js:2:757027
at tryCatch (C:\Users\USER_NAME\AppData\Local\Programs\DevKinsta\resources\app.asar\main.prod.js:8:1829201)
at Generator.<anonymous> (C:\Users\USER_NAME\AppData\Local\Programs\DevKinsta\resources\app.asar\main.prod.js:8:1830850)
at Generator.next (C:\Users\USER_NAME\AppData\Local\Programs\DevKinsta\resources\app.asar\main.prod.js:8:1829750)
at asyncGeneratorStep (C:\Users\USER_NAME\AppData\Local\Programs\DevKinsta\resources\app.asar\main.prod.js:8:1821046)
at _next (C:\Users\USER_NAME\AppData\Local\Programs\DevKinsta\resources\app.asar\main.prod.js:8:1821345)
at processTicksAndRejections (node:internal/process/task_queues:95:5)
...................
[2024-07-01 14:35:58.968] [info] [ProgressIndicator] { isFailed: true, isOpen: true }" Failed to import
Upon inspecting the backup.sql file, I discovered it starts with /*!999999\- enable the sandbox mode */, containing an extra backslash that appears to be causing the SQL error. Removing the backslash manually to /*!999999 - enable the sandbox mode */ temporarily fixes the issue. However, each re-import attempt with DevKinsta results in the file being overwritten with the original erroneous format.
Can this extra backslash be the root cause of the import failure?
I am looking forward to a permanent solution from the DevKinsta team to prevent this issue from recurring. Thank you!"
I am sorry that you are also experiencing it, I’ve passed this along to our devs as well. As what my colleagues have mentioned, we are still waiting for a permanent fix.
Yes, that this line is the cause of the import issue.
/*!999999- enable the sandbox mode */
You can remove this line as a temporary workaround.