Icinga / Icinga/icinga2

"last_state_change" shows "1970-01-01 01:00:00" for unreachable host

Open
#10,217 0 comments 0 reactions 1 assignee View on GitHub

@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

  1. create a new host-object with an unreachable IP
  2. deploy
  3. 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

grafik

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

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.