loader

by NKN CTO Yilun Zhang


We released a new version v1.1.1-beta. This is a major release that introduced various features, security updates, and performance optimization. Feature highlights:

Database:

  • Implement state pruning that can greatly reduce ChainDB size by removing unused states. State pruning is still be beta phase and is not enabled by default. You can enable it by setting StatePruningMode to "lowmem" in config.json, or start nknd with --pruning lowmem argument. In the future state pruning will be enabled by default. When state pruning is enabled, every time nknd starts, it will first prune local ChainDB, which might take a long time depending on last pruned height. Pruning an unpruned ChainDB can take a few days depending on your node’s disk I/O speed, so please be patient or start from a pruned snapshot (e.g. https://nkn.org/ChainDB_pruned_latest.zip or https://nkn.org/ChainDB_pruned_latest.tar.gz)

Consensus:

  • Implement random sampling neighbors in voting and gossip

Security:

  • Add block verification when syncing and persisting blocks

Client:

  • Implement multicast and compression protocol

Others:

  • Fix the bug that nanopay txn not in txpool gets removed
  • Fix the bug that nknc return code is not correct

This is a compatible upgrade, but upgrade is highly recommended due to the security update. Old version might be deprecated to accelerate the upgrade process.

  • If you are using one-click on DO/AWS/Google Cloud, you just need to stop and restart and miner and it will upgrade automatically.
  • If you downloaded the release version, you just need to download it again https://github.com/nknorg/nkn/releases 2, replace your nknd and nknc and run again
  • If you build from scratch, you just need to do the build again.
  • If you are using some scripts or tutorials that has auto-updator, then it should be automatic if the auto-updator is working properly.

You probably don’t need to download the ChainDB snapshot manually, but if you really want or need, you can use https://nkn.org/ChainDB_latest.zip for full ChainDB, https://nkn.org/ChainDB_pruned_latest.zip or https://nkn.org/ChainDB_pruned_latest.tar.gz for pruned ChainDB.

To update to the new version, please stop your nknd, rebuild (or download the latest binary from https://github.com/nknorg/nkn/releases 2), and then restart. If you are using the auto-updater, then you just need to stop and restart and miner and it will upgrade automatically.