Skip to content

Commit

Permalink
DAOS-13047 chk: properly handle start options
Browse files Browse the repository at this point in the history
Test-tag-hw-medium: Pass1Test

The start options for new instance should properly overwrite old ones.
It also enhances CR pass 1 functionality tests:

1. Verify DAOS checker under dryrun mode.

2. Verify DAOS checker under auto mode.

3. Verify that the DAOS checker can detect and repair the inconsistency
   under regular mode.

4. Fix some typo for the test tags.

5. More accurate comment for test flow.

Signed-off-by: Fan Yong <[email protected]>
  • Loading branch information
Nasf-Fan committed May 26, 2023
1 parent 7eaf5d2 commit da1e1e1
Show file tree
Hide file tree
Showing 6 changed files with 160 additions and 152 deletions.
2 changes: 2 additions & 0 deletions src/chk/chk_common.c
Original file line number Diff line number Diff line change
Expand Up @@ -902,6 +902,8 @@ chk_prop_prepare(d_rank_t leader, uint32_t flags, int phase,
int i;

prop->cp_leader = leader;
if (!(flags & CHK__CHECK_FLAG__CF_DRYRUN))
prop->cp_flags &= ~CHK__CHECK_FLAG__CF_DRYRUN;
if (flags & CHK__CHECK_FLAG__CF_NO_FAILOUT)
prop->cp_flags &= ~CHK__CHECK_FLAG__CF_FAILOUT;
if (flags & CHK__CHECK_FLAG__CF_NO_AUTO)
Expand Down
4 changes: 2 additions & 2 deletions src/chk/chk_engine.c
Original file line number Diff line number Diff line change
Expand Up @@ -1972,8 +1972,8 @@ chk_engine_start_prep(struct chk_instance *ins, uint32_t rank_nr, d_rank_t *rank

init:
if (!chk_is_on_leader(gen, leader, true)) {
rc = chk_prop_prepare(leader, api_flags | prop->cp_flags, phase,
policy_nr, policies, rank_list, prop);
rc = chk_prop_prepare(leader, api_flags, phase, policy_nr, policies, rank_list,
prop);
if (rc != 0)
goto out;

Expand Down
3 changes: 1 addition & 2 deletions src/chk/chk_leader.c
Original file line number Diff line number Diff line change
Expand Up @@ -2334,8 +2334,7 @@ chk_leader_start_prep(struct chk_instance *ins, uint32_t rank_nr, d_rank_t *rank
cbk->cb_version = DAOS_CHK_VERSION;

init:
rc = chk_prop_prepare(leader, flags | prop->cp_flags, phase,
policy_nr, policies, rank_list, prop);
rc = chk_prop_prepare(leader, flags, phase, policy_nr, policies, rank_list, prop);
if (rc != 0)
goto out;

Expand Down
Loading

0 comments on commit da1e1e1

Please sign in to comment.