Project

General

Profile

Bug #11066

zfs clean_mirror tests should scrub between tests

Added by Kody Kantor 7 months ago. Updated 7 months ago.

Status:
Closed
Priority:
Normal
Assignee:
Category:
tests
Start date:
2019-05-23
Due date:
% Done:

100%

Estimated time:
Difficulty:
Bite-size
Tags:
needs-triage

Description

The ZFS test suite clean_mirror tests are meant to test the ability for ZFS to maintain data durability in the face of losing one side of a mirrored vdev. When we added the 'zpool sync' command some old functionality was removed that would scrub the test pool between each test. Scrubbing the pool between tests is a necessary step, otherwise the tests simulate losing both sides of a mirror (which ZFS can't survive).

History

#1

Updated by Kody Kantor 7 months ago

This is what it looks like when we run these tests today:

root@dew:/opt/zfs-tests# ./bin/zfstest -c ./kkantor.run
Test: /opt/zfs-tests/tests/functional/clean_mirror/setup (run as root) [00:00] [PASS]
Test: /opt/zfs-tests/tests/functional/clean_mirror/clean_mirror_001_pos (run as root) [00:06] [PASS]
Test: /opt/zfs-tests/tests/functional/clean_mirror/clean_mirror_002_pos (run as root) [00:04] [FAIL]
Test: /opt/zfs-tests/tests/functional/clean_mirror/clean_mirror_003_pos (run as root) [00:03] [FAIL]
Test: /opt/zfs-tests/tests/functional/clean_mirror/clean_mirror_004_pos (run as root) [00:03] [FAIL]
Test: /opt/zfs-tests/tests/functional/clean_mirror/cleanup (run as root) [00:00] [PASS]

Results Summary
FAIL 3
PASS 3

Running Time: 00:00:19
Percent passed: 50.0%
Log directory: /var/tmp/test_results/20190523T154120

And subsequent runs fail because the tests don't clean up the /var/tmp/testdir directory:

root@dew:/opt/zfs-tests# ./bin/zfstest -c ./kkantor.run
Test: /opt/zfs-tests/tests/functional/clean_mirror/setup (run as root) [00:00] [FAIL]
Test: /opt/zfs-tests/tests/functional/clean_mirror/clean_mirror_001_pos (run as root) [00:00] [SKIP]
Test: /opt/zfs-tests/tests/functional/clean_mirror/clean_mirror_002_pos (run as root) [00:00] [SKIP]
Test: /opt/zfs-tests/tests/functional/clean_mirror/clean_mirror_003_pos (run as root) [00:00] [SKIP]
Test: /opt/zfs-tests/tests/functional/clean_mirror/clean_mirror_004_pos (run as root) [00:00] [SKIP]
Test: /opt/zfs-tests/tests/functional/clean_mirror/cleanup (run as root) [00:00] [PASS]

Results Summary
FAIL 1
SKIP 4
PASS 1

Running Time: 00:00:01
Percent passed: 16.7%
Log directory: /var/tmp/test_results/20190523T154147

#2

Updated by Electric Monk 7 months ago

  • Status changed from New to Closed
  • % Done changed from 0 to 100

git commit 7811b028df2f34164be65174d666b570b73d32c3

commit  7811b028df2f34164be65174d666b570b73d32c3
Author: Kody Kantor <kody@kkantor.com>
Date:   2019-05-24T16:55:12.000Z

    11066 zfs clean_mirror tests should scrub between tests
    Reviewed by: Toomas Soome <tsoome@me.com>
    Reviewed by: Jerry Jelinek <jerry.jelinek@joyent.com>
    Approved by: Gordon Ross <gwr@nexenta.com>

Also available in: Atom PDF