Details
-
Bug
-
Status: Confirmed (View Workflow)
-
Minor
-
Resolution: Unresolved
-
10.1.11, 5.5(EOL), 10.0(EOL), 10.1(EOL), 10.2(EOL)
-
Linux
Description
mysqld_multi parses the --defaults-file=... option just fine and reads from the given file instead of reading the global default under /etc
It does not pass on that option to the mysqld instances it starts, and so the mysqld processes read the global default my.cnf for options that were not set by mysqld_multi itself via command line options.
This can lead to confusing situations as the mysqld processes now might be using settings that were not specified in the [mysqld] section of the options file given to mysqld_multi via its --defaults-file option.
As a workaround it is possible to put a "defaults-file=..." onto the first line of each [mysqld#] server block int the mysqld_multi configuration file.
The manual page doesn't really specify how this should work, it has this paragraph though:
"The [mysqld] or [mysqld_safe] groups can be used for common options read by all instances of mysqld or mysqld_safe. You can specify a --defaults-file=file_name option to use a different configuration file for that instance, in which case the [mysqld] or [mysqld_safe] groups from that file will be used for that instance. "
I tend to interpret that as "The [mysqld] ... group ... of the same file that mysqld_multi was reading".
Also the the "You can specify a --defaults-file=file_name option" part is not really clear, it probably refers to putting this into the server specific [mysqld#] option, in which case the double dash prefix should be removed and it should clearly be stated that this needs to be the very first option in a [mysql#] option
Suggested fix:
- Pass through --defaults-file option value to all started mysqld instances, unless a different defaults-file entry was found in the instance specific [mysqld#] block
- be more clear about option file handling of started instances in the documentation