Skip to content

Commit

Permalink
Merge pull request #9184 from filecoin-project/feat/secrenew-only-cc
Browse files Browse the repository at this point in the history
feat: sectors renew --only-cc
  • Loading branch information
magik6k authored Aug 18, 2022
2 parents b5ac141 + 87b82b9 commit 9fb1a0d
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 0 deletions.
8 changes: 8 additions & 0 deletions cmd/lotus-miner/sectors.go
Original file line number Diff line number Diff line change
Expand Up @@ -796,6 +796,10 @@ var sectorsRenewCmd = &cli.Command{
Name: "new-expiration",
Usage: "try to extend selected sectors to this epoch, ignoring extension",
},
&cli.BoolFlag{
Name: "only-cc",
Usage: "only extend CC sectors (useful for making sector ready for snap upgrade)",
},
&cli.Int64Flag{
Name: "tolerance",
Usage: "don't try to extend sectors by fewer than this number of epochs, defaults to 7 days",
Expand Down Expand Up @@ -931,6 +935,10 @@ var sectorsRenewCmd = &cli.Command{
}

for _, si := range activeSet {
if len(si.DealIDs) > 0 && cctx.Bool("only-cc") {
continue
}

if si.Expiration >= from && si.Expiration <= to {
if _, exclude := excludeSet[uint64(si.SectorNumber)]; !exclude {
sis = append(sis, si)
Expand Down
1 change: 1 addition & 0 deletions documentation/en/cli-lotus-miner.md
Original file line number Diff line number Diff line change
Expand Up @@ -1789,6 +1789,7 @@ OPTIONS:
--from value only consider sectors whose current expiration epoch is in the range of [from, to], <from> defaults to: now + 120 (1 hour) (default: 0)
--max-fee value use up to this amount of FIL for one message. pass this flag to avoid message congestion. (default: "0")
--new-expiration value try to extend selected sectors to this epoch, ignoring extension (default: 0)
--only-cc only extend CC sectors (useful for making sector ready for snap upgrade) (default: false)
--really-do-it pass this flag to really renew sectors, otherwise will only print out json representation of parameters (default: false)
--sector-file value provide a file containing one sector number in each line, ignoring above selecting criteria
--to value only consider sectors whose current expiration epoch is in the range of [from, to], <to> defaults to: now + 92160 (32 days) (default: 0)
Expand Down

0 comments on commit 9fb1a0d

Please sign in to comment.