"last_state_change" shows "1970-01-01 01:00:00" for unreachable host
Open
@Al2Klimov is already working on this.
Since Nov 8, 2024.
area/icingadb
bug
- Dominant language
- C++
- Stars
- 2.2k
- Forks
- 616
- Avg merge
- 5d 6h
- Merged PRs (30d)
- 10
Description
Describe the bug
When a host-object is displayed as unreachable since it was created and checked the first time, the "last_state_change" shows the date "1970-01-01 01:00:00" (seems to be Unix-epoch timestamp 3600).
To Reproduce
- create a new host-object with an unreachable IP
- deploy
- check "last_state_change" in icingaweb2 "Problems -> Host Problems" by clicking on the event of the new host-object
Expected behavior
The 0- or 3600-default-value (epoch depends on the timezone) of last_state_change-field should be filled with the timestamp of the moment when the "hostalive"-check has marked the object as unreachable/down.
Screenshots
Your Environment
- Icinga Web 2 version and modules (System - About): 2.12.1
- Web browser used: Firefox 128.4.0esr (64-Bit)
- Icinga 2 version used (
icinga2 --version): r2.14.2-1 - PHP version used (
php --version): 8.1.29 - Server operating system and version: SLES 15 SP6
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Assessment
This issue has not been assessed yet.