-
Bug
-
Resolution: Unresolved
-
Medium
-
None
-
None
-
None
-
3
-
9223372036854775807
sanity test_413k "QoS mkdir exclude prefixes" fails intermittently with:
sanity test_413k: @@@@@@ FAIL: d413k.sanity on MDT1, _temporary on MDT2
It passes on a fresh mount, but fails on every later run on the same client once test_413l has run, e.g. repeating ONLY="413k 413l" sanity.sh without remounting gives PASS, FAIL, FAIL.
Root cause: test_413k/413l save the exclude list with lctl get_param -n lmv..qos_exclude_patterns, which prints one pattern per line, and restore it with lctl set_param. The write handler in lproc_lmv.c only splits on ':', so the restore stores "_temporary<newline>_temporary." as one pattern that matches nothing, and _temporary is no longer excluded. The same happens with echo name > qos_exclude_patterns, which stores "name\n". Since the bogus entry ends in ".*", qos_exclude_prefixes then reads back empty, 413k saves an empty list, and lctl rejects the empty value on restore, so 413k also leaks its "abc", "123" and "foo bar" prefixes on each failed run.
With two mounts on a client, lmv.* matches both LMV devices, so a saved list contains every pattern twice and each restore doubles the list on both devices.
Fix:
- treat newline as a pattern separator like ':'
- clear the list on a write with no names and no '+'/'-' (e.g. echo > file)
- skip adding a pattern that is already in the list
- make sanity test_413k/413l save and restore the full qos_exclude_patterns list as a ':'-joined value
- add sanityn test_125 to check duplicate handling with two mounts
- is related to
-
LU-19268 Replace qos_exclude_prefixes with qos_exclude_patterns
-
- Resolved
-