[MXS-3879] MaxScale doesn't load maxscale section in persistent file after restart Created: 2021-11-16  Updated: 2021-11-19  Resolved: 2021-11-19

Status: Closed
Project: MariaDB MaxScale
Component/s: Core
Affects Version/s: 2.4
Fix Version/s: 2.4.19

Type: Bug Priority: Major
Reporter: Kevin Assignee: markus makela
Resolution: Fixed Votes: 0
Labels: None

Attachments: PNG File image-2021-11-16-16-21-09-552.png    

 Description   

After alter maxscale section parameter (like writeq_high_water) using HTTP PATCH /maxscale, we got a persistent config file global-options.cnf. However MaxScale doesn't load the maxscale section parameters, those parameters seem to be simply skipped.



 Comments   
Comment by markus makela [ 2021-11-17 ]

There's a separate handler for the MaxScale sections that handles the global options.

Comment by Kevin [ 2021-11-18 ]

You mean ini_global_handler? But that function only load the initial config file, and just ignore other global options in persistent file.

The problem can be reproduce after these steps:
1. Use HTTP PATCH /maxscale to change global option writeq_high_water to some value.
2. Shutdown and restart MaxScale process.
3. Call GET /maxscale to see if the changed value still there. The value will restore to the original value.

Comment by markus makela [ 2021-11-18 ]

This could be a bug in 2.4. Have you tested this with 2.5?

Comment by Kevin [ 2021-11-18 ]

No, only 2.4, but I've checked the code in 2.5, it seems like the same, since this line still exists: MXS_ERROR("The [maxscale] section must only be defined in the root configuration file.");

Comment by markus makela [ 2021-11-18 ]

Tested with 2.5, seems to work as expected there.

Comment by markus makela [ 2021-11-18 ]

2.4 does indeed fail to read it.

Generated at Thu Feb 08 04:24:36 UTC 2024 using Jira 8.20.16#820016-sha1:9d11dbea5f4be3d4cc21f03a88dd11d8c8687422.