[MXS-25] bugzillaId-656: MySQL Monitor: claims that Master is available after master failure Created: 2014-01-18  Updated: 2019-12-19  Resolved: 2015-04-30

Status: Closed
Project: MariaDB MaxScale
Component/s: mariadbmon, Plugin
Affects Version/s: 1.0.0
Fix Version/s: 1.1.1

Type: Bug Priority: Minor
Reporter: Timofey Turenko Assignee: markus makela
Resolution: Fixed Votes: 0
Labels: None
Environment:

Linux



 Description   

This is imported from bugzilla item: http://bugs.mariadb.com/show_bug.cgi?id=656

Description Vilho Raatikka 2014-12-18 15:16:42 UTC
How to reproduce:
1. start rwsplit with a master and optionally with slaves
2. prevent connections to master by executing
iptables -I INPUT -p tcp --dport 3000 -j REJECT --reject-with icmp-admin-prohibited
3. read the message log:

(..errors..)
2014-12-18 17:09:30 Server 127.0.0.1:3000 lost the master status.
2014-12-18 17:09:30 Info: A Master Server is now available: 127.0.0.1:3000
2014-12-18 17:10:35 Info: A Master Server is now available: 127.0.0.1:3000



 Comments   
Comment by Dipti Joshi (Inactive) [ 2015-03-10 ]

This is comment history from bugzilla:

Comment 1 Mark Riddoch 2015-02-13 10:28:46 UTC
Add as test case and retest

Comment 2 Timofey Turenko 2015-03-02 10:42:34 UTC
Error log says:

2015-03-02 12:36:31 Error : Monitor was unable to connect to server 192.168.122.141:3306 : "Can't connect to MySQL server on '192.168.122.141'
(111)"

Message log says:

2015-03-02 12:36:31 Server 192.168.122.141:3306 lost the master status.
2015-03-02 12:36:31 Info : A Master Server is now available: 192.168.122.141:3306

MaxAdmin says:

 
Server 0x26e71c0 (server1)
	Server:				192.168.122.141
	Status:               		Master, Down
	Protocol:			MySQLBackend
	Port:				3306
	Server Version:			5.5.42-MariaDB-log
	Node Id:			141
	Master Id:			-1
	Slave Ids:			142, 143 , 144 
	Repl Depth:			0
	Number of connections:		0
	Current no. of conns:		0
	Current no. of operations:	0

So, the problem is visible only in the messages log. Is it a real problem or just logging issue?

Comment by markus makela [ 2015-04-30 ]

MySQL monitor wasn't checking if the server was running when generating the Info message about new master.

Comment by Timofey Turenko [ 2015-05-06 ]

checked manually:

2015-05-06 15:46:26 MaxScale started with 8 server threads.
2015-05-06 15:46:26 Info : A Master Server is now available: 192.168.122.161:3306
2015-05-06 15:46:36 Info : A Master Server is now available: 192.168.122.161:3306
2015-05-06 15:46:43 Loaded module MySQLBackend: V2.0.0 from /usr/local/mariadb-maxscale/modules/libMySQLBackend.so
2015-05-06 15:46:43 Loaded module qlafilter: V1.1.1 from /usr/local/mariadb-maxscale/modules/libqlafilter.so
2015-05-06 15:46:46 Info : A Master Server is now available: 192.168.122.161:3306
2015-05-06 15:46:56 Info : A Master Server is now available: 192.168.122.161:3306
2015-05-06 15:47:07 Info : A Master Server is now available: 192.168.122.161:3306

block master:

2015-05-06 15:47:17 Server 192.168.122.161:3306 lost the master status.
2015-05-06 15:49:29 Server 192.168.122.161:3306 lost the master status.

unblock master:
2015-05-06 15:50:40 Info : A Master Server is now available: 192.168.122.161:3306
2015-05-06 15:50:50 Info : A Master Server is now available: 192.168.122.161:3306

block again: nothing in the lmessage log, but clear message in error log

2015-05-06 15:51:00 Error : Monitor was unable to connect to server 192.168.122.161:3306 : "Can't connect to MySQL server on '192.168.122.161' (113)"

I guees this can be closed now

Comment by Timofey Turenko [ 2015-05-12 ]

verified by manual checking of error log when Master node is blocked by firewall

Generated at Thu Feb 08 03:56:13 UTC 2024 using Jira 8.20.16#820016-sha1:9d11dbea5f4be3d4cc21f03a88dd11d8c8687422.