Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

mysql: preserve mysql_common_validate return code #826

Closed
wants to merge 1 commit into from
Closed

mysql: preserve mysql_common_validate return code #826

wants to merge 1 commit into from

Conversation

kleind
Copy link
Contributor

@kleind kleind commented Jun 17, 2016

mysql: preserve mysql_common_validate return code if validate failed during monitor. OCF_NOT_RUNNING is not true.

We observed this when a node that did not have mysqld installed joined an existing cluster. monitor_0 happily returned OCF_NOT_RUNNING and the cluster never knew that node was not capable of running the mysqld resource.

Jun 17 12:05:33 node02 mysql(MysqlServer)[6848]: ERROR: Setup problem: couldn't find command: /usr/bin/mysqld_safe
Jun 17 12:05:33 node02 mysql(MysqlServer)[6848]: INFO: MySQL is not running
Jun 17 12:05:33 node02 lrmd[6708]:   notice: MysqlServer_monitor_0:6848:stderr [ ocf-exit-reason:Setup problem: couldn't find command: /usr/bin/mysqld_safe ]
Jun 17 12:05:33 node02 crmd[6711]:   notice: Operation MysqlServer_monitor_0: not running (node=node02, call=23, rc=7, cib-update=13, confirmed=true)
Jun 17 12:05:33 node02 crmd[6711]:   notice: node02-MysqlServer_monitor_0:23 [ ocf-exit-reason:Setup problem: couldn't find command: /usr/bin/mysqld_safe\n ]

@kleind
Copy link
Contributor Author

kleind commented Sep 29, 2016

Although nothing happened here in over three months, I just stumbled upon this thing again and think my patch is not correct. Instead it breaks probes in clusters where mysql is on not mounted storage (like drbd).
My intention was to fix the situation that the mysqld binary is not available. The patch does fix this single issue. It does however break probes since the my.cnf and the datadir (which mysql_common_validate checks for) are very likely not available on a passive node joining the cluster. So it will also return "not installed" if these files/dirs are not there although this situation may be perfectly okay in a drbd scenario.

Please do not apply this patch as is.

@fabbione fabbione deleted the branch ClusterLabs:master December 27, 2021 05:26
@fabbione fabbione closed this Dec 27, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants