How to replay the shred
- download , unzip and put into /tmp/test-ledger
https://drive.google.com/file/d/1IXk39jz6lN02D7Xu3bgKgHyKKzFAW65F/view?usp=share_link
- download solana-pg.sql
https://drive.google.com/file/d/1m5OC_TvdCbHWLYwW_IQyRIt0-7mh_I4z/view?usp=share_link
then load the .sql file into postgres
psql -U solana -p 5432 -h 127.0.0.1 -d solana -f /tmp/solana-pg.sql
- run shred_replay process, make sure /tmp/test-ledger exists.
> shred-replay -c <geyser.json> -l <new-ledger-dir> verify
> shred-replay -c /Users/cairo/solana-dev/settlement/solana-accountsdb-plugin-postgres/scripts/geyser.json -l /tmp/ledger2 verify
genesis hash: D65qTaRvYmu15VUugEEuQt4mfc14zvmYFehXtnoSMwxo
Ok
> solana-ledger-tool -l /tmp/ledger2 verify
run l /tmp/ledger2 verify
Here's a snapshot showing blocks being verified success.
Once the verification fails, the stderr will show “entry hash is different”.