Bug 460973

Summary: cdrom test fails on written media comparison
Product: [Retired] Red Hat Hardware Certification Program Reporter: Greg Nichols <gnichols>
Component: Test Suite (tests)Assignee: Greg Nichols <gnichols>
Status: CLOSED ERRATA QA Contact: Lawrence Lim <llim>
Severity: medium Docs Contact:
Priority: medium    
Version: 5.2CC: gnichols, ndai, rlandry, tools-bugs, ykun
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: 2008-11-12 19:24:35 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:
Attachments:
Description Flags
cdrom.py patch to re-try mount command
none
cdrom.py patch to re-try mount command - 2nd attempt none

Description Greg Nichols 2008-09-03 03:04:37 UTC
Description of problem:

The cdrom test fails due to problems arising from mount failures
when trying to mount the cdrom to verify it was written correctly.

Example run log:
[...]
Please close the drive tray of /dev/sr0 manually then press ENTER to continue.
 Start to compare data, this may take some time, please be patient ...
Traceback (most recent call last):
 File "./cdrom.py", line 761, in <module>
   returnValue = test.do(sys.argv)
 File "/usr/share/hts/lib/hts/test.py", line 226, in do
   return self.run()
 File "./cdrom.py", line 668, in run
   returnValue = self.testCDRW(cdromDevice)
 File "./cdrom.py", line 527, in testCDRW
   returnValue = self.rewriter("cdrom",cdromDevice)
 File "./cdrom.py", line 463, in rewriter
   returnValue = self.writer(deviceType,cdromDevice)
 File "./cdrom.py", line 429, in writer
   if self.cmpTree(fileDir,"media"):
 File "./cdrom.py", line 99, in cmpTree
   if filecmp.cmp(file1,file2):
 File "/usr/lib/python2.5/filecmp.py", line 44, in cmp
   s2 = _sig(os.stat(f2))
OSError: [Errno 2] No such file or directory: 'media/chcat'
...finished running ./cdrom.py, exit code=1
recovered exit code=1
hts-report-result /HTS/hts/cdrom FAIL /var/log/hts/runs/3/cdrom/output.log
saveOutput: /var/log/hts/runs/3/cdrom/output.log
Return value was 0 


Version-Release number of selected component (if applicable):

HTS 5.2 R19

How reproducible:

Always on T42 running Fedora 8

Comment 1 Greg Nichols 2008-09-03 03:06:12 UTC
Created attachment 315614 [details]
cdrom.py patch to re-try mount command

Comment 2 Greg Nichols 2008-09-03 03:07:51 UTC
The above patch will re-try the mount command when it fails (10 tries, 5 sec wait per try).   The patch also separates the comparison code as a separate "compare" function.

Comment 3 Greg Nichols 2008-09-03 17:54:31 UTC
Created attachment 315669 [details]
cdrom.py patch to re-try mount command - 2nd attempt

Comment 4 YangKun 2008-09-04 06:06:05 UTC
what's the purpose to re-try mount for several times ? If the first mount fails, then there must be something wrong(either hardware or software failure) and should be fixed.

Comment 11 Nicole Dai 2008-10-15 09:11:45 UTC
Verified the problem was not found in hts-5.2-20.el5 and hts-5.2-20.el4 on RHEL 5 and 4.

Comment 13 errata-xmlrpc 2008-11-12 19:24:35 UTC
An advisory has been issued which should help the problem
described in this bug report. This report is therefore being
closed with a resolution of ERRATA. For more information
on therefore solution and/or where to find the updated files,
please follow the link below. You may reopen this bug report
if the solution does not work for you.

http://rhn.redhat.com/errata/RHBA-2008-0919.html