[MDEV-13397] MariaDB upgrade fail when using default_time_zone Created: 2017-07-28 Updated: 2018-07-19 Resolved: 2018-07-19 |
|
| Status: | Closed |
| Project: | MariaDB Server |
| Component/s: | Server, Time zones |
| Affects Version/s: | 10.0, 10.1 |
| Fix Version/s: | 10.0.36, 10.1.35 |
| Type: | Bug | Priority: | Major |
| Reporter: | Nicolas Payart | Assignee: | Sergei Golubchik |
| Resolution: | Fixed | Votes: | 0 |
| Labels: | None | ||
| Environment: |
Linux Debian |
||
| Description |
|
I am using official MariaDB APT repository on Debian 8 to install mariadb-server-10.1 package. I populate timezone tables using:
Then setting default_time_zone variable in my.cnf:
After restarting mysql service all works fine:
The problem occurs when upgrading mariadb-server packages. For example, my last apt-get upgrade upgraded MariaDB from v10.1.22 to v10.1.25:
MariaDB error log (/var/log/mysql.err) says:
If I comment the default_time_zone parameter in my.cnf, I can complete the upgrade process:
Then, reintroducing default_time_zone parameter in my.cnf, I am able to restart mysql service without any problem. It seems that something is broken in apt upgrade process when default_time_zone is set, whereas time zone tables are filled or not... Other users have encountered the same problem as you can see on StackOverflow: https://stackoverflow.com/questions/29565278/apt-get-upgrade-always-fails-on-mariadb-server-due-to-timezone |
| Comments |
| Comment by Elena Stepanova [ 2017-08-01 ] | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
I'm not getting the problem:
Is the problem reproducible for you? Can you paste the part of the upgrade stdout relevant to MariaDB upgrade? | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| Comment by Daniel Krämer [ 2017-08-18 ] | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
Hi there I ran into this Problem too! Here is the output which surprised me, cause the database was running fine before:
| ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| Comment by Elena Stepanova [ 2017-09-15 ] | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
The error about timezones is not mysterious, it happens because postinst configure runs mysql_install_db (even though the database is already there, so it's mainly a redundant call), which in turn runs mysqld boostrap, which does not recognize timezones. On some reason, it doesn't make upgrade to 10.1 (for which it was reported initially) fail for me. The error is still there, but upgrade proceeds and finishes successfully However, for 10.0 it does indeed fail. It's unclear how it worked before if it did, it looks like bootstrap would always fail this way. Maybe something was different in Debian scripts or Debian upgrade process. | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| Comment by Elena Stepanova [ 2017-09-15 ] | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
serg, what do you think about it? Would it be easy to make boostrap be aware of previously loaded timezones? Or alternatively, do we need to run bootstrap every time upon upgrade? |