From 85f2ac8789e9b5a4760bf6ba01cb46b22f0d8707 Mon Sep 17 00:00:00 2001 From: aarshkshah1992 Date: Fri, 21 May 2021 14:56:37 +0530 Subject: [PATCH] more logging --- extern/sector-storage/piece_provider.go | 1 + extern/sector-storage/stores/remote.go | 2 ++ 2 files changed, 3 insertions(+) diff --git a/extern/sector-storage/piece_provider.go b/extern/sector-storage/piece_provider.go index fd54d2166..9d7ff907b 100644 --- a/extern/sector-storage/piece_provider.go +++ b/extern/sector-storage/piece_provider.go @@ -57,6 +57,7 @@ func (p *pieceProvider) tryReadUnsealedPiece(ctx context.Context, sector storage // the unsealed piece. r, err := p.storage.Reader(ctx, sector, abi.PaddedPieceSize(offset.Padded()), size.Padded()) if err != nil { + log.Debugf("failed storage reader;sector=%+v, err:%s", sector.ID, err) cancel() return nil, nil, err } diff --git a/extern/sector-storage/stores/remote.go b/extern/sector-storage/stores/remote.go index 7400c6ee0..741928fdf 100644 --- a/extern/sector-storage/stores/remote.go +++ b/extern/sector-storage/stores/remote.go @@ -510,6 +510,7 @@ func (r *Remote) Reader(ctx context.Context, s storage.SectorRef, offset, size a log.Infof("Read local %s (+%d,%d)", path, offset, size) ssize, err := s.ProofType.SectorSize() if err != nil { + log.Debugf("failed to get sectorsize: %s", err) return nil, err } @@ -530,6 +531,7 @@ func (r *Remote) Reader(ctx context.Context, s storage.SectorRef, offset, size a if err := r.pfHandler.Close(pf); err != nil { return nil, xerrors.Errorf("close partial file: %w", err) } + log.Debugf("miner has unsealed file but not unseal piece, %s (+%d,%d)", path, offset, size) return nil, nil }