openhab / openhabian

openHABian - empowering the smart home, for Raspberry Pi and Debian systems
https://community.openhab.org/t/13379
ISC License
818 stars 251 forks source link

systemd-timesyncd service fails frequently #1744

Closed BigGeorgeTx closed 1 year ago

BigGeorgeTx commented 1 year ago

Issue information:

I have noticed that systemd-timesyncd service fails regularly. I restart it frequently, but it seems like every time I check, it has failed. This leads to problems such as logs not rotating.

Debug information:

This is what I do to check if it is running: `openhabian@openhab-midway:~ $ systemctl -a --failed UNIT LOAD ACTIVE SUB DESCRIPTION ● systemd-timesyncd.service loaded failed failed Network Time Synchronization

LOAD = Reflects whether the unit definition was properly loaded. ACTIVE = The high-level unit activation state, i.e. generalization of SUB. SUB = The low-level unit activation state, values depend on unit type. 1 loaded units listed. To show all installed unit files use 'systemctl list-unit-files'. openhabian@openhab-midway:~ $ systemctl restart systemd-timesyncd ==== AUTHENTICATING FOR org.freedesktop.systemd1.manage-units === Authentication is required to restart 'systemd-timesyncd.service'. Authenticating as: ,,, (openhabian) Password: ==== AUTHENTICATION COMPLETE === openhabian@openhab-midway:~ $ systemctl -a --failed UNIT LOAD ACTIVE SUB DESCRIPTION 0 loaded units listed. To show all installed unit files use 'systemctl list-unit-files'.`

This is what I see with journalct | grep timesyncd

Nov 27 13:34:26 openhab-midway.hsd1.ut.comcast.net systemd-timesyncd[7028]: Initial synchronization to time server 64.79.100.197:123 (0.debian.pool.ntp.org).
Nov 27 13:34:27 openhab-midway.hsd1.ut.comcast.net systemd[1]: systemd-timesyncd.service: Succeeded.
Nov 27 13:34:27 openhab-midway.hsd1.ut.comcast.net systemd[1]: systemd-timesyncd.service: Succeeded.
Nov 27 13:34:28 openhab-midway.hsd1.ut.comcast.net systemd-timesyncd[7106]: Initial synchronization to time server 50.205.57.38:123 (0.debian.pool.ntp.org).
Nov 27 13:34:28 openhab-midway.hsd1.ut.comcast.net systemd[1]: systemd-timesyncd.service: Succeeded.
Nov 27 13:34:28 openhab-midway.hsd1.ut.comcast.net systemd[1]: systemd-timesyncd.service: Succeeded.
Nov 27 13:34:28 openhab-midway.hsd1.ut.comcast.net systemd[1]: systemd-timesyncd.service: Start request repeated too quickly.
Nov 27 13:34:28 openhab-midway.hsd1.ut.comcast.net systemd[1]: systemd-timesyncd.service: Failed with result 'start-limit-hit'.
Nov 28 02:07:40 openhab-midway.hsd1.ut.comcast.net mirror_SD[4513]: /var/lib/systemd/timesync/clock
Nov 28 17:30:50 openhab-midway.hsd1.ut.comcast.net polkitd(authority=local)[19574]: Operator of unix-process:12608:318851533 successfully authenticated as unix-user:openhabian to gain ONE-SHOT authorization for action org.freedesktop.systemd1.manage-units for system-bus-name::1.31770 [systemctl restart systemd-timesyncd] (owned by unix-user:openhabian)
Nov 28 17:30:51 openhab-midway.hsd1.ut.comcast.net systemd-timesyncd[12683]: Initial synchronization to time server 24.214.53.97:123 (0.debian.pool.ntp.org).
Nov 28 17:30:54 openhab-midway.hsd1.ut.comcast.net systemd[1]: systemd-timesyncd.service: Succeeded.
Nov 28 17:30:54 openhab-midway.hsd1.ut.comcast.net systemd-timesyncd[12720]: Initial synchronization to time server 38.229.56.9:123 (0.debian.pool.ntp.org).
Nov 28 17:30:57 openhab-midway.hsd1.ut.comcast.net systemd[1]: systemd-timesyncd.service: Succeeded.```

## System information:
Technical Information from UI

runtimeInfo: version: 3.4.0.M1 buildString: Milestone Build locale: en-US systemInfo: configFolder: /etc/openhab userdataFolder: /var/lib/openhab logFolder: /var/log/openhab javaVersion: 11.0.13 javaVendor: Azul Systems, Inc. javaVendorVersion: Zulu11.52+13-CA osName: Linux osVersion: 5.10.103-v7l+ osArchitecture: arm availableProcessors: 4 freeMemory: 33455096 totalMemory: 259522560 startLevel: 100 bindings:

Happy to provide additional information. I have two seperate openHAB systems at two different location, and both of them experience this.

I found this on the openHAB Community: https://community.openhab.org/t/ntp-service-allways-changes-to-inactive/136772 I believe these users are experiencing the same issue.

mstormi commented 1 year ago

Github isn't for users to request help with debugging. You need to debug your system yourself, turn to the forum for help. It's not necessarily a bug with openHABian as as we hardly touch that service. If you come up with a proper analysis to prove it is a bug and can tell what can be done about it, you can post it here.

BigGeorgeTx commented 1 year ago

Sorry. I thought I was being helpful.

On Tue, Nov 29, 2022 at 1:53 PM Markus Storm @.***> wrote:

Github isn't for users to request help with debugging. You need to debug your system yourself, turn to the forum for help. It's not necessarily a bug with openHABian as as we hardly touch that service. If you come up with a proper analysis to prove it is a bug and can tell what can be done about it, you can post it here.

— Reply to this email directly, view it on GitHub https://github.com/openhab/openhabian/issues/1744#issuecomment-1331211307, or unsubscribe https://github.com/notifications/unsubscribe-auth/ADEQZL3VKJ6VHASOYLRYNIDWKZNKHANCNFSM6AAAAAASN5D2DA . You are receiving this because you authored the thread.Message ID: @.***>

-- George Hyde Mobile +1-281-620-3039

mstormi commented 1 year ago

feel free to comment or reopen if you have relevant news to share