Bug 577868

Summary: spacewalk-remove-channel unhandled exception parsing /etc/rhn/rhn.conf
Product: Red Hat Satellite 5 Reporter: Vishal Gaikwad <vgaikwad>
Component: ServerAssignee: Justin Sherrill <jsherril>
Status: CLOSED CURRENTRELEASE QA Contact: Martin Minar <mminar>
Severity: medium Docs Contact:
Priority: medium    
Version: 530CC: cperry, mkoci, mminar, msuchy
Target Milestone: ---   
Target Release: ---   
Hardware: All   
OS: Linux   
Whiteboard:
Fixed In Version: Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2010-10-28 14:55:38 UTC Type: ---
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:
Bug Depends On:    
Bug Blocks: 487678    

Comment 1 Vishal Gaikwad 2010-03-29 14:22:38 UTC
Here's what we have till now:

> /usr/share/rhn/common/rhnConfig.py(559)parse_file()
-> lineno = lineno + 1

(Pdb) print line
com.redhat.rhn.taskomatic.task.DailySummary,\

(Pdb) n
> /usr/share/rhn/common/rhnConfig.py(560)parse_file()
-> try:

(Pdb)
> /usr/share/rhn/common/rhnConfig.py(561)parse_file()
-> (keys, values) = parse_line(line)

(Pdb)
ValueError: 'unpack list of wrong size'
> /usr/share/rhn/common/rhnConfig.py(561)parse_file()
-> (keys, values) = parse_line(line)

(Pdb) print line
com.redhat.rhn.taskomatic.task.DailySummary,\

(Pdb) n
> /usr/share/rhn/common/rhnConfig.py(562)parse_file()
-> except:

(Pdb) n
> /usr/share/rhn/common/rhnConfig.py(563)parse_file()
-> raise ConfigParserError("Parse Error: <%s:%s>: '%s'" % (

(Pdb) n
ConfigParserError: <common.rhnConfig.ConfigParserError instance at 0xb7ae550c>
> /usr/share/rhn/common/rhnConfig.py(563)parse_file()
-> raise ConfigParserError("Parse Error: <%s:%s>: '%s'" % (

Basically, parse_line() is expected to return 'keys' and 'value' pairs and the distinction happens on the '=' character in the 'line' this fails if you have a continuation character '\' in the /etc/rhn/rhn.conf file.

I'm still working on the patch, I think the way to handle this would be to parse /etc/rhn/rhn.conf file and check the existence of '\' and '\n' (new line) at the end of every line, if found then replace that with a space " ".

Comment 2 Justin Sherrill 2010-07-27 17:40:55 UTC
Should be fixed now in spacewalk master:

10bbbabc430fafa7ab94312baa31ede559796808

Comment 4 Miroslav Suchý 2010-10-19 10:48:31 UTC
verified in stage

Comment 5 Clifford Perry 2010-10-28 14:50:47 UTC
The 5.4.0 RHN Satellite and RHN Proxy release has occurred. This issue has been resolved with this release. 


RHEA-2010:0801 - RHN Satellite Server 5.4.0 Upgrade
https://rhn.redhat.com/rhn/errata/details/Details.do?eid=10332

RHEA-2010:0803 - RHN Tools enhancement update
https://rhn.redhat.com/rhn/errata/details/Details.do?eid=10333

RHEA-2010:0802 - RHN Proxy Server 5.4.0 bug fix update
https://rhn.redhat.com/rhn/errata/details/Details.do?eid=10334

RHEA-2010:0800 - RHN Satellite Server 5.4.0
https://rhn.redhat.com/rhn/errata/details/Details.do?eid=10335

Docs are available:

http://docs.redhat.com/docs/en-US/Red_Hat_Network_Satellite/index.html 

Regards,
Clifford