[MXS-3552] Possible SwitchOver When Master & Slave status is "Maintenance" Created: 2021-05-18  Updated: 2021-08-26  Resolved: 2021-08-25

Status: Closed
Project: MariaDB MaxScale
Component/s: Monitor, readwritesplit
Affects Version/s: 2.4.7
Fix Version/s: N/A

Type: Bug Priority: Major
Reporter: febriyant Assignee: Unassigned
Resolution: Cannot Reproduce Votes: 0
Labels: errors
Environment:

CentOS 7


Attachments: PNG File image_2021_02_04T10_58_59_188Z.png    

 Description   

[DB_190_nbc]
type=server
address=192.168.101.190
port=13306
protocol=MariadBBackend
priority=2
 
[DB_191_biznet]
type=server
address=192.168.101.191
port=13306
protocol=MariadBBackend
priority=1
 
[MariaDB-Monitor-testing]
type=monitor
module=mariadbmon
servers=DB_190_nbc,DB_191_biznet
user=maxscale
password=90AF8370A0805BCDBB221C772BA54755
monitor_interval=1000
auto_failover=false
detect_stale_master=true
failover_timeout=10
auto_rejoin=true
failcount=5
master_failure_timeout=2
verify_master_failure=true
switchover_timeout=90
replication_user=maxscale
replication_password=90AF8370A0805BCDBB221C772BA54755
detect_stale_slave=true
 
[Read-Write-Service-testing]
type=service
router=readwritesplit
servers=DB_190_nbc,DB_191_biznet
user=maxscale
password=90AF8370A0805BCDBB221C772BA54755
master_failure_mode=fail_on_write
strict_multi_stmt=false
use_sql_variables_in=master
master_reconnection=true
delayed_retry=true
delayed_retry_timeout=20
transaction_replay=true
max_sescmd_history=60
prune_sescmd_history=true
connection_timeout=36000
filters=Hint
 
[Read-Write-Listener-testing]
type=listener
service=Read-Write-Service-testing
protocol=MariadbClient
port=13306
authenticator=MariaDBAuth
authenticator_options=lower_case_table_names=true

I have trouble when I manually switchover using command

maxadmin call command mariadbmon switchover MariaDB-Monitor-Test DB_191_biznet DB_190_nbc

"errors":[
  {
    "detail": "Slave catchup timed out on slave 'DB_191_biznet'."
  },
  {
    "detail": "Switchover DB_190_nbc -> DB_191_biznet failed."
  }
]

so whether possible switchover when I set Master & slave to maintenance first and after that I Switchover manually ?



 Comments   
Comment by markus makela [ 2021-08-25 ]

I think the problem is solved by setting the values of failover_timeout and switchover_timeout to higher values: https://mariadb.com/kb/en/mariadb-maxscale-25-mariadb-monitor/#failover_timeout-and-switchover_timeout

How long does that maxctrl command take to execute?

Comment by markus makela [ 2021-08-25 ]

Tested with MaxScale 2.5 and it seems to work as expected. I used a replication delay of 150 seconds and switchover_timeout of 90 seconds. The maxctrl command returned after about 90 seconds as expected.

Comment by febriyant [ 2021-08-26 ]

I think more than value I set on config
because I already tested with higher value on switchover_timeout

still got same error.

Comment by markus makela [ 2021-08-26 ]

Was this with 2.5?

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