Ich habe eine meiner WordPress-Websites mit dem Duplicator-Plugin exportiert. Wenn ich jetzt versuche, es auf meinem Localhost einzurichten, ist es nicht möglich, einige Tabellen in die Datenbank zu importieren. Welche Ursache, dass die Site nicht auf localhost läuft.
Beim Überprüfen des Doplicator-Plugin-Protokolls habe ich viele Fehler erhalten, einige davon sind:
**********************************************************************
VERSION: 1.1.0 PHP: 7.0.2 | SAPI: apache2handler SERVER: Apache/2.4.17 (Win64) PHP/7.0.2
DATENBANK-ROUTINEN
————————————– SERVERUMGEBUNG ————————————– MYSQL VERSION: 5.7.9 TIMEOUT: 5000 MAXPACK: 1048576 —————————— ——– DATENBANKERGEBNISSE ————————————–
**ERROR** database error write ‘Invalid default value for ‘comment_date” – [sql=
CREATE TABLE wp_comments (
comment_ID bigint(20) unsigned NOT NULL A…]
**ERROR** database error write ‘Invalid default value for ‘created” – [sql=
CREATE TABLE wp_duplicator_packages (
id bigint(20) unsigned NOT NUL…]
**ERROR** database error write ‘Invalid default value for ‘link_updated” – [sql=
CREATE TABLE wp_links (
link_id bigint(20) unsigned NOT NULL AUTO_IN…]
**ERROR** database error write ‘Invalid default value for ‘post_date” – [sql=
CREATE TABLE wp_posts (
ID bigint(20) unsigned NOT NULL AUTO_INCREME…]
**ERROR** database error write ‘Invalid default value for ‘user_registered” – [sql=
CREATE TABLE wp_users (
ID bigint(20) unsigned NOT NULL AUTO_INCREME…]
**ERROR** database error write ‘Table ‘ne.wp_duplicator_packages’ doesn’t exist’ – [sql=
/* INSERT TABLE DATA: wp_duplicator_packages */
INSERT INTO `wp_duplicato…]
**ERROR** database error write ‘Table ‘ne.wp_duplicator_packages’ doesn’t exist’ – [sql=INSERT INTO wp_duplicator_packages VALUES(“2”, “20151126_naturalexpressio…]
**ERROR** database error write ‘Table ‘ne.wp_duplicator_packages’ doesn’t exist’ – [sql=INSERT INTO wp_duplicator_packages VALUES(“3”, “20151126_naturalexpressio…]
**ERROR** database error write ‘Table ‘ne.wp_posts’ doesn’t exist’ – [sql=
/* INSERT TABLE DATA: wp_posts */
INSERT INTO wp_posts VALUES(“4”, “1”, …]
**ERROR** database error write ‘Table ‘ne.wp_posts’ doesn’t exist’ – [sql=INSERT INTO wp_posts VALUES(“5”, “1”, “2015-09-07 14:22:39”, “2015-09-07 …]
**ERROR** database error write ‘Table ‘ne.wp_posts’ doesn’t exist’ – [sql=INSERT INTO wp_posts VALUES(“7”, “1”, “2015-09-07 14:30:51”, “2015-09-07 …]
**ERROR** database error write ‘Table ‘ne.wp_posts’ doesn’t exist’ – [sql=INSERT INTO wp_posts VALUES(“8”, “1”, “2015-09-07 14:32:08”, “2015-09-07 …]
**ERROR** database error write ‘Table ‘ne.wp_posts’ doesn’t exist’ – [sql=INSERT INTO wp_posts VALUES(“9”, “1”, “2015-09-07 14:32:36”, “2015-09-07 …]
**ERROR** database error write ‘Table ‘ne.wp_posts’ doesn’t exist’ – [sql=INSERT INTO wp_posts VALUES(“10”, “1”, “2015-09-07 14:33:05”, “2015-09-07…]
**ERROR** database error write ‘Table ‘ne.wp_posts’ doesn’t exist’ – [sql=INSERT INTO wp_posts VALUES(“11”, “1”, “2015-09-07 14:34:39”, “2015-09-07…]
**ERROR** database error write ‘Table ‘ne.wp_posts’ doesn’t exist’ – [sql=INSERT INTO wp_posts VALUES(“19”, “1”, “2015-09-09 08:33:24”, “2015-09-09…]
Ich habe gegoogelt und festgestellt, dass das Aktualisieren von sql_mode mit NO_ENGINE_SUBSTITUTION das Problem löst.
Da ich LAMP verwende, habe ich /etc/mysql/my.cnf geöffnet und die folgende Zeile hinzugefügt:
sql_mode=NO_ENGINE_SUBSTITUTION
und den Apache-Server mit dem folgenden Befehl neu gestartet:
sudo service apache2 restart
Aber es löst das Problem nicht. Lassen Sie mich Ihre Lösung wissen …. danke.