Hide Forgot
Description of problem: Currently VDSM and ovirt-engine uses the system time in each log prints. To align with common logging we need to replace the current format to use UTC.
This needs to happen on both sides in the same release, not just vdsm
We must have localtime timestamp in vdsm to debug system related issues. This will not happen before /var/log/messages and /var/log/sanlock switch to UTC. The only way to get UTC timestamps now is to set the system timezone to UTC, this will automatically fix all logs on the system to use the same timezone.
(In reply to Nir Soffer from comment #2) > We must have localtime timestamp in vdsm to debug system related issues. > > This will not happen before /var/log/messages and /var/log/sanlock switch to > UTC. journalctl can show in UTC (or not). If sanlock logs need to be fixed, we can file a bug on sanlock as well. > > The only way to get UTC timestamps now is to set the system timezone to UTC, > this > will automatically fix all logs on the system to use the same timezone. libvirt already uses UTC as well, I believe.
Peter, do you know if syslog utc support (https://github.com/rsyslog/rsyslog/issues/730) is available in Fedora/RHEL?
(In reply to Yaniv Kaul from comment #3) > (In reply to Nir Soffer from comment #2) > > We must have localtime timestamp in vdsm to debug system related issues. > > > > This will not happen before /var/log/messages and /var/log/sanlock switch to > > UTC. > > journalctl can show in UTC (or not). Being able to provide UTC logs from journalctl is not the same as having UTC logs in /var/log/messages. This increase the chance to get useable logs from users. > If sanlock logs need to be fixed, we > can file a bug on sanlock as well. I opened bug 1390867 for this.
(In reply to Michal Skrivanek from comment #1) > This needs to happen on both sides in the same release, not just vdsm There is already another RFE for the engine.
(In reply to Oved Ourfali from comment #6) > (In reply to Michal Skrivanek from comment #1) > > This needs to happen on both sides in the same release, not just vdsm > > There is already another RFE for the engine. Interestingly it was not in the whine until today. Strange...
Well, I asked Martin to open it this week.... So apparently he did :-)
Additional log files that must match vdsm timestamps: - /var/log/glusterfs/ - /var/log/openvswitch/ Sahina, can we configure glusterfs to use UTC timestamps in the logs?
(In reply to Nir Soffer from comment #9) > Additional log files that must match vdsm timestamps: > - /var/log/glusterfs/ > - /var/log/openvswitch/ > > Sahina, can we configure glusterfs to use UTC timestamps in the logs? AFAIK, glusterfs already uses UTC timestamps in logs. Adding Krutika to confirm
(In reply to Sahina Bose from comment #10) > (In reply to Nir Soffer from comment #9) > > Additional log files that must match vdsm timestamps: > > - /var/log/glusterfs/ > > - /var/log/openvswitch/ > > > > Sahina, can we configure glusterfs to use UTC timestamps in the logs? > > AFAIK, glusterfs already uses UTC timestamps in logs. Adding Krutika to > confirm Yes, that is correct Sahina. -Krutika
It is not clear to me that all timestamps emitted have to be in UTC, but they do have to include accurate timezone information. For the last supported Fedora releases, I don't think rsyslog is installed by default, and so there is no /var/log/messages file. If the user optionally installs rsyslog I believe they still get v7 (though hopefully v8 will make its way there soon if it has not already). For v7, switching to use the RSYSLOG_FileFormat (sp?) template as the default instead of RSYSLOG_TraditionalFileFormat (sp?) should provide the proper timezone information in the logs. Why are we not just requiring that the systems run in UTC? There is no reason to run any system in another timezone besides UTC (we assert).
Moving to 4.2 as we will not be able to change logging time zone in 4.1
the vdsm part is handled in bug #1408190
(In reply to Yaniv Bronhaim from comment #14) > the vdsm part is handled in bug #1408190 This is not the same thing: BZ1408190 adds local time zone to log records, but this bug is about setting time zone of log records to UTC even though local system time zone is different.
(In reply to Yaniv Kaul from comment #3) > (In reply to Nir Soffer from comment #2) > > We must have localtime timestamp in vdsm to debug system related issues. > > > > This will not happen before /var/log/messages and /var/log/sanlock switch to > > UTC. > > journalctl can show in UTC (or not). If sanlock logs need to be fixed, we > can file a bug on sanlock as well. Sanlock can be configured to use UTC.