Skip to content
This repository has been archived by the owner on Jan 15, 2019. It is now read-only.

[dev.icinga.com #4152] Fix for buggy MySQL versions #56

Closed
icinga-migration opened this issue May 8, 2013 · 2 comments
Closed

[dev.icinga.com #4152] Fix for buggy MySQL versions #56

icinga-migration opened this issue May 8, 2013 · 2 comments
Labels
Milestone

Comments

@icinga-migration
Copy link

This issue has been migrated from Redmine: https://dev.icinga.com/issues/4152

Created by tgelf on 2013-05-08 09:33:37 +00:00

Assignee: (none)
Status: Resolved (closed on 2013-06-07 02:42:31 +00:00)
Target Version: 1.9.1
Last Update: 2013-06-07 02:42:31 +00:00 (in Redmine)

Icinga Version: 1.8.2
DB Type: MySQL
DB Version: 5.1
Jasper Version: 5.0.1

It seems that some MySQL versions don't respect their documentation when it goes to empty variables. As of http://dev.mysql.com/doc/refman/5.1/en/user-variables.html they should be NULL:

If you refer to a variable that has not been initialized, it has a value of NULL and a type of string.

However we have seen that this doesn't seem to be true at least on some 5.0 and 5.1 versions and could therefore lead to hardly reproduceable issues with SLA values being "sometimes" wrong. I haven't been able to reproduce this on 5.5 yet. You can find a small patch attached to this issue that should fix this.

This bug could also be related to a whole bunch of open MySQL issues related to MySQLs missbehaviour when it goes to variables named like column names. So a more conservative fix would rename @last_state to something different as last_state is also a column name. As this is rather ridiculous and the attached patch seems to be working fine I'd suggest to skip farther changes right now.

Cheers,
Thomas

Attachments

Changesets

2013-05-29 12:47:33 +00:00 by (unknown) b119991

fix empty variable for mysql sla procedure

fixes #4152
@icinga-migration
Copy link
Author

Updated by mfriedrich on 2013-05-08 09:40:46 +00:00

  • Target Version set to 1.9.1

@icinga-migration
Copy link
Author

Updated by Anonymous on 2013-06-07 02:42:31 +00:00

  • Status changed from New to Resolved
  • Done % changed from 0 to 100

Applied in changeset b119991.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
Projects
None yet
Development

No branches or pull requests

1 participant