Bugzilla will be upgraded to version 5.0. The upgrade date is tentatively scheduled for 2 December 2018, pending final testing and feedback.
Bug 1455771 - [downstream clone - 4.1.3] [RFE] Log collector should collect time diff for all hosts
[downstream clone - 4.1.3] [RFE] Log collector should collect time diff for a...
Status: CLOSED ERRATA
Product: Red Hat Enterprise Virtualization Manager
Classification: Red Hat
Component: ovirt-log-collector (Show other bugs)
4.0.6
All Linux
unspecified Severity medium
: ovirt-4.1.3
: ---
Assigned To: Sandro Bonazzola
Aleksei Slaikovskii
: FutureFeature, ZStream
Depends On: 1404509
Blocks: 1455781 1487037
  Show dependency treegraph
 
Reported: 2017-05-26 01:48 EDT by rhev-integ
Modified: 2017-08-31 02:18 EDT (History)
9 users (show)

See Also:
Fixed In Version: ovirt-log-collector-4.1.2-1.el7ev
Doc Type: Enhancement
Doc Text:
When collecting SOS reports from hosts, chrony and systemd SOS plugins can collect information about time synchronization. In addition, a new option --time-only has been added to ovirt-log-collector allowing information about time differences to be gathered from the hosts without gathering full SOS reports, saving a considerable amount of time for the operation.
Story Points: ---
Clone Of: 1404509
Environment:
Last Closed: 2017-07-06 03:31:59 EDT
Type: ---
Regression: ---
Mount Type: ---
Documentation: ---
CRM:
Verified Versions:
Category: ---
oVirt Team: Integration
RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---
lsvaty: testing_plan_complete-


Attachments (Terms of Use)


External Trackers
Tracker ID Priority Status Summary Last Updated
oVirt gerrit 77244 master MERGED sos: add time report plugin 2017-05-26 01:49 EDT
oVirt gerrit 77259 master MERGED core: added --time-only option 2017-05-26 01:49 EDT
oVirt gerrit 77380 ovirt-log-collector-4.1 MERGED sos: add time report plugin 2017-05-26 02:16 EDT
oVirt gerrit 77381 ovirt-log-collector-4.1 POST core: added --time-only option 2017-05-26 01:55 EDT
Red Hat Product Errata RHEA-2017:1695 normal SHIPPED_LIVE ovirt-log-collector enhancement update 2017-07-06 07:24:57 EDT

  None (edit)
Description rhev-integ 2017-05-26 01:48:54 EDT
+++ This bug is a downstream clone. The original bug is: +++
+++   bug 1404509 +++
======================================================================

## Description of problem:

It would be great if Log Collector checked the time diff for all hosts, regardless of how many hosts (sosreport) are selected.

## Version-Release number of selected component (if applicable):

ovirt-log-collector-4.0.1-1.el7ev.noarch

## How reproducible:

always

## Steps to Reproduce:

1. generate Log Collector
2. don't specify any hosts (or only specify one, etc)

## Actual results:

time_diff.txt only collects info for hosts that are specified

## Expected results:

collect time diff info for all hosts

## Additional info:

Sometimes when troubleshooting issues, we get LC ouput without any host info, then get sosreports separately.  More commmon, if we are troublehsooting a migration issue, we only get the destination host but not the source (so we can't check that both are in sync)

It would be very useful if we could include this info (time diff for all hosts) so that we can easily 'tick off' out-of-sync hosts as a cause for various problems.

Alternative - provide some easy way for the customer (or Support) to verify all hosts are in sync.  I've been getting customers to run: (one line)

for i in `cat hosts.txt`; do echo $i; ssh -i /etc/pki/ovirt-engine/keys/engine_id_rsa root@${i} 'date --iso-8601=seconds'; date --iso-8601=seconds; done


Where 'hosts.txt' is a list of hosts (from 'ovirt-log-collector list')  Is there a better way to see at a glance if all hosts are in sync?

(Originally by Marcus West)
Comment 3 rhev-integ 2017-05-26 01:49:06 EDT
A possible way to do

(Originally by Sandro Bonazzola)
Comment 4 rhev-integ 2017-05-26 01:49:11 EDT
A possible way to do a check against time drift is to leverage ntpq or chronyc commands. Need to check if sos already collect this kind of data.

(Originally by Sandro Bonazzola)
Comment 5 rhev-integ 2017-05-26 01:49:15 EDT
The systemd sos plugin provides the output from timedatectl:

$ timedatectl 
      Local time: mer 2017-05-24 13:35:46 CEST
  Universal time: mer 2017-05-24 11:35:46 UTC
        RTC time: mer 2017-05-24 11:35:46
       Time zone: Europe/Rome (CEST, +0200)
 Network time on: yes
NTP synchronized: yes
 RTC in local TZ: no


and the chrony plugin provides time drift:

# cat chronyc_sources
210 Number of sources = 4
MS Name/IP address         Stratum Poll Reach LastRx Last sample               
===============================================================================
^? blue.1e400.net                0   9     0     -     +0ns[   +0ns] +/-    0ns
^* ntp-2.arkena.net              2   7   355   813  -2808us[-4156us] +/-   41ms
^? server1.websters-compute>     2   9     4   21m    +13ms[  +12ms] +/-   50ms
^+ iris.linocomm.net             2   7   377    39  -9300us[-9300us] +/-   78ms

# cat chronyc_tracking
Reference ID    : 5F51AD4A (ntp-2.arkena.net)
Stratum         : 3
Ref time (UTC)  : Wed May 24 11:18:51 2017
System time     : 0.000000059 seconds fast of NTP time
Last offset     : -0.001348147 seconds
RMS offset      : 0.000891597 seconds
Frequency       : 9.894 ppm fast
Residual freq   : -0.298 ppm
Skew            : 2.514 ppm
Root delay      : 0.050097819 seconds
Root dispersion : 0.018574700 seconds
Update interval : 518.1 seconds
Leap status     : Normal

(Originally by Sandro Bonazzola)
Comment 6 rhev-integ 2017-05-26 01:49:19 EDT
Also added --time-only option to skip sos collection from specified hosts, in particular, from all known hosts

(Originally by Sandro Bonazzola)
Comment 10 Aleksei Slaikovskii 2017-06-13 05:38:52 EDT
Verified on ovirt-log-collector-4.1.3-1.el7ev.noarch
Comment 12 errata-xmlrpc 2017-07-06 03:31:59 EDT
Since the problem described in this bug report should be
resolved in a recent advisory, it has been closed with a
resolution of ERRATA.

For information on the advisory, and where to find the updated
files, follow the link below.

If the solution does not work for you, open a new bug report.

https://access.redhat.com/errata/RHEA-2017:1695

Note You need to log in before you can comment on or make changes to this bug.