Bug #76884 fix GTID mode to work correctly in --bootstrap/--initialize mode

Submitted: 29 Apr 2015 11:34 Modified: 5 Jun 2015 9:35
Reporter: Georgi Kodinov Email Updates:
Status: Closed Impact on me:
None 
Category:MySQL Server: Replication Severity:S3 (Non-critical)
Version:5.7.8 OS:Any
Assigned to: CPU Architecture:Any

[29 Apr 2015 11:34] Georgi Kodinov
Description:
Currently the mysqld initialization code (init_server_components() function) has to turn the global gtid mode off when --bootstrap is specified.
So it has the following code:

  /// @todo: this looks suspicious, revisit this /sven
  enum_gtid_mode gtid_mode= get_gtid_mode(GTID_MODE_LOCK_NONE);

  /* TODO: remove this. */
  if (gtid_mode != GTID_MODE_OFF && opt_bootstrap)
    _gtid_mode= GTID_MODE_OFF;

If you remove the if() part it crashes.

How to repeat:
Comment out the if() above and run the tests

Suggested fix:
Make sure the server works properly with the default values for gtid (on) in --bootstrap/--initialize mode.
[29 Apr 2015 11:56] Sven Sandberg
Posted by developer:
 
The test that fails is i_rpl.rpl_bootstrap_gtid
[25 May 2015 0:00] Paul DuBois
Note for documentation: The following locations in refman-5.7 refer to GTIDs being disabled in initialization mode and might need updating per the present bug.

http://dev.mysql.com/doc/refman/5.7/en/server-options.html#option_mysqld_initialize
http://dev.mysql.com/doc/refman/5.7/en/server-options.html#option_mysqld_bootstrap
[25 May 2015 15:18] David Moss
Posted by developer:
 
Based on discussion with Sven the following changes were made to these options:

http://dev.mysql.com/doc/refman/5.7/en/server-options.html#option_mysqld_bootstrap

http://dev.mysql.com/doc/refman/5.7/en/server-options.html#option_mysqld_initialize

This paragraph is now used:
In MySQL 5.7.7 and earlier, global transaction identifiers (GTIDs) were automatically disabled whenever --initialize was enabled. In MySQL 5.7.8 and later GTIDs are not disabled when --initialize is enabled.

Portions of this website are copyright © 2001, 2002 The PHP Group

Page generated in 0.054 sec. using MySQL 8.4.7-u6-cloud

Timestamp references displayed by the system are UTC.
Content reproduced on this site is the property of the respective copyright holders.
It is not reviewed in advance by Oracle and does not necessarily represent the opinion of Oracle or any other party.