Time measurement in telemetry can be negative
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
ubiquity (Ubuntu) |
Fix Released
|
High
|
Didier Roche-Tolomelli | ||
Bionic |
Fix Released
|
High
|
Didier Roche-Tolomelli |
Bug Description
[Impact]
* Telemetry was relaying on time.time() to report duration of installation and various step. This system clock though can be reset by the installer, loading to negative time report.
[Test Case]
* Start an 18.04 live session and install ubiquity
* Start ubiquity
* Change the timezone to one "in the past" compared to your location
* Complete the installation and close ubiquity without rebooting the session
* Check that no values of the "Stages" hashmap in /target/
[Regression Potential]
* We are using /proc/upstime as a reference and it's not affected by the system clock.
* The worst case is that we still report negative telemetry data for time.
-----
time.time() is sensitive to system clock change after NTP sync.
We should rather use /proc/uptime as a reference and test it's not affected by system clock (it shouldn't).
Related branches
- Jean-Baptiste Lallement: Approve
-
Diff: 62 lines (+24/-3)2 files modifieddebian/changelog (+8/-0)
ubiquity/telemetry.py (+16/-3)
- Jean-Baptiste Lallement: Approve
-
Diff: 62 lines (+24/-3)2 files modifieddebian/changelog (+8/-0)
ubiquity/telemetry.py (+16/-3)
tags: | added: rls-bb-incoming |
Changed in ubiquity (Ubuntu): | |
importance: | Undecided → High |
status: | New → Triaged |
milestone: | none → ubuntu-18.04.1 |
Changed in ubiquity (Ubuntu Bionic): | |
status: | New → Triaged |
importance: | Undecided → High |
milestone: | none → ubuntu-18.04.1 |
Changed in ubiquity (Ubuntu): | |
milestone: | ubuntu-18.04.1 → none |
description: | updated |
Changed in ubiquity (Ubuntu): | |
assignee: | nobody → Didier Roche (didrocks) |
Changed in ubiquity (Ubuntu Bionic): | |
assignee: | nobody → Didier Roche (didrocks) |
This bug was fixed in the package ubiquity - 18.10.3
---------------
ubiquity (18.10.3) cosmic; urgency=medium
* Don't record telemetry data when doing stage 2 (user mode) as it keeps an
unused /target directory (LP: #1773321) Also, record OEM types
(LP: #1765693)
* Switch to use uptime instead of time.time() which is sensitive to
BIOS time reset after NTP sync, leading to negative values.
(LP: #1771966)
* Ignore .git file from built package and remove .bzr artefacts
* update manifest
-- Didier Roche <email address hidden> Mon, 28 May 2018 16:02:33 +0200