AIT3 is finally here I invite you to follow this tutorial so that you can also try to participate on this new testnet of aptos
Who am I
I am passionate about the world of blockchain and I would like to share my passion and research with you through my articles in giving you my perception and opening new doors to very early crypto projects.
Discord: Akabane#3147
EN Official Announcement canal
FR Officiel canal d’annoncement
Read every story from Dr_jackal (and thousands of other writers on Medium)
Introduction to Aptos Labs
Aptos is a new, independent project to fulfill our vision of delivering the safest and most production-ready blockchain in the world.
EN Official Announcement canal
FR Officiel canal d’annoncement
Part 01: How order and configure your VPS server in 2 minutes
Before installing the node you need to rent a VPS server
The advantages of VPS are that they have high availability and are easy to configure.
Of course I’ll explain how to rent a VPS server at a lower cost and especially how to configure it in less than 2 minutes.
Let’s go…
Order your VPS on Contabo by clicking here.
To be completely transparent with you this is an affiliate link that you can use even if you already have an account on Contabo. Thank you in advance.
Select Cloud VPS M
1 month for the rental period, you can extend later if needed
Do not change anything for the geolocation of your VPS server
Select 400GB SSD for storage type
Select Ubuntu 20.04
Generate your passport and copy and paste it now into a notepad that will be saved on your computer
Don’t touch anything
Don’t touch anything and click on “NEXT”
If you are new to Contabo and you are an individual, do not touch anything
Fill in the fields with your personal data
Finish filling in the last fields with your personal information and click on Next button to proceed to payment
Once you have finished paying for your order. You will receive a first email.
Corresponding to the status of your order
And approximately 15 minutes later you will receive a second email with all the information to connect to your VPS.
The login details to connect on your VPS
Part 02: How to connect to your VPS
With MacOS:
MacOS includes already a SSH command. To connect via SSH from this operating system, first open the Terminal window. You can find this tool by going to “ Application->Utilities->Terminal”.
With Windows : I invite you to download Putty by clicking “here**” (**You can directly download the installation file with this link).
This is the file illustrated in the image above, if you wish to download another one click on this “link”
Now open the .exe file to start the installation of Putty and follow the instructions to complete the installation. At the end of the installation you will have a shortcut to Putty on your desktop.
Now launch Putty
Launch Putty, a new window will open in which you will enter the IP address of your VPS and click on Open
The interface of your server will open and will ask you for the login details.
Now you are finally on your server (see image below):
Tip 1: To paste any command that you have already copied above, just right-click where you want to paste the command
Tip 2: Only paste or write a command when your vps server allows it. As soon as “[email protected]: “is visible you can write otherwise you have to wait
In this example you have permission to write or paste a command
Now you are ready to get serious. You just have to paste one by one the commands that I put at your disposal below. Take your time and make sure you have taken the order from start to finish.
To help you I have put some screenshots showing the result you should get each time you paste a command.
Best of luck…
Part03: Preparation
Update packages:
sudo apt update && sudo apt upgrade -y
Intall dependencies:
sudo apt-get install jq unzip -y
Screen installation
sudo apt install screen
when he asks you to press Y and then ENTER on your keyboard
Install git:
apt install git
Press Y and Enter
Install cargo:
apt install cargo
Press Y and Enter
Part04: Download Aptos Core/ prepare your developer environment/Install Aptos Cli
Clone the Aptos Repo:
git clone https://github.com/aptos-labs/aptos-core.git
And
cd aptos-core
Prepare your developer environment:
./scripts/dev_setup.sh
Press y and Enter
Update your current shell environment
source ~/.cargo/env
install aptos cli:
cargo install --git https://github.com/aptos-labs/aptos-core.git aptos --branch testnet
Part05: Setup Your Validator Node
Checkout the testnet:
git checkout --track origin/testnet
Create a directory for your Aptos node composition:
export WORKSPACE=testnetexport USERNAME=XXXXXXXXmkdir ~/$WORKSPACE
Remplace XXXXXX by a username libe below for example
export WORKSPACE=testnetexport USERNAME=jackalmkdir ~/$WORKSPACE
Generate key pairs
aptos genesis generate-keys --output-dir ~/$WORKSPACE/keys
This will create 4files: public-keys.yaml
,private-keys.yaml
, validator-identity.yaml
, validator-full-node-identity.yaml
for you. IMPORTANT: Backup your key files somewhere safe. These key files are important for you to establish ownership of your node, and you will use this information to claim your rewards later if eligible. Never share those keys with anyone else.
Open “public-Keys.yaml” with this command:
sudo nano /root/testnet/keys/public-keys.yaml
Save all information in a notepad and Press CTRL+X to quit
Open “private-Keys.yaml” with this command:
sudo nano /root/testnet/keys/private-keys.yaml
Save all information in a notepad and Press CTRL+X to quit
Open “validator-identity.yaml” with this command:
sudo nano /root/testnet/keys/validator-identity.yaml
Save all information in a notepad and Press CTRL+X to quit
Open “validator-full-node-identity” with this command:
sudo nano /root/testnet/keys/validator-full-node-identity.yaml
Save all information in a notepad and Press CTRL+X to quit
I save the all information in a notepad like below:
Part6: Configure your Validator
aptos genesis set-validator-configuration \ --local-repository-dir ~/$WORKSPACE \ --username xxxxxxxxx \ --owner-public-identity-file ~/$WORKSPACE/keys/public-keys.yaml \ --validator-host 35.232.235.205:6180 \ --full-node-host 34.135.169.144:6182 \ --stake-amount 100000000000000
Replace xxxxxx by your “node name” like the example below:
aptos genesis set-validator-configuration \ --local-repository-dir ~/$WORKSPACE \ --username jackal \ --owner-public-identity-file ~/$WORKSPACE/keys/public-keys.yaml \ --validator-host 35.232.235.205:6180 \ --full-node-host 34.135.169.144:6182 \ --stake-amount 100000000000000
This will create a YAML file in your working directory with your username
Please check with this command:
sudo nano /root/testnet/xxxxxxx/operator.yaml
Replace xxxxxxx by your username like below:
sudo nano /root/testnet/jackal/operator.yaml
And this command:
sudo nano /root/testnet/xxxxxxx/owner.yaml
Replace xxxxxxx by your username like below:
sudo nano /root/testnet/jackal/owner.yaml
Save all information in your notepad!!! Please CTRL+X to quit
Create layout YAML file, which defines the node in the validator:
aptos genesis generate-layout-template --output-file ~/$WORKSPACE/layout.yaml
And
vi ~/$WORKSPACE/layout.yaml
Delete all information and Paste the following information into this window:
---root_key: "D04470F43AB6AEAA4EB616B72128881EEF77346F2075FFE68E14BA7DEBD8095E"users: ["xxxxxxxxxx"]chain_id: 43allow_new_validators: falseepoch_duration_secs: 7200is_test: truemin_stake: 100000000000000min_voting_threshold: 100000000000000max_stake: 100000000000000000recurring_lockup_duration_secs: 86400required_proposer_stake: 100000000000000rewards_apy_percentage: 10voting_duration_secs: 43200voting_power_increase_limit: 20
Replace xxxxxx by your “node name” like the example below:
---root_key: "D04470F43AB6AEAA4EB616B72128881EEF77346F2075FFE68E14BA7DEBD8095E"users: ["jackal"]chain_id: 43allow_new_validators: falseepoch_duration_secs: 7200is_test: truemin_stake: 100000000000000min_voting_threshold: 100000000000000max_stake: 100000000000000000recurring_lockup_duration_secs: 86400required_proposer_stake: 100000000000000rewards_apy_percentage: 10voting_duration_secs: 43200voting_power_increase_limit: 20
For save write only “: w” without move and press Enter
Output
For quit write “: q” and finally press Enter
Part7: Framework
Build AptosFramework Move bytecode and copy into the framework folder:
cargo run --package framework -- releasecp head.mrb ~/$WORKSPACE/framework.mrb
Part8: Compile genesis
Compile genesis blob and waypoint with this comand:
aptos genesis generate-genesis --local-repository-dir ~/$WORKSPACE --output-dir ~/$WORKSPACE
This will create two files, genesis.blob
and waypoint.txt
, in your working directory.
And now copy the validator.yaml
, fullnode.yaml
files into this directory with thos command:
mkdir ~/$WORKSPACE/configcp docker/compose/aptos-node/validator.yaml ~/$WORKSPACE/validator.yamlcp docker/compose/aptos-node/fullnode.yaml ~/$WORKSPACE/fullnode.yaml
Part9: Modify the Config
Open your config file:
sudo nano /root/testnet/validator.yaml
And now modify the config file to update the key path, genesis file path, waypoint path:
Before modification
Replace the blue areas with the information below:
/root/testnet/
Replace the yellow areas with the information below:
/root/testnet/keys/
After the modification:
After modification
Now press CTRL+X
Press Y
Press Enter
Part10:Open ports
Go to the root:
cd $home
And use this command
apt install ufw -y ufw allow ssh ufw allow https ufw allow http ufw allow 6180 ufw allow 80 ufw allow 9101 ufw allow 181 ufw allow 182 ufw allow 8080 ufw allow 9103 ufw enable
Press enter
Press y and Enter
Part11: Launch your validator node
Start your local Validator by running the below command:
cd aptos-core
Create a screen session called “aptos-core”:
screen -S aptos-core
cargo run -p aptos-node --release -- -f ~/testnet/validator.yaml
Please Wait…
Press Ctrl+A then D
Now you can close Putty
Part12: Check your Validator Node Status
Please click here
Congratulation Everything it’s OK!
Part13: Register your validator node
Please click here
Warning: If you have a problem with the consensus pop format it’s because you didn’t copy all the consensus pop info, go to the right and you will understand
sudo nano /root/testnet/keys/public-keys.yaml
If you have a error message. refresh the page and click and second time “Validate node” button.
Best of luck.
Please join Dr Jackal Community for any support please don’t forget subscribre my My Youtube channel and follow my medium.
Don’t forget to connect your petra wallet, I explain everything in this tutorial, it’s super fast
Optionnel: You can also register your fullnode in parallel. If you have not yet launched your fullnode you can follow this tutorial which is much lighter
Part14: Vote for Dr.Jackal Community
😅
Please click here
See you soon!!!
Please join Dr Jackal Community for any support please don’t forget subscribre my My Youtube channel and follow my medium.
MY LINKS:
Discord: Akabane#3147
EN Official Announcement canal
FR Officiel canal d’annoncement
Read every story from Dr_jackal (and thousands of other writers on Medium)