PlatON Network Version 1.1.1 (Copernicus) Upgrade Operations Manual

PlatON Network

PlatON Network Version 1.1.1 (Copernicus) Upgrade Operations Manual

PlatON Network Version 1.1.1 (Copernicus) update announcement

Version Information
ChainID: 100
Version: 1.1.1
Git Commit: 9960b7fd8128a047bc552b76ab7a0f557d0fb7dd

1.Notes of Update

1.1 CPU, memory and disk-related issues

As part of the historical data will be migrated to the Freezer database during the upgrade process, the hashing power of CPU will grow and return to normal when the data is migrated; after the upgrade is restarted, the memory may increase in some cases, and if so, it will return to normal when the data is migrated; the storage will also increase after the upgrade (for example, the storage space will increase by about 8G after the upgrade at the height of Block 16200000). For details, see Github releases 1

  • Upgrade memory
  • There is a small probability that 8G memory will increase when the nodes are upgrading, resulting in OOM. To avoid this situation, it is advised to use swap partitions. If possible, you can also upgrade the machine’s physical memory to 16GB.

Increase swap partition

wget https://download.platon.network/platon/scripts/platon_swap.sh chmod +x platon_swap.sh 
./platon_swap.sh

Notes:

  1. The platon_swap.sh script provided in the document is subject to the following treatments: when the swap partition does not exist, an 8G swap partition will be created; when the swap partition is less than 7G, the swap partition will be increased to 8G; when the swap partition is greater than 7G, the swap partition will not be created.
  2. If you do not upgrade the host memory for node upgrade, an OOM situation will occur and the host will fail to be connected; after the host is restarted, the startup process can be resumed

Scale the disk:

  • During the upgrade process, the disk capacity has increased by about 8G. If the available disk capacity is insufficient, it is suggested to scale it.

1.2 Incompatibility issue

After this node upgrade, you cannot use version 1.1.0 or the upgraded data to start up. It is suggested to download the official backup data before the upgrade and store it on the node’s host. If the node cannot be started after the upgrade, version 1.1.0 and the backup data will be needed.

  • To back up data in the fast mode, with the data size of 9.4G and the block height at 16230831, replace the data/platon directory with the data when the node fails to start,.
wget https://download.platon.network/platon/nodedata/1.1.0-fast-data.tar.gz tar -xf 1.1.0-fast-data.tar.gz

2. Installation Guide

​ If the PlatON node has been installed, please skip to 3 to update the nodes;

​ If the node is not installed, please strictly follow the official document for installation. If you need help, please contact customer service.


3. Update Guide (update first, and do not restart temporarily)

We take the Ubuntu18.04 system as an example in the following steps. There are two ways for the update: directly using binary and source code compilation, for your choice; please strictly follow the steps below. If you need any help, please contact customer service.

Directly using binary

# Back up binary
$ [[ -x /usr/bin/platon ]] && sudo mv /usr/bin/platon /usr/bin/platon_`platon version | grep ‘^Version:’ | awk -F “[ ,:,-]” ‘{print $3}’`
# Download the latest binary file
$ wget https://download.platon.network/platon/platon/1.1.1/platon
# Use new version
$ chmod +x platon
$ sudo mv platon /usr/bin/platon
# View version
$ platon version
Version: 1.1.1-unstable
Git Commit: 9960b7fd8128a047bc552b76ab7a0f557d0fb7dd

Source code compilation

(For the environment that has been successfully compiled before, please refer to Installation of official website source code for new compilation

# Back up binary
$ [[ -x /usr/bin/platon ]] && sudo mv /usr/bin/platon /usr/bin/platon_`platon version | grep '^Version:' | awk -F "[ ,:,-]" '{print $3}'`
# Compile binary
$ git clone https://github.com/PlatONnetwork/PlatON-Go.git --recursive
$ cd PlatON-Go/
$ git checkout -b platon-1.1.1 9960b7fd8128a047bc552b76ab7a0f557d0fb7dd
# Install dependencies and compile. If missing go.sum entry for module appears, use go mod tidy to remove unused and add missing dependencies
$ go mod download && make all
# Use new version
$ chmod +x build/bin/platon
$ sudo mv build/bin/platon /usr/bin/platon
# View version
$ platon version
Version: 1.1.1-unstable
Git Commit: 9960b7fd8128a047bc552b76ab7a0f557d0fb7dd

4. Restart the Process as Appropriate

If the current node has staked coins before, first check whether the node has been elected as a validator (in consensus) through Blockchain Explorer 2.
If yes, please restart after the node quit being the validator (from in consensus to active).

The following commands are for reference only. You may restart the platon process according to the respective management methods.

nohup platon --identity platon --datadir ./data --port 16789 --rpcport 6789 --rpcapi "db,platon,net,web3,admin,personal" --rpc --nodekey ./data/nodekey --cbft.blskey ./data/blskey --verbosity 1 --rpcaddr 127.0.0.1 --syncmode "fast" > ./data/platon.log 2>&1 &

5. Version Statement

After the version statement is released, you can check the node version in the explorer.

#Example of version statement
$ platon_mtool declare_version --keystore $PLATON_MTOOLDIR/keystore/staking.json --config $PLATON_MTOOLDIR/validator/validator_config.json
  • For nodes with no staking, skip this step.
  • If $PLATON_MTOOLDIR is not defined, the absolute path needs to be completed according to the actual deployment situation.

6. Feedback

If the platon upgrade fails, you can provide feedback through the following channels.

  1. WeChat group of validators
  2. Email validator@platon.network

This article is reproduced from https://medium.com/platon-network/platon-network-version-1-1-1-copernicus-upgrade-operations-manual-396b80ad96fe

Like (0)
PlatONWorld-M6's avatarPlatONWorld-M6Official
Previous November 18, 2021 10:56
Next November 18, 2021 15:25

相关推荐

Leave a Reply

Please Login to Comment