Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Commit 252cc98

Browse files
committed
Update some docs
1 parent db5f3a9 commit 252cc98

2 files changed

Lines changed: 9 additions & 2 deletions

File tree

Utilities/snapshot/README.md

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -62,8 +62,11 @@ You can verify the snapshot against a running node. Keep in mind, if a node is o
6262

6363
```
6464
snapshot verify balances
65+
snapshot verify chains
6566
```
6667

6768
# TODO
6869

69-
It could be optimized with go routines, and there might be a file limit for chains. So I might need to rotate the file cache and only have N number of file descriptors open. Eg use something like https://github.com/hashicorp/golang-lru
70+
It could be optimized with go routines, and there might be a file limit for chains. So I might need to rotate the file cache and only have N number of file descriptors open. Eg use something like https://github.com/hashicorp/golang-lru
71+
72+
Currently `verify chains` does not prove **all** chains were recorded. We can do this by tallying up the chains in the system, and compare to the number of chains we recorded.

Utilities/snapshot/internal/cmd/verify.go

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -90,7 +90,11 @@ func verifyEntries() *cobra.Command {
9090
cmd := &cobra.Command{
9191
Use: "chains",
9292
Aliases: []string{"entries"},
93-
Short: "verify found chains",
93+
Short: "verify all recorded chains are correct",
94+
Long: "This will ensure all recorded chains have the correct chain heads and all eblocks are correct." +
95+
" It will not check to see if all chains were recorded, so there might exist untracked chains." +
96+
" We can check for untracked chains by checking the total number of chains recorded against the expected" +
97+
" number.",
9498
RunE: func(cmd *cobra.Command, args []string) error {
9599
ctx := cmd.Context()
96100
dumpDirectory, err := cmd.Flags().GetString("dump-dir")

0 commit comments

Comments
 (0)