diff --git a/cmd/containerd-shim-runhcs-v1/task_hcs.go b/cmd/containerd-shim-runhcs-v1/task_hcs.go index 224735a242..f355955105 100644 --- a/cmd/containerd-shim-runhcs-v1/task_hcs.go +++ b/cmd/containerd-shim-runhcs-v1/task_hcs.go @@ -566,6 +566,9 @@ func (ht *hcsTask) Pids(ctx context.Context) ([]runhcsopts.ProcessDetails, error // Get the guest pids props, err := ht.c.Properties(ctx, schema1.PropertyTypeProcessList) if err != nil { + if isStatsNotFound(err) { + return nil, errors.Wrapf(errdefs.ErrNotFound, "failed to fetch pids: %s", err) + } return nil, err }