Bug 736675 - v7 storage test sets an improper I/O records
Summary: v7 storage test sets an improper I/O records
Keywords:
Status: CLOSED ERRATA
Alias: None
Product: Red Hat Hardware Certification Program
Classification: Red Hat
Component: Test Suite (tests)
Version: 6.1
Hardware: Unspecified
OS: Unspecified
unspecified
unspecified
Target Milestone: ---
: ---
Assignee: Greg Nichols
QA Contact: Caspar Zhang
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2011-09-08 12:02 UTC by WANG Chao
Modified: 2015-02-08 21:42 UTC (History)
8 users (show)

Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Clone Of:
Environment:
Last Closed: 2011-11-08 15:41:54 UTC


Attachments (Terms of Use)
patch fix (4.31 KB, patch)
2011-09-08 12:28 UTC, WANG Chao
no flags Details | Diff


Links
System ID Priority Status Summary Last Updated
Red Hat Product Errata RHBA-2011:1436 normal SHIPPED_LIVE v7 bug fix and enhancement update 2011-11-08 23:28:41 UTC

Description WANG Chao 2011-09-08 12:02:36 UTC
Description of problem:
After code review of /usr/share/v7/tests/storage/storage.py, I found that storage.py run dt with an static option 'records=X' and X is incorrectly static.
Here's the buggy code of storage.py, check line 113:
   110	    def dtTest(self, minBs, maxBs, file, size, otherOptions):
   111	        """Do a few passes of read/write testing on the given device."""
   112	        # Find out how many maxBs-sized blocks we can fit on the test file/dev
   113	        blocks = ((size/(maxBs/1024)))
'blocks' is the records that will give to dt as an option 'records=%d' % blocks.
And the records is static as line 113 wrote.I think records should be dynamically assigned as size*1024/bs.
If test size is set as 64k, as maxBs is 64k too, we will get blocks=1.Not matter what bs is set, it will write/read only 1 record, and can't cover all the test size.


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

How reproducible:
100%

Steps to Reproduce:
1.v7 run -t storage
2.Check dt print
3.
  
Actual results:
Every write operation has same records

Expected results:
Every write operation should have different records to cover the test size

Additional info:

Comment 1 WANG Chao 2011-09-08 12:28:48 UTC
Created attachment 522104 [details]
patch fix

This patch also fix:
bug 736638 , bug 736666 and bug 736679

Comment 4 Caspar Zhang 2011-10-21 14:35:46 UTC
The fix for this bug caused storage testing time abnormally long (see bug 739967) and I have withdrew the patch. Seems that we don't need to verify _every_ block of the device, the original code was just right.

So setting SanityOnly in the verified field, and no need to verify it. Also no TechNote is needed.

Comment 5 errata-xmlrpc 2011-11-08 15:41:54 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-2011-1436.html

Comment 6 errata-xmlrpc 2011-11-08 18:33:07 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-2011-1436.html


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