alastria / alastria-node-besu

How to install a node in Alastria Red-B (Besu Technology) and tips to deploy and use it
Apache License 2.0
7 stars 6 forks source link

ALASTRIA red B

Slack Status License

Introduction

Alastria red B Network is a public-permissioned Blockchain network that uses the Hyperledger BESU technology, IBFT 2.0 consensus algorithm, and it's managed by Alastria partners, :vulcan_salute:.

There are 2 main steps to set up an Alatria Node:

1. Installation & configuration: There are two different ways to install the Alastria Besu node.

2. Getting permissioned: In order to use Alastria Network, your node must be previously accepted.

If you are a rookie in Blockchain or Ethereum please consider reading these references:

If you would like you to know more about Hyperledger Ecosystem, this link is a good start.

Administrative requirements

Alastria partners can add its own node. Otherwise contact support@alastria.io to start with administrative permissioning.

There are 2 main steps to set up an Alatria Node:

1. Installation: Follow the installation process and your node will be ready to be permissioned.

2. Getting permissioned: In order to use Alastria Network, your node must be previously accepted, after filling the form.

If a member wants to remove a node from the network, please send us a removal request using the same electronic form.

1) Installation

Before starting, consider the following guide to add a dedicated disk for the node database, independent of the system disk.

The following process explains the installation for a node:

git clone https://github.com/alastria/alastria-node-besu.git
cd alastria-node-besu/docker-compose

Set the NODENAME attribute according to the name you want for this node. The name SHOULD follow the convention: `REGB`

Where \<COMPANY> is your company/entity name, \<Y> is the number of processors of the machine, \<Z> is the amount of memory in Gb and \<NN> is a sequential counter for each machine that you may have (starting at 00). For example:

NODE_NAME="REG_ExampleOrg_B_2_8_00"

This is the name that will be given to the docker container.

docker-compose up -d

We are done. Now, we will have the followings available:

2) Permissioning new node

All nodes in Alastria Networks must be permissioned. To ask for permission you must enter your data in this electronic form, providing these information of your node:

1. ENODE: String ENODE from ENODE_ADDRESS (enode://ENODE@IP:30303)

2. Public IP: The external IP of your node.

3. System details: Hosting provider, number of cores (vCPUs), RAM Memory and Hard disk size.

In order to get permissioning, follow these steps to get the information that you will be asked for in the previous form:

curl https://ifconfig.me/

Adding automatic checking for updates in node lists

If your installation was done with docker-compose everything is set up in the container and there's nothing else to do :tada:

However, if your installation was done prior to June 2022, ensure you have the more up-to-date code running in your machine following these steps:

Secure your Besu node using API Key

We can add an additional security layer to our Besu node using API Key implementation in order to identify or authenticate an user for using the service.

Please, navigate to the section to set up the node. :point_right: API Key

Infraestructure details

System requirements

Hardware Minimum Desired
CPU's: 2 4
Memory: 4 Gb 8 Gb
Hard Disk (SSD): 64 Gb 256 Gb

Blockchain database is about 16Gb at mid-2021 and grows at rate of 2Gb/month. Take this into consideration when provisioning space for cache, logs etc. SSD Disk is mandatory

Firewall configuration

You need to open the following ports to deploy a node:

Incoming rules

Port Type From Definition
30303 TCP 0.0.0.0 Ethereum client data transfer ports
30303 UDP 0.0.0.0 Ethereum client listener and discovery ports
9545 TCP 18.201.52.140 Scraping Prometheus metrics from Alastria

Notes:

Optional ports:

Port Type From Definition
8080 TCP (orion parners) :warning: DEPRECATED Orion port (in case you use private transactions)
8545 TCP (web3 client) json+rpc (in case you use remix/truffle/.../web3)
8546 TCP (web3 client) json+ws (in case you use remix/truffle/.../web3)

Notes:

Help! :fire_extinguisher:

Slack

Alastria has a group of channels available on Slack message platform, url: alastria.slack.com. You need to be invited, for it, please send a email to support@alastria.io asking to join the channel. Provide the following information:

Available channels by default

Once accepted in the Alastria Slack group you are automatically included in:

You can add yourself to the following channels:

FAQ

docker logs -f NODE_NAME
2021-04-29 14:58:44.465+00:00 | EthScheduler-Services-5 (importBlock) | INFO  | FullImportBlockStep | Import reached block 10145800 (0x82c9..ea34), Peers: 1

The last column should show, at least, one "Peer".

Use eth_syncing method to see the synchronization progress:

curl -X POST --data '{"jsonrpc":"2.0","method":"eth_syncing","params":[],"id":1}' http://127.0.0.1:8545
curl -X POST --data '{"jsonrpc":"2.0","method":"admin_peers","params":[],"id":1}' http://127.0.0.1:8545
curl -X POST --data '{"jsonrpc":"2.0","method":"admin_nodeInfo","params":[],"id":1}' http://127.0.0.1:8545

Other ADMIN methods, in Besu API method

Also, IBFT and PERM methods (for validator nodes), in Private network API methods

It's in your hands! Alastria is an open group and everyone is welcome to contribute. If you need any support we are here to help :hugs:

You can refer to the smart-contract-deployment repository.

Links

Operation documents of Alastria nodes