Announcement

#1 2015-02-09 18:29:59

hamiltont
Member
2015-02-06
12

Installation Failure For MySQL > 5.7.4 with default mysql settings

Hey Piwigo Team,

I'm not an expert on Piwigo, but here's some info that might help.

As of mysql 5.7.4 it appears that mysql turns strict mode by default - see https://dev.mysql.com/doc/refman/5.7/en … ode-strict

This causes the piwigo installation to fail when creating numerous tables.
I can confirm that disabling STRICT_TRANS_TABLES allows piwigo to
install properly. Helpful stackoverflow post on this topic is at
http://stackoverflow.com/a/25351733


Errors, so that they can hopefully be cleaned up and Piwigo can work with default MySQL

[Mon Feb 09 17:13:15 2015] [error] [client 172.17.42.1] PHP Warning:  [mysql error 1067] Invalid default value for 'date'\nCREATE TABLE `piwigo_comments` ( `id` int(11) unsigned NOT NULL auto_increment, `image_id` mediumint(8) unsigned NOT NULL default '0', `date` datetime NOT NULL default '0000-00-00 00:00:00', `author` varchar(255) default NULL, `email` varchar(255) default NULL, `author_id` mediumint(8) unsigned DEFAULT NULL, `anonymous_id` varchar(45) NOT NULL, `website_url` varchar(255) DEFAULT NULL, `content` longtext, `validated` enum('true','false') NOT NULL default 'false', `validation_date` datetime default NULL, PRIMARY KEY  (`id`), KEY `comments_i2` (`validation_date`), KEY `comments_i1` (`image_id`) ) ENGINE=MyISAM DEFAULT CHARACTER SET utf8; in /var/www/include/dblayer/functions_mysqli.inc.php on line 830, referer: http://<removed>/install.php?language=en_US
[Mon Feb 09 17:13:15 2015] [error] [client 172.17.42.1] PHP Warning:  [mysql error 1067] Invalid default value for 'date'\nCREATE TABLE `piwigo_history` ( `id` int(10) unsigned NOT NULL auto_increment, `date` date NOT NULL default '0000-00-00', `time` time NOT NULL default '00:00:00', `user_id` mediumint(8) unsigned NOT NULL default '0', `IP` varchar(15) NOT NULL default '', `section` enum('categories','tags','search','list','favorites','most_visited','best_rated','recent_pics','recent_cats') default NULL, `category_id` smallint(5) default NULL, `tag_ids` varchar(50) default NULL, `image_id` mediumint(8) default NULL, `summarized` enum('true','false') default 'false', `image_type` enum('picture','high','other') default NULL, PRIMARY KEY  (`id`), KEY `history_i1` (`summarized`) ) ENGINE=MyISAM DEFAULT CHARACTER SET utf8; in /var/www/include/dblayer/functions_mysqli.inc.php on line 830, referer: http://<removed>/install.php?language=en_US
[Mon Feb 09 17:13:15 2015] [error] [client 172.17.42.1] PHP Warning:  [mysql error 1067] Invalid default value for 'date_available'\nCREATE TABLE `piwigo_images` ( `id` mediumint(8) unsigned NOT NULL auto_increment, `file` varchar(255) binary NOT NULL default '', `date_available` datetime NOT NULL default '0000-00-00 00:00:00', `date_creation` datetime default NULL, `name` varchar(255) default NULL, `comment` text, `author` varchar(255) default NULL, `hit` int(10) unsigned NOT NULL default '0', `filesize` mediumint(9) unsigned default NULL, `width` smallint(9) unsigned default NULL, `height` smallint(9) unsigned default NULL, `coi` char(4) default NULL COMMENT 'center of interest', `representative_ext` varchar(4) default NULL, `date_metadata_update` date default NULL, `rating_score` float(5,2) unsigned default NULL, `path` varchar(255) NOT NULL default '', `storage_category_id` smallint(5) unsigned default NULL, `level` tinyint unsigned NOT NULL default '0', `md5sum` char(32) default NULL, `added_by` mediumint(8) unsigned NOT NULL default '0', `rotation` tinyint unsigned default in /var/www/include/dblayer/functions_mysqli.inc.php on line 830, referer: http://<removed>/install.php?language=en_US
[Mon Feb 09 17:13:15 2015] [error] [client 172.17.42.1] PHP Warning:  [mysql error 1067] Invalid default value for 'date_deleted'\nCREATE TABLE `piwigo_old_permalinks` ( `cat_id` smallint(5) unsigned NOT NULL default '0', `permalink` varchar(64) binary NOT NULL default '', `date_deleted` datetime NOT NULL default '0000-00-00 00:00:00', `last_hit` datetime default NULL, `hit` int(10) unsigned NOT NULL default '0', PRIMARY KEY  (`permalink`) ) ENGINE=MyISAM DEFAULT CHARACTER SET utf8; in /var/www/include/dblayer/functions_mysqli.inc.php on line 830, referer: http://<removed>/install.php?language=en_US
[Mon Feb 09 17:13:15 2015] [error] [client 172.17.42.1] PHP Warning:  [mysql error 1067] Invalid default value for 'date'\nCREATE TABLE `piwigo_rate` ( `user_id` mediumint(8) unsigned NOT NULL default '0', `element_id` mediumint(8) unsigned NOT NULL default '0', `anonymous_id` varchar(45) NOT NULL default '', `rate` tinyint(2) unsigned NOT NULL default '0', `date` date NOT NULL default '0000-00-00', PRIMARY KEY  (`element_id`,`user_id`,`anonymous_id`) ) ENGINE=MyISAM DEFAULT CHARACTER SET utf8; in /var/www/include/dblayer/functions_mysqli.inc.php on line 830, referer: http://<removed>/install.php?language=en_US
[Mon Feb 09 17:13:15 2015] [error] [client 172.17.42.1] PHP Warning:  [mysql error 1067] Invalid default value for 'expiration'\nCREATE TABLE `piwigo_sessions` ( `id` varchar(255) binary NOT NULL default '', `data` mediumtext NOT NULL, `expiration` datetime NOT NULL default '0000-00-00 00:00:00', PRIMARY KEY  (`id`) ) ENGINE=MyISAM DEFAULT CHARACTER SET utf8; in /var/www/include/dblayer/functions_mysqli.inc.php on line 830, referer: http://<removed>/install.php?language=en_US
[Mon Feb 09 17:13:15 2015] [error] [client 172.17.42.1] PHP Warning:  [mysql error 1067] Invalid default value for 'applied'\nCREATE TABLE `piwigo_upgrade` ( `id` varchar(20) NOT NULL default '', `applied` datetime NOT NULL default '0000-00-00 00:00:00', `description` varchar(255) default NULL, PRIMARY KEY  (`id`) ) ENGINE=MyISAM DEFAULT CHARACTER SET utf8; in /var/www/include/dblayer/functions_mysqli.inc.php on line 830, referer: http://<removed>/install.php?language=en_US
[Mon Feb 09 17:13:15 2015] [error] [client 172.17.42.1] PHP Warning:  [mysql error 1067] Invalid default value for 'registration_date'\nCREATE TABLE `piwigo_user_infos` ( `user_id` mediumint(8) unsigned NOT NULL default '0', `nb_image_page` smallint(3) unsigned NOT NULL default '15', `status` enum('webmaster','admin','normal','generic','guest') NOT NULL default 'guest', `language` varchar(50) NOT NULL default 'en_UK', `expand` enum('true','false') NOT NULL default 'false', `show_nb_comments` enum('true','false') NOT NULL default 'false', `show_nb_hits` enum('true','false') NOT NULL default 'false', `recent_period` tinyint(3) unsigned NOT NULL default '7', `theme` varchar(255) NOT NULL default 'elegant', `registration_date` datetime NOT NULL default '0000-00-00 00:00:00', `enabled_high` enum('true','false') NOT NULL default 'true', `level` tinyint unsigned NOT NULL default '0', `activation_key` varchar(255) default NULL, `activation_key_expire` datetime default NULL, `lastmodified` TIMESTAMP DEFAULT CURRENT_TIMESTAMP ON UPDATE CURRENT_TIMESTAMP, PRIMARY KEY (`user_id`), KEY `last in /var/www/include/dblayer/functions_mysqli.inc.php on line 830, referer: http://<removed>/install.php?language=en_US

Piwigo version: 2.7.3

Last edited by hamiltont (2015-02-09 18:50:07)

Offline

 

#2 2015-02-10 00:10:26

flop25
Piwigo Team
2006-07-06
7037

Re: Installation Failure For MySQL > 5.7.4 with default mysql settings

thx for the report!
could you open a ticket in our bugtracker plz? http://piwigo.org/bugs thx again!


To get a better help : Politeness like Hello-A link-Your past actions precisely described
Check my extensions : more than 30 available
who I am and what I do : http://fr.gravatar.com/flop25
My gallery : an illustration of how to integrate Piwigo in your website

Offline

 

#3 2015-02-16 20:55:27

hamiltont
Member
2015-02-06
12

Re: Installation Failure For MySQL > 5.7.4 with default mysql settings

Offline

 

Board footer

Powered by FluxBB

github twitter newsletter Donate Piwigo.org © 2002-2022 · Contact