Bug 689470

Summary: CMSDASD broken by case-sensitive use
Product: Red Hat Enterprise Linux 5 Reporter: Philip Rowlands <phr>
Component: anacondaAssignee: David Cantrell <dcantrell>
Status: CLOSED ERRATA QA Contact: Release Test Team <release-test-team>
Severity: medium Docs Contact:
Priority: medium    
Version: 5.6CC: atodorov, brueckner, jstodola
Target Milestone: rc   
Target Release: ---   
Hardware: s390x   
OS: Linux   
Whiteboard:
Fixed In Version: anaconda-11.1.2.243-1 Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of: 681219 Environment:
Last Closed: 2012-02-21 05:37:23 UTC Type: ---
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Bug Depends On:    
Bug Blocks: 726828    

Description Philip Rowlands 2011-03-21 15:56:51 UTC
Steps to reproduce:
- Create parm file which includes CMSDASD parameter with uppercase hex, e.g. CMSDASD=2F1
- Punch and IPL the RHEL5.6 installation files
- Observe that the latter stages of /sbin/init:readcmsfile() fail to offline the device and rmmod dasd_eckd_mod and dasd_mod
- Specifically, the sysecho command uses the uppercase version whilst the /sys/bus/ccw/... path uses lowercase

Effect:
Returning from readcmsfile() without validating its final sysecho and rmmod commands leaves us in an undefined state. The correct operation of loader to insmod again, creating fresh /dev/dasd* devices defined by DASD= is broken. Ultimately loader fails to read the kickstart file specified by ks=hd:dasdb1:/path/to/kickstart.file and prompts the user.


Bug or feature?
I vote bug, given that the module itself and parse_dasd() functions in linuxrc.s390 take care to allow both uppercase and lowercase hex for dasd device addresses; because the documentation does not specify case-sensitivity; because uppercase DASD= addresses are acceptable within the CONF file.


Suggested fixes:
The comment in readcmsfile() would work ("more robust ... printf"), but I'd suggest lowercasing the address as soon as it's read in MAIN:#Parse configuration.

Also, test the return values of sysecho and rmmod; do not ignore errors. Test the return value of readcmsfile itself.

Also, make loader's rmmod more verbose on failure, like real rmmod. (This would have greatly helped in tracking down the problem.)

Comment 1 RHEL Program Management 2011-08-05 12:31:05 UTC
This request was evaluated by Red Hat Product Management for inclusion in a Red
Hat Enterprise Linux maintenance release.  Product Management has requested
further review of this request by Red Hat Engineering, for potential
inclusion in a Red Hat Enterprise Linux Update release for currently deployed
products.  This request is not yet committed for inclusion in an Update
release.

Comment 3 Jan Stodola 2012-01-10 14:28:43 UTC
Reproduced on RHEL-5.7, successfully verified on RHEL-5.8 Snapshot 3 with anaconda-11.1.2.250-1.s390x.

Moving to VERIFIED.

Comment 4 errata-xmlrpc 2012-02-21 05:37:23 UTC
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.

http://rhn.redhat.com/errata/RHBA-2012-0197.html