Details
-
Bug
-
Status: Closed (View Workflow)
-
Major
-
Resolution: Fixed
-
None
Description
MariaDB gives a misleading error message if you specify an invalid value for a known system variable on the command line.
Take innodb-log-file-size as an example variable:
Known variable, legal value:
$ sql/mariadbd ... --innodb-log-file-size=1000000
|
...
|
2024-02-15 13:05:18 0 [Note] sql/mariadbd: ready for connections.
|
Known variable, invalid values:
$ sql/mariadbd ... --innodb-log-file-size=-123 # <- Not legal because negative
|
...
|
2024-02-15 13:06:25 0 [ERROR] sql/mariadbd: unknown variable 'innodb-log-file-size=-123'
|
$ sql/mariadbd ... --innodb-log-file-size=999999999999999999999999999 # <- Not legal because it's too large
|
...
|
2024-02-15 13:06:59 0 [ERROR] sql/mariadbd: unknown variable 'innodb-log-file-size=999999999999999999999999999'
|
Solution
Instead of reporting this as an "unknown variable", it should be reported as an "invalid value."
The code that produces this misleading error message is at https://github.com/MariaDB/server/blob/e71aecfd308d6093fd693044253518a872994394/mysys/my_getopt.c#L389
Attachments
Issue Links
- is duplicated by
-
MDEV-25386 MDEV-22219 Followup: small inconsistency in option handling
- Confirmed
- relates to
-
MDEV-26923 MariaDB will abort server startup if it finds an invalid parameter, but won't check for other invalid params
- Closed