[LU-8603] improve metadata-updates.sh with sub-tests Created: 12/Sep/16 Updated: 19/Apr/17 Resolved: 19/Apr/17 |
|
| Status: | Resolved |
| Project: | Lustre |
| Component/s: | None |
| Affects Version/s: | Lustre 2.9.0 |
| Fix Version/s: | Lustre 2.10.0 |
| Type: | Bug | Priority: | Minor |
| Reporter: | Jian Yu | Assignee: | Saurabh Tandan (Inactive) |
| Resolution: | Fixed | Votes: | 0 |
| Labels: | None | ||
| Issue Links: |
|
||||||||
| Severity: | 3 | ||||||||
| Rank (Obsolete): | 9223372036854775807 | ||||||||
| Description |
|
Currently, there are no sub-tests in metadata-updates.sh, which causes test failure logs are not gathered with proper names that can be imported by Maloo. Such as: We need improve metadata-updates.sh to wrap the tests with test_x(). |
| Comments |
| Comment by Niu Yawei (Inactive) [ 14/Sep/16 ] |
|
Debug marker needs be made at the begining of each test case (operation), that'll be helpful for reading the debug log. For example: do_change_timestamps () {
echo "Changing atime, mtime ..."
do_nodes $NODES_TO_USE " set $TRACE;
TESTFILE=$TESTDIR/\\\$(hostname)/$FILE;
touch -c --date=\\\"$NEW_ATIME\\\" -a \\\$TESTFILE;
touch -c --date=\\\"$NEW_MTIME\\\" -m \\\$TESTFILE " || return ${PIPESTATUS[0]}
return 0
}
Besides this "echo", a debug marker will be helpful. |
| Comment by Gerrit Updater [ 20/Dec/16 ] |
|
James Nunez (james.a.nunez@intel.com) uploaded a new patch: https://review.whamcloud.com/24450 |
| Comment by James Nunez (Inactive) [ 21/Dec/16 ] |
|
Niu - The patch to break up the subtest of metadata-updates is failing with trevis-35vm1: /mnt/lustre/d0.metadata-updates/trevis-35vm1.trevis.hpdd.intel.com/testfile [ uid gid size mode ] expected : root root 0 0644 ; got : root root 0 0222 trevis-35vm1: Wrong file attributes trevis-35vm2: /mnt/lustre/d0.metadata-updates/trevis-35vm1.trevis.hpdd.intel.com/testfile [ uid gid size mode ] expected : root root 0 0644 ; got : root root 0 0222 trevis-35vm2: Wrong file attributes metadata-updates test_3: @@@@@@ FAIL: wrong attributes after truncate Logs are at https://testing.hpdd.intel.com/test_sets/21227fca-c7c7-11e6-9e78-5254006e85c2. Previously, the call to get_stat to check the file attributes after truncate was not a fatal error, but a "error_noexit". So, we never failed the test if the attributes were incorrect after truncate. Should we error out if the attributes are not correct or is there a reason to ignore the new attributes if they do not match what is expected? |
| Comment by Niu Yawei (Inactive) [ 22/Dec/16 ] |
|
The original script will update CURRENT_MODE (0644) to NEW_MODE (0222) in do_chmod() of 2nd test case, but looks it failed to update the value now when you moved them into sub tests. Another problem is that all test cases are depended each other, none of them can be executed individually (except the first one), so it doesn't make much sense to separate them into sub-tests. Rather than moving them into separate sub-tests, I think probably just use debug marker (lctl mark ...) to make the test cases distinguishable in debug log is good enough? (and replace most 'echo' with 'log' to make sure the important messages saved in test log). |
| Comment by Gerrit Updater [ 19/Apr/17 ] |
|
Oleg Drokin (oleg.drokin@intel.com) merged in patch https://review.whamcloud.com/24450/ |
| Comment by Peter Jones [ 19/Apr/17 ] |
|
Landed for 2.10 |