diff --git a/cmd/lotus-shed/splitstore.go b/cmd/lotus-shed/splitstore.go index ff949fda9..c2363c655 100644 --- a/cmd/lotus-shed/splitstore.go +++ b/cmd/lotus-shed/splitstore.go @@ -30,6 +30,7 @@ var splitstoreCmd = &cli.Command{ Subcommands: []*cli.Command{ splitstoreRollbackCmd, splitstoreCheckCmd, + splitstoreInfoCmd, }, } @@ -281,3 +282,29 @@ var splitstoreCheckCmd = &cli.Command{ return api.ChainCheckBlockstore(ctx) }, } + +var splitstoreInfoCmd = &cli.Command{ + Name: "info", + Description: "prints some basic splitstore information", + Action: func(cctx *cli.Context) error { + api, closer, err := lcli.GetFullNodeAPIV1(cctx) + if err != nil { + return err + } + defer closer() + + ctx := lcli.ReqContext(cctx) + info, err := api.ChainBlockstoreInfo(ctx) + if err != nil { + return err + } + + for k, v := range info { + fmt.Print(k) + fmt.Print(": ") + fmt.Println(v) + } + + return nil + }, +}