How to Set the Correct Time in Edge Devices (e.g., K3OS)

⚠️
Please note that k3OS is deprecated. We recommend switching to flatcar instead.

If you're experiencing issues with timestamps in messages or other time-related problems in your edge devices, it may be due to incorrect time settings. Here's how you can fix it.

Instructions

  1. Execute the date command in the terminal to understand the current time.
  2. Execute sudo ntpd -w -d -p pool.ntp.org to get the offset from the timeserver and to check whether the timeserver is working. The offset is the difference between the local time and the NTP server time.
  3. If there is an offset, check whether there are NTP servers set in the /etc/connman/main.conf file. If not, add them.
  4. If NTP is not the issue, it could be caused by a backlog in the system, especially when using an older version with the MQTT bridge. In newer versions, you can check the lag of Kafka with Kowl and then go to consumer groups.