Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
7 changes: 6 additions & 1 deletion src/control/lib/control/system.go
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
//
// (C) Copyright 2020-2024 Intel Corporation.
// (C) Copyright 2025 Hewlett Packard Enterprise Development LP
// (C) Copyright 2025-2026 Hewlett Packard Enterprise Development LP
//
// SPDX-License-Identifier: BSD-2-Clause-Patent
//
Expand Down Expand Up @@ -1318,6 +1318,7 @@ func SystemRebuildManage(ctx context.Context, rpcClient UnaryInvoker, req *Syste
type SystemSelfHealEvalReq struct {
unaryRequest
msRequest
retryableRequest
}

// SystemSelfHealEvalResp contains the response.
Expand All @@ -1341,6 +1342,10 @@ func SystemSelfHealEval(ctx context.Context, rpcClient UnaryInvoker, req *System
req.setRPC(func(ctx context.Context, conn *grpc.ClientConn) (proto.Message, error) {
return mgmtpb.NewMgmtSvcClient(conn).SystemSelfHealEval(ctx, pbReq)
})
req.retryTestFn = func(err error, _ uint) bool {
return (system.IsUnavailable(err) || IsRetryableConnErr(err) ||
system.IsNotLeader(err) || system.IsNotReplica(err))
}

rpcClient.Debugf("DAOS system self-heal eval request: %s", pbUtil.Debug(pbReq))
ur, err := rpcClient.InvokeUnaryRPC(ctx, req)
Expand Down
10 changes: 7 additions & 3 deletions src/control/system/errors.go
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
//
// (C) Copyright 2020-2024 Intel Corporation.
// (C) Copyright 2025 Hewlett Packard Enterprise Development LP
// (C) Copyright 2025-2026 Hewlett Packard Enterprise Development LP
//
// SPDX-License-Identifier: BSD-2-Clause-Patent
//
Expand All @@ -17,6 +17,8 @@ import (
"github.com/pkg/errors"

"github.com/daos-stack/daos/src/control/build"
"github.com/daos-stack/daos/src/control/fault"
"github.com/daos-stack/daos/src/control/fault/code"
"github.com/daos-stack/daos/src/control/lib/ranklist"
)

Expand All @@ -39,8 +41,10 @@ func IsUnavailable(err error) bool {
if err == nil {
return false
}
cause := errors.Cause(err).Error()
return strings.Contains(cause, ErrRaftUnavail.Error()) || strings.Contains(cause, ErrLeaderStepUpInProgress.Error())
cause := errors.Cause(err)
return strings.Contains(cause.Error(), ErrRaftUnavail.Error()) ||
strings.Contains(cause.Error(), ErrLeaderStepUpInProgress.Error()) ||
fault.IsFaultCode(cause, code.ServerDataPlaneNotStarted)
}

// IsEmptyGroupMap returns a boolean indicating whether or not the
Expand Down
Loading