Bug 1302017 - augeas chrony lens fails to parse negative values
augeas chrony lens fails to parse negative values
Status: CLOSED ERRATA
Product: Red Hat Enterprise Linux 7
Classification: Red Hat
Component: augeas (Show other bugs)
7.2
Unspecified Unspecified
unspecified Severity unspecified
: rc
: ---
Assigned To: Pino Toscano
Virtualization Bugs
https://github.com/hercules-team/auge...
:
Depends On:
Blocks: 1301891
  Show dependency treegraph
 
Reported: 2016-01-26 09:25 EST by Michal Wasilewski
Modified: 2018-04-10 05:56 EDT (History)
3 users (show)

See Also:
Fixed In Version: augeas-1.4.0-4.el7
Doc Type: Bug Fix
Doc Text:
Prior to this update, Augeas was not able to read negative values in the configuration of the chrony daemon (/etc/chrony.conf). The chrony lens of Augeas has been fixed to parse also negative values. As a result, Augeas now reads /etc/chrony.conf even with negative values of options.
Story Points: ---
Clone Of:
Environment:
Last Closed: 2018-04-10 05:55:26 EDT
Type: Bug
Regression: ---
Mount Type: ---
Documentation: ---
CRM:
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---


Attachments (Terms of Use)


External Trackers
Tracker ID Priority Status Summary Last Updated
Red Hat Product Errata RHBA-2018:0684 None None None 2018-04-10 05:56 EDT

  None (edit)
Description Michal Wasilewski 2016-01-26 09:25:16 EST
Description of problem:
augeas contains a lens for chrony.conf that will fail to parse negative values for makestep. This is fixed here: https://github.com/hercules-team/augeas/commit/664f8a8d690f3cfac2d3a8b44834d809e15b51ed
The bug is to, if possible, backport it

Version-Release number of selected component (if applicable):
1.4.0-2.el7

How reproducible:


Steps to Reproduce:
1. change chrony.conf from 'makestep 10 3' to 'makestep 10 -1'
2. run augtool, print /files/etc/chrony.conf
3.

Actual results:
augeas fails to parse the config file

Expected results:
should parse the config file with negative values

Additional info:
Comment 3 YongkuiGuo 2017-09-29 02:07:24 EDT
Verified with packages:
augeas-1.4.0-4.el7.x86_64
libguestfs-1.36.3-6.el7_4.3.x86_64

Steps:

1. Modified the makestep line with negative value in /etc/chrony.conf as follows:
   "makestep 1.0 -3"

2. #augtool
augtool> print /files/etc/chrony.conf
--------------------------------------------------------------
/files/etc/chrony.conf
/files/etc/chrony.conf/#comment[1] = "These servers were defined in the installation:"
/files/etc/chrony.conf/server[1] = "ns1.nay.redhat.com"
/files/etc/chrony.conf/server[1]/iburst
/files/etc/chrony.conf/server[2] = "clock01.util.phx2.redhat.com"
/files/etc/chrony.conf/server[2]/iburst
/files/etc/chrony.conf/server[3] = "lanczos.maths.tcd.ie"
/files/etc/chrony.conf/server[3]/iburst
/files/etc/chrony.conf/#comment[2] = "Use public servers from the pool.ntp.org project."
/files/etc/chrony.conf/#comment[3] = "Please consider joining the pool (http://www.pool.ntp.org/join.html)."
/files/etc/chrony.conf/#comment[4] = "Record the rate at which the system clock gains/losses time."
/files/etc/chrony.conf/driftfile = "/var/lib/chrony/drift"
/files/etc/chrony.conf/#comment[5] = "Allow the system clock to be stepped in the first three updates"
/files/etc/chrony.conf/#comment[6] = "if its offset is larger than 1 second."
/files/etc/chrony.conf/makestep
/files/etc/chrony.conf/makestep/threshold = "1.0"
/files/etc/chrony.conf/makestep/limit = "-3"
...
--------------------------------------------------------------
So augeas can parse /etc/chrony.conf correctly. Verified this bug.
Comment 6 errata-xmlrpc 2018-04-10 05:55:26 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/RHBA-2018:0684

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