[MDEV-13430] InnoDB upgrade from previous versions to 10.3 is not possible Created: 2017-08-02  Updated: 2017-08-10  Resolved: 2017-08-08

Status: Closed
Project: MariaDB Server
Component/s: Storage Engine - InnoDB
Affects Version/s: 10.3
Fix Version/s: 10.2.8, 10.3.1

Type: Bug Priority: Critical
Reporter: Elena Stepanova Assignee: Marko Mäkelä
Resolution: Fixed Votes: 0
Labels: None

Issue Links:
Blocks
blocks MDEV-13269 Upgrade tests for InnoDB undo log Closed
Problem/Incident
causes MDEV-13475 InnoDB: Failing assertion: lsn == log... Closed

 Description   

10.3 refuses to startup on a data directory created with a previous version. It appears that it mistakenly detects that the server crashed before upgrade, even if it did not.

  • create a data directory with a previous version, e.g. 10.2, with all defaults; contents does not matter;
  • shut down the server properly (with or without fast_shutdown, does not matter);
  • try to start 10.3 on the same datadir:

10.2 log before upgrade, to show that the server was shut down normally

Version: '10.2.8-MariaDB-debug'  socket: '/data/bld/10.2/data/tmp/mysql.sock'  port: 3306  Source distribution
2017-08-02 23:44:53 139939325794048 [Note] /data/bld/10.2/bin/mysqld (root[root] @ localhost [::1]): Normal shutdown
 
2017-08-02 23:44:53 139939325794048 [Note] Event Scheduler: Purging the queue. 0 events
2017-08-02 23:44:53 139938876086016 [Note] InnoDB: FTS optimize thread exiting.
2017-08-02 23:44:53 139939325794048 [Note] InnoDB: Starting shutdown...
2017-08-02 23:44:53 139938356000512 [Note] InnoDB: Dumping buffer pool(s) to /data/bld/10.2/data/ib_buffer_pool
2017-08-02 23:44:53 139938356000512 [Note] InnoDB: Buffer pool(s) dump completed at 170802 23:44:53
2017-08-02 23:44:54 139939325794048 [Note] InnoDB: Shutdown completed; log sequence number 1620126
2017-08-02 23:44:54 139939325794048 [Note] InnoDB: Removed temporary tablespace data file: "ibtmp1"
2017-08-02 23:44:54 139939325794048 [Note] /data/bld/10.2/bin/mysqld: Shutdown complete

10.3 1b0cf1b7295f1abee3bd62aa36a1c8aeff0d098d

2017-08-02 23:45:03 139667643228224 [Note] InnoDB: !!!!!!!! UNIV_DEBUG switched on !!!!!!!!!
2017-08-02 23:45:03 139667643228224 [Note] InnoDB: Mutexes and rw_locks use GCC atomic builtins
2017-08-02 23:45:03 139667643228224 [Note] InnoDB: Uses event mutexes
2017-08-02 23:45:03 139667643228224 [Note] InnoDB: Compressed tables use zlib 1.2.8
2017-08-02 23:45:03 139667643228224 [Note] InnoDB: Using Linux native AIO
2017-08-02 23:45:03 139667643228224 [Note] InnoDB: Number of pools: 1
2017-08-02 23:45:03 139667643228224 [Note] InnoDB: Using SSE2 crc32 instructions
2017-08-02 23:45:03 139667643228224 [Note] InnoDB: Initializing buffer pool, total size = 128M, instances = 1, chunk size = 128M
2017-08-02 23:45:03 139667643228224 [Note] InnoDB: Completed initialization of buffer pool
2017-08-02 23:45:03 139666910693120 [Note] InnoDB: If the mysqld execution user is authorized, page cleaner thread priority can be changed. See the man page of setpriority().
2017-08-02 23:45:03 139667643228224 [ERROR] InnoDB: Upgrade after a crash is not supported. The redo log was created with MariaDB 10.2.8.
2017-08-02 23:45:03 139667643228224 [ERROR] InnoDB: Plugin initialization aborted at srv0start.cc[2215] with error Generic error
2017-08-02 23:45:04 139667643228224 [Note] InnoDB: Starting shutdown...
2017-08-02 23:45:04 139667643228224 [ERROR] Plugin 'InnoDB' init function returned error.
2017-08-02 23:45:04 139667643228224 [ERROR] Plugin 'InnoDB' registration as a STORAGE ENGINE failed.
2017-08-02 23:45:04 139667643228224 [Note] Plugin 'FEEDBACK' is disabled.
2017-08-02 23:45:04 139667643228224 [ERROR] Unknown/unsupported storage engine: InnoDB
2017-08-02 23:45:04 139667643228224 [ERROR] Aborting



 Comments   
Comment by Marko Mäkelä [ 2017-08-07 ]

bb-10.3-monty

Comment by Marko Mäkelä [ 2017-08-07 ]

bb-10.2-marko
While I did not repeat any problem in 10.2, I think that it is cleanest to ensure that the log_sys->log.lsn is set to the most recent checkpoint at startup.

Comment by Jan Lindström (Inactive) [ 2017-08-08 ]

ok to push.

Generated at Thu Feb 08 08:05:32 UTC 2024 using Jira 8.20.16#820016-sha1:9d11dbea5f4be3d4cc21f03a88dd11d8c8687422.