/ icinga2 Public
Deletion of Downtimes after 19.01.2038 fails for IDO-MySQL #6064
Something isn't working
Deprecated, not supported or not worth any effort
When you add or delete a downtime that starts or ends after 19.01.2038 it should also be deleted from IDO-MySQL.
When you schedule a downtime after 19.01.2038 Icinga2 inserts the downtime with
(In Icingaweb2 this downtime will appear with an empty expiration time.)
When you delete the downtime via Icingaweb2 or API the downtime will be removed from Icinga2 itself and the following query is executed:
scheduled_end_time = FROM_UNIXTIME(2148294524)part gets evaluated by MySQL to
scheduled_end_time = NULL:
scheduled_end_time = NULLin a WHERE-clause does not work as expected (https://dev.mysql.com/doc/refman/5.7/en/working-with-null.html), it returns an emtpy set.
To delete the downtime the query could use
WHERE scheduled_end_time IS NULL.
When we restart Icinga2 the downtimes are removed from the database and the webinterface is in a consistend state again. I assume Icinga2 executes different queries during the initial config dump.
(Store the timestamps in another way, do not allow timestamps after 2038, something else...)
icinga2 --version): r2.8.1-1
icinga2 feature list): api checker command ido-mysql mainlog notification
The text was updated successfully, but these errors were encountered: