bnb-chain / bsc-snapshots

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Fatal: Could not open database: open /bsc/node/geth/chaindata/ancient/chain/headers.cidx: no such file or directory

vaibhavraj05 opened this issue · comments

i am trying to setup bsc node on my system with docker but i am facing issue

  1. first i downloaded the data from below website and with the given link
    https://github.com/48Club/bsc-snapshots/tree/main#bsc-snapshots
    https://snapshots.48.club/geth.fast.33660414.tar.zst

I run the command

wget https://snapshots.48.club/geth.fast.33660414.tar.zst -O - | zstd -cd | tar xf -

and its download the geth.fast/geth/chainnode and chaindata contain all data

  1. Then i downloaded mainnet using below command provided on bsc website
wget   $(curl -s https://api.github.com/repos/bnb-chain/bsc/releases/latest |grep browser_ |grep mainnet |cut -d\" -f4)
unzip mainnet.zip

And my folder structure look like this

image
  1. below is my docker compose
version: "3.3"
services: 
  bsc:
    image : ghcr.io/bnb-chain/bsc:latest
    container_name: bsc
    restart: always
    ports:
      - 8575:8575
    volumes:
      - /bsc/config:/bsc/config
      - /bsc/data/geth.fast:/bsc/node
    command: --http.addr 0.0.0.0 --http.port 8575 --http.vhosts '*' --verbosity 5

these are the logs for the docker compose
image

and while running this command in container
geth --datadir node init ./config/genesis.json
getting below error
image

Fatal: Could not open database: open /bsc/node/geth/chaindata/ancient/chain/headers.cidx: no such file or directory