Init bor with new genesis file. Make sure you specify the correct data directory. If you have used ansible, it will be at ~/.bor/data by default. If you are not using the defaults, please modify the datadir in the following command:
bor --datadir ~/.bor/data init ~/genesis.json
This should print âSuccessfully wrote genesis stateâ on your console. That means it was successful.
Start the bor service
sudo service bor start
Check for bor logs if everything is working fine
journalctl -u bor -f
Reach out to us in case you are facing any issues during or after the upgrade.
Since v0.2.5, snapshot=true by default, unless you explicitly set it as false.
We wouldnât recommend using syncmode=snap as we have seen some issues with it. The node doesnât sync the states and block number shows up as 0 always, even after syncing completely. So the recommended setting is âfullâ. But if you are syncing a new node from scratch, then you can use snap mode to sync till latest block quickly and then change it back to full and restart.
ubuntu@ip-xxx:~$ curl https://raw.githubusercontent.com/maticnetwork/launch/master/mainnet-v1/sentry/sentry/bor/genesis.json > ~/genesis.json
% Total % Received % Xferd Average Speed Time Time Time Current
Dload Upload Total Spent Left Speed
100 68446 100 68446 0 0 354k 0 --:--:-- --:--:-- --:--:-- 353k
ubuntu@ip-xxx:~$ bor --datadir ~/.bor/data init ~/genesis.json
Fatal: invalid genesis file: json: cannot unmarshal object into Go struct field BorConfig.config.bor.period of type uint64