Bug 1657192

Summary: augeas cannot parse /etc/sysconfig/anaconda
Product: Red Hat Enterprise Linux 8 Reporter: Pino Toscano <ptoscano>
Component: augeasAssignee: Libvirt Maintainers <libvirt-maint>
Status: CLOSED CURRENTRELEASE QA Contact: YongkuiGuo <yoguo>
Severity: unspecified Docs Contact:
Priority: unspecified    
Version: 8.0CC: linl, ptoscano, rjones, virt-bugs, xchen, yoguo
Target Milestone: rc   
Target Release: 8.0   
Hardware: Unspecified   
OS: Unspecified   
Whiteboard:
Fixed In Version: augeas-1.10.1-7.el8 Doc Type: If docs needed, set a value
Doc Text:
Story Points: ---
Clone Of: 1657189 Environment:
Last Closed: 2019-06-14 02:01:34 UTC Type: Bug
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:

Description Pino Toscano 2018-12-07 11:58:31 UTC
+++ This bug was initially created as a clone of Bug #1657189 +++

Description of problem:
augeas cannot parse the Anaconda user interaction configuration file /etc/sysconfig/anaconda.

Version-Release number of selected component (if applicable):
augeas-libs-1.10.1-6.el8.x86_64
augeas-1.10.1-6.el8.x86_64

Steps to Reproduce:
1. install RHEL using Anaconda (manual or automated installation)
2. check that /etc/sysconfig/anaconda is present in the system
3. augtool print /augeas//error | grep anaconda
4. augtool print /files/etc/sysconfig/anaconda/

Actual results:
- step #3 prints (error position depends on the actual file):
/augeas/files/etc/sysconfig/anaconda/error = "parse_failed"
/augeas/files/etc/sysconfig/anaconda/error/pos = "73"
/augeas/files/etc/sysconfig/anaconda/error/line = "3"
/augeas/files/etc/sysconfig/anaconda/error/char = "0"
/augeas/files/etc/sysconfig/anaconda/error/lens = "/usr/share/augeas/lenses/dist/shellvars.aug:194.12-.60:"
/augeas/files/etc/sysconfig/anaconda/error/message = "Syntax error"
- step #4 prints nothing

Expected results:
- step #3 prints nothing
- step #4 prints the parsed tree, for example:
/files/etc/sysconfig/anaconda
/files/etc/sysconfig/anaconda/#comment = "This file has been generated by the Anaconda Installer 21.48.22.147-1"
/files/etc/sysconfig/anaconda/ProgressSpoke
/files/etc/sysconfig/anaconda/ProgressSpoke/visited = "1"

Comment 2 YongkuiGuo 2018-12-13 01:46:30 UTC
Verified with package:
augeas-1.10.1-7.el8.x86_64

Steps:

1. 
# augtool print /files/etc/sysconfig/anaconda/
/files/etc/sysconfig/anaconda
/files/etc/sysconfig/anaconda/#comment = "This file has been generated by the Anaconda Installer 29.19.0.23"
/files/etc/sysconfig/anaconda/General
/files/etc/sysconfig/anaconda/General/post_install_tools_disabled = "1"

2.
# augtool print /augeas//error | grep anaconda
The command above prints nothing.

So verified it.