Description of problem: To make it easier to debug cluster issues, ovirt want to switch to UTC timestamps, so timestamps in engine and vdsm logs match. To make this happen, we need also sanlock log timestamps in UTC format. I think the best solution would be to provide a configuration option for UTC timestamps. I guess we need to change /var/log/messages to UTC as well to debug sanlock when using UTC timestamps. The current way to get UTC timestamps in the logs is switch the system to UTC timezone.
I think just changing the logging timezone to utc is fine, I don't see any need to have it configurable. When I replace localtime() with gmtime() I see this in /var/log/sanlock.log: 2016-11-02 08:02:16+0000 3186563 [27332]: sanlock daemon started 3.4.0 host null-02 and this in /var/log/messages: Nov 2 03:02:16 null-02 sanlock[27332]: 2016-11-02 08:02:16+0000 3186563 [27332]: sanlock daemon started 3.4.0 host null-02 (do you think we can drop the %z / +0000 with this change?)
(In reply to David Teigland from comment #1) > I think just changing the logging timezone to utc is fine, I don't see any > need to have it configurable. The issue is using different timestamps when running with older vdsm using localtime. The purpose of this bug is to allow vdsm to configure sanlock so both use the same timestamps without affecting older vdsm versions when a user upgrade sanlock. > When I replace localtime() with gmtime() I > see this in /var/log/sanlock.log: > > 2016-11-02 08:02:16+0000 3186563 [27332]: sanlock daemon started 3.4.0 host > null-02 > > and this in /var/log/messages: > > Nov 2 03:02:16 null-02 sanlock[27332]: 2016-11-02 08:02:16+0000 3186563 > [27332]: sanlock daemon started 3.4.0 host null-02 Sending timestamps and pid to syslog does not look useful. > (do you think we can drop the %z / +0000 with this change?) Yes
Why are we not just setting the base system to be in UTC?
(In reply to Peter Portante from comment #3) > Why are we not just setting the base system to be in UTC? I agree that this is the best solution, however upstream sanlock includes now the option to create utc timestamps in the logs: https://git.fedorahosted.org/cgit/sanlock.git/commit/?id=fa70eff67e327b181e3d006a3381ae8e32822084 David, I think we can move this bug to modified.
This is a fedora bug, so the bz state isn't very relevant, just closing instead.
This bug appears to have been reported against 'rawhide' during the Fedora 27 development cycle. Changing version to '27'.
This message is a reminder that Fedora 27 is nearing its end of life. On 2018-Nov-30 Fedora will stop maintaining and issuing updates for Fedora 27. It is Fedora's policy to close all bug reports from releases that are no longer maintained. At that time this bug will be closed as EOL if it remains open with a Fedora 'version' of '27'. Package Maintainer: If you wish for this bug to remain open because you plan to fix it in a currently maintained version, simply change the 'version' to a later Fedora version. Thank you for reporting this issue and we are sorry that we were not able to fix it before Fedora 27 is end of life. If you would still like to see this bug fixed and are able to reproduce it against a later version of Fedora, you are encouraged change the 'version' to a later Fedora version prior this bug is closed as described in the policy above. Although we aim to fix as many bugs as possible during every release's lifetime, sometimes those efforts are overtaken by events. Often a more recent Fedora release includes newer upstream software that fixes bugs or makes them obsolete.
Fedora 27 changed to end-of-life (EOL) status on 2018-11-30. Fedora 27 is no longer maintained, which means that it will not receive any further security or bug fix updates. As a result we are closing this bug. If you can reproduce this bug against a currently maintained version of Fedora please feel free to reopen this bug against that version. If you are unable to reopen this bug, please file a new report against the current release. If you experience problems, please add a comment to this bug. Thank you for reporting this bug and we are sorry it could not be fixed.