We are releasing a new version of Bor -
v0.3.3 for Mainnet. This version includes a hardfork named Delhi fork. Please upgrade your mainnet nodes before block number 38,189,056 (https://polygonscan.com/block/countdown/38189056) which is expected to be mined on Tue, 17th Jan 2023 around 6:00 PM UTC.
The instructions given below assume that you already have
bor v0.3.0 installed for the mainnet. If not, please find the announcement mentioning steps for the same here. Once that is installed, please follow the instructions below to upgrade to
v0.3.3. Note that this version is an immediate successor of
v0.3.0 for Mainnet.
Stop bor service
sudo service bor stop
Install Bor with a version tag, network name (mainnet or mumbai), and node type (sentry, validator, or archive).
# Replace the node type curl -L https://raw.githubusercontent.com/maticnetwork/install/main/bor.sh | bash -s -- v0.3.3 mainnet <node_type>
Check bor version
/usr/bin/bor version # It should print # 0.3.3-stable
Restart bor service
sudo service bor start
We’ve noticed from the feedback received that the many of the node operators are facing sync/peering issues with the latest release and we’d like to point out few considerations which might be possible reasons for the same.
The old cli used different default values for mainnet and mumbai chains and hence the cache which was implicitly used for mainnet was 4096 MB. With new-cli, as there is only one set of default values (at the moment), the cache for mainnet nodes (if not set explicitly) will be set to 1024 MB which will degrade the syncing performance of the node. Hence, we’d recommend using 4096 MB as the cache value if you’re running a mainnet node. To do so, add/update the
cachefield under cache tag in the config.toml (
/var/lib/bor/config.toml) file used to run the node. (If you’re running the node with flags, use
[cache] cache = 4096 ...
The old cli was capable to read and consume the static and trusted nodes files residing in datadir (by name
trusted-nodes.jsonrespectively). With new-cli, it will only consider these values of static and trusted nodes if they’re provided in the config.toml files. Hence, we’d recommend checking/updating these fields once (if not done already) and move all the values to this config.toml (
/var/lib/bor/config.toml) file. This will help the node in connecting to better peers and sync well.
[p2p] ... [p2p.discovery] ... bootnodes =  # Update the bootnodes here static-nodes =  # Update the static nodes here trusted-nodes =  # Update the trusted nodes here
Hard fork specific changes:
- Decrease sprint length from 64 to 16
baseFeeChangeDenominatorfrom 8 to 16
- Pruning has been introduced in the new-cli (using the command
bor snapshot prune-state). The internal mechanism of pruning will work in the same way as it used to with the previous versions. The command snapshot prune-state will be available as a subcommand of the bor binary and will accept relevant flags (e.g. datadir). More details can be found here.
- Adds support for a new flag for tweaking the number of tries in memory (
—cache.triesinmemory, default: 128) (Make TriesInMemory configurable through CLI and toml config by 0xsharma · Pull Request #552 · maticnetwork/bor · GitHub).
- Updates and improvements in the description and documentation of the flags in new-cli along with their default values in the help command.
Improvements and feature additions:
- GRPC integration for bor and heimdall (Implemented gRPC client for heimdall by 0xKrishna · Pull Request #468 · maticnetwork/bor · GitHub).
- Improve bor’s interaction with heimdall by using context based cancellation methods in heimdall client and bor consensus (add context to Fetch* methods by JekaMas · Pull Request #445 · maticnetwork/bor · GitHub).
- More improvements on checkpoint based validations while importing new blocks to control reorgs (RFC35/Common Ancestor: Modifying the forkchoice rule by manav2401 · Pull Request #425 · maticnetwork/bor · GitHub).
- Improvement and fixes in
eth_getTransactionReceiptsByBlockrpc call which used to return wrong results when state-sync transactions are present and unit tests for the same (Fix getTransactionReceiptsByBlock and TestGetTransactionReceiptsByBlock by 0xsharma · Pull Request #477 · maticnetwork/bor · GitHub).
- Replace mutex wherever possible with atomic pointers (introduced in go 1.19) (Use atomic pointer in go 1.19 by JekaMas · Pull Request #446 · maticnetwork/bor · GitHub).
- Add new metrics in heimdall client to measure requests (like valid/invalid requests, duration of each request, etc) (consensus/bor/heimdall: add new meter and timer metrics in heimdall client by manav2401 · Pull Request #459 · maticnetwork/bor · GitHub).
- Add traces (available through open-telemetry tracing) in whole mining process to measure time taken by each component in building a new block to make improvements in future (https://github.com/maticnetwork/bor/pull/429).
- Enable tracing support for state-sync transactions in
debugrequests (Add state sync transaction to debug_trace functions. by 0xsharma · Pull Request #547 · maticnetwork/bor · GitHub).
- Minor bug fixes and improvements across other modules.
Testing and benchmarking
- Restore geth tests (new: dev: pos-398 restore geth tests by marcello33 · Pull Request #436 · maticnetwork/bor · GitHub).
- Benchmark mining operations to make it more optimal to use (Mining benchmark by JekaMas · Pull Request #439 · maticnetwork/bor · GitHub).
- More unit tests for testing the consistency of validator set operations (e.g. handling priority and power of validators in set) in bor consensus (Added valSet testcases by 0xsharma · Pull Request #452 · maticnetwork/bor · GitHub).
- e2e tests for bor receipt calculations (Reciept e2e test by temaniarpit27 · Pull Request #431 · maticnetwork/bor · GitHub).
- Unit tests for bor specific filters (https://github.com/maticnetwork/bor/pull/456).
- Unit tests for scenarios when validator comes back online after a crash and tries to reorg (add : TestValidatorWentOffline by 0xsharma · Pull Request #507 · maticnetwork/bor · GitHub).
- Property based tests on transaction pool have been added to make improvements in future (Property based tests on TxPool: pending, locals by JekaMas · Pull Request #466 · maticnetwork/bor · GitHub).
You can find the latest docker images here:
For upgrading nodes using the Erigon client, please refer Erigon v0.0.5 Release for Mainnet [Action Required].