Launching GHOST TestNet 3.0 [~1 HR]

  • Post author:
  • Post category:Guide
You are currently viewing Launching GHOST TestNet 3.0 [~1 HR]

Introduction

Welcome to the GHOST TestNet 3.0 Launch Guide. In TestNet 2.0 we have 140 Nodes and ability to send $CSPR. With TestNet 3.0 there is a ton of stuff coming including further GHOST Eye updates, staking, slashing, etc. All existing TestNet 2.0 Full Nodes MUST update to TestNet 3.0 to take advantage of new functionality.

1. Prerequisites

Launching GHOST TestNet 2.0 Prerequisites

Before you can proceed with launching you GHOST Node please make sure to go though the following guide:

  1. GHOST Chain Startup Guide – create the proper environment and install GHOST Chain.
  2. Testing Connectivity Guide – test whether or not you node can become a Boot Node and set proper firewall rules.

2. GHOST Chain Key Generation

Generating Keys & Applying For Genesis Block Key Generation
Start with creating the following directory:

sudo mkdir /etc/ghost

Get your username:

whoami

Give the user permission to the directory and substitute {USERNAME} for the one from previous command:

sudo chown {USERNAME} /etc/ghost

Generating Node Keys

To generate the node key use the following command:

~/ghost/ghost-node/target/release/ghost key generate-node-key --bin --file=/etc/ghost/node-key
Generating Keys & Applying For Genesis Block Local Identity
Local Identity

3. Launching GHOST TestNet 3.0

Launching GHOST TestNet 2.0 Launch GHOST Node

Go to ghost-node directory:

cd ghost/ghost-node

Remove ghost ledger:

sudo rm -rf /var/lib/ghost/chains/casper_staging_testnet

Make sure ghost-node is up to date:

git pull origin main

Recompile ghost-node using starter.sh and --release flag. Make ghost-node service being able to be started by default user using --make-global:

./scripts/starter.sh --release --make-global

The default option is capitalized which is N, you can also press Enter to choose the default option. In this case we want to recompile so type y and press Enter to proceed:

'cargo build --release ' is what you want? [y/N]:

Recompiling will take some time!

Check the hash of the build:

sha256sum /etc/ghost/casper.json

You should see:

5aeb6fd5b9b14bdbc1a61600655b5217ded7c1b7cb05bd32929354e88935ae97

Create running ghost-node service that starts on system boot using --unit-file flag. And we must set up the ghost-node launch command by setting arguments using --set-arguments flag:

./scripts/starter.sh --unit-file --set-arguments

Only change the defaults if you are advanced otherwise press Enter for the following prompts.

If this is your first node simply press Enter to proceed with the default. If this is your second node you should type a different port here, for example 30334, and then you should open this port on your firewall and create a dedicated port forwarding rule on your router as specified in the Testing Connectivity Guide:

specify p2p protocol TCP port (default: 30333):

To choose default options press Enter here:

specify JSON-RPC server TCP port: (default: 9945): 
specify the chain specification (default: /etc/ghost/casper.json):
specify node's secret key file for p2p networking (default: /etc/ghost/node-key):

It is recommended that you give your node a Name you can recognize:

specify name for the node (default: RANDOM_NAME):

Validator Node vs Full Node

Currently you have to qualify to become a validator node through GHOST Whales. If you were NOT included in the ghosties file then you cannot be a validator node and you can only be a full node so for disable validator mode? [y/N] type y. If you were included in the ghosties file the you can press Enter:

disable validator mode? [y/N]: y

You can press Enter here:

enable prometheus? [y/N]:

Boot Node

For the following prompt:

list of bootnodes if any:

Paste one of the following Boot Node address:

IMPORTANT!!!
If you want your node to become a GHOST Chain Boot Node and to have a dedicated Boot Node Address listed in this guide please follow the Create Custom Boot Node Address guide and let us know in GHOST Whales.
Boot Node Address Port Status
/dns/bootnode69.chain.ghostchain.io/tcp/30334/p2p/12D3KooWF9SWxz9dmy6vfndQhoxqCa7PESaoFWEiF8Jkqh4xKDRf
Checking port 30334 for https://bootnode69.chain.ghostchain.io...
/dns/bootnode70.chain.ghostchain.io/tcp/30333/p2p/12D3KooWP3h5dSdqcpvsCr7fp1jyfqDj291QDZ68a4gY6VQ8T1nW
Checking port 30333 for https://bootnode70.chain.ghostchain.io...
/dns/ghostvision.mywire.org/tcp/30333/p2p/12D3KooWR5JJQ9mALPpnSxfZm5M23AByitSfxpei9ZDghU1NLNeW
Checking port 30333 for https://ghostvision.mywire.org...
/dns/ghostvision.mywire.org/tcp/30334/p2p/12D3KooWDs4i6VoK4dpwGSUVtZENzSmsbQk3tF63gYT745x7eAb2
Checking port 30334 for https://ghostvision.mywire.org...
/dns/ghostvision.mywire.org/tcp/30335/p2p/12D3KooWJMiF7LUmDZ17NJRi9yHusHG4hrLGxoPv6sS7K2Vpn9P2
Checking port 30335 for https://ghostvision.mywire.org...
/ip4/84.247.181.131/tcp/30333/p2p/12D3KooWJXBYA7cUQLLenEfT7hmCjBJ6fyikDy8YhNz4aLfwbBC8
Checking port 30333 for http://84.247.181.131...
/ip4/47.199.13.160/tcp/30333/p2p/12D3KooWQHiwqRokC3BmDrZ9LszxwFj7vjJ2adJDZPVQvRJXSA42
Checking port 30333 for http://47.199.13.160...
/ip4/85.190.242.68/tcp/30334/p2p/12D3KooWEcJAQHs59gD3hDWU5UXxc9nNQcS6dPe3cnFtL8bBuEnw
Checking port 30334 for http://85.190.242.68...
/ip4/47.199.13.160/tcp/30334/p2p/12D3KooWB4758nu1pXuFiawKZ6R8ZRYzHS367afPnyJKScmLQ81x
Checking port 30334 for http://47.199.13.160...
/ip4/47.199.13.160/tcp/30335/p2p/12D3KooWRHyMrQDqQLbEtADi84FBtxn4gu7iu9VKtFPvhHLsoSsF
Checking port 30335 for http://47.199.13.160...
/ip4/47.199.13.160/tcp/30336/p2p/12D3KooWD6YmEzC44HDZ5pDbQ8MU2V2i3e9vq7ay1pE7QoAC37e2
Checking port 30336 for http://47.199.13.160...
/ip4/47.199.13.160/tcp/30337/p2p/12D3KooWJbwRwvYxZCVtzw7hUq3CuA9LrzotgEcAT6zkc9sc81w4
Checking port 30337 for http://47.199.13.160...
/dns/Fujisan1.mywire.org/tcp/30333/p2p/12D3KooWHZubqyhyU68wfWvhtXJCdSH6mJW8DPz45xK2zG6eXkHo
Checking port 30333 for http://Fujisan1.mywire.org...
/dns/Fujisan1.mywire.org/tcp/30334/p2p/12D3KooWHZubqyhyU68wfWvhtXJCdSH6mJW8DPz45xK2zG6eXkHo
Checking port 30334 for http://Fujisan1.mywire.org...
/dns/Fujisan1.mywire.org/tcp/30335/p2p/12D3KooWHZubqyhyU68wfWvhtXJCdSH6mJW8DPz45xK2zG6eXkHo
Checking port 30335 for http://Fujisan1.mywire.org...
/dns/Fujisan1.mywire.org/tcp/30336/p2p/12D3KooWHZubqyhyU68wfWvhtXJCdSH6mJW8DPz45xK2zG6eXkHo
Checking port 30336 for http://Fujisan1.mywire.org...

Changing unit-file name is optional, otherwise press Enter:

[?] name for the unit file (default: ghost-node.service)

IF ERROR and [!] user ghost not found pops up press y:

[!] user ghost not found
[?] do you want to create ghost user? (NOT RECOMMENDED: current root) [y/N]:
[+] make ghost owner of /var/lib/ghost
[+] prepare unit file for the ghost-node.service
[+] reloading systemd because of updated unit file

DO NOT start and enable ghost-node.service press Enter:

[?] do you want to start the ghost-node.service? [y/N]:
[?] do you want to enable the ghost-node.service? [y/N]:
[+] execution finished

Restart ghost-node:

sudo systemctl restart ghost-node

Enable ghost-node:

sudo systemctl enable ghost-node

To see the logs produced by your ghost-node:

journalctl -f -u ghost-node

To exit journalctl -f -u ghost-node Press CTRL + C.

Finally, go to GHOST Telemetry so see your node live on the map.

Congratulations! You have an operational GHOST Node.

Migrating from TestNet 2.0 to 3.0

Launching GHOST TestNet 3.0 Migrating

Only follow this section if you currently have a GHOST TestNet 2.0 Full Node

Stop ghost-node process:

sudo systemctl stop ghost-node

Remove GHOST TestNet 2.0 Ledger:

sudo rm -r /var/lib/ghost/chains/casper_staging_testnet

Go to ghost-node directory:

cd /home/ghost/ghost-node

Pull the most recent GHOST Chain PR from GHOST GIT:

git pull origin main

Recompile your GHOST Node:

./scripts/starter.sh --release --make-global

Check checksum the output should be 5aeb6fd5b9b14bdbc1a61600655b5217ded7c1b7cb05bd32929354e88935ae97:

sha256sum /etc/ghost/casper.json

Check ghost-node version, the output should be ghost 0.7.196-22984545194:

ghost --version

Restart GHOST Node:

sudo systemctl restart ghost-node

Check GHOST Node log:

journalctl -f -u ghost-node

Troubleshooting

Launching GHOST TestNet 2.0 Troubleshooting
For future troubleshooting be aware of the following commands:

Update GHOST Node

Go to GHOST directory:

cd ghost/ghost-node

Pull the most recent GHOST Node Repo:

git pull origin main

Set arguments. In one of the prompts it is recommended that you give your node a Name you can recognize:

./scripts/starter.sh --set-arguments
## do all steps

Check GHOST Node log:

journalctl -f -u ghost-node

To exit journalctl -f -u ghost-node Press CTRL + C.

Delete GHOST Chain ledger

sudo systemctl stop ghost-node
sudo rm -rf /var/lib/ghost
./scripts/starter.sh --unit-file
sudo systemctl start ghost-node

Check session keys

./scripts/starter.sh --check-keys --insert-keys
sudo ls -l /var/lib/ghost/chains/casper_staging_testnet/keystore/
sudo systemctl restart ghost-node.service

Miscellaneous

To soft reload the entire system:

sudo systemctl daemon-reload

To stop ghost-node:

sudo systemctl stop ghost-node

To restart ghost-node:

sudo systemctl restart ghost-node

To see the logs produced by your ghost-node:

journalctl -f -u ghost-node

What is GHOST?

GHOST Ecosystem is at the forefront of decentralized cross-chain interoperability, providing the ability to transfer tokens, NFTs, and other digital assets across multiple blockchains.

ghostAirdrop | ghostAirdrop Bot | Medium | Telegram | Twitter | Website