DPOPS Testnet Instructions

Zach Hildreth
X-Cash
4 min readDec 17, 2021

--

Dear Community,

Today we would like to explain how to setup your node for the testnet. This is about the same process as setting up a node for the mainnet, but we will be using the “dpops-test” branch. You can follow any of the official tutorials for more in depth coverage of setting up a server, delegate or voting, registering etc, but this article will give the basics for full testnet participation.

You can view the delegates website for the testnet at http://dpops-test-delegates.xcash.foundation

Step 1

Once you have a server ready, use the “dpops-test” branch autoinstaller to setup the server with the dpops code specifically for the testnet (make sure to use the default paths for everything as this is not fully tested yet on custom paths)

source <(curl -sSL https://raw.githubusercontent.com/X-CASH-official/xcash-dpops/dpops-test/scripts/autoinstaller/autoinstaller.sh)

This will take about an hour but can depend on your server speed and internet speed.

Step 2

Now you need to stop xcash-dpops and xcash-rpc-wallet from running

sudo systemctl stop xcash-dpops xcash-rpc-wallet

Step 3

Now you need to edit the service file for dpops

sudo nano /lib/systemd/system/xcash-dpops.service && sudo systemctl daemon-reload

just go to the end of the line that starts with ExecStart and add to the end of the line

--start-time 122 1 8 16 56

example my line looks like (if my key was all 0's)

ExecStart=/root/xcash-official/xcash-dpops/build/xcash-dpops --block-verifiers-secret-key 00000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000 --start-time 122 1 8 16 56

Step 4

Note for this step, you can view your wallets password at any time by running

cat /lib/systemd/system/xcash-rpc-wallet.service

You can also view your DPOPS private key by running

cat /lib/systemd/system/xcash-dpops.service

The private key will be the 128 byte key and the public key will be the last 64 bytes of the 128 byte key

Now its time to register your delegate. You will need to open the delegate wallet to do this (replace YOURPASSWORD with your password from the install output)

cd ~/xcash-official/xcash-wallets && ~/xcash-official/xcash-core/build/release/bin/xcash-wallet-cli --wallet-file delegate-wallet --password “YOURPASSWORD”

Once the wallet is fully synced and at the wallet prompt register the delegate by run the following

delegate_register <delegates_name> <delegates_IP_address> <delegates_public_key>

Where the following are

<delegates_name> = any delegate name you want
<delegates_IP_address> = the ip of the server or a domain with an A record with the ip of the server
<delegates_public_key> = the delegate public key from the installation step

this can take up to five minutes

then exit once your done (if you dont need to vote from this wallet)
type “exit” in the wallet

Step 5

Now you need to vote for your own delegate or get others to vote for you. If you want to vote it is recommended to download the testnet binaries to your local computer and open your wallet on your local computer (not the server).
you can download the testnet binaries from
windows-bin.zip
linux-bin.zip

The best way to connect to the testnet blockchain is to use a testnet remote node to vote. Once the binaries have been downloaded you can run the following to restore your wallet file. (its important you dont use an existing wallet file because it will have a cache for the mainnet, so you need to reimport your wallet to a new file)

Unzip the binaries and navigate to the folder in a CMD window or terminal and then run

Linux

./xcash-wallet-cli --trusted-daemon --daemon-address dpops-test-1.xcash.foundation:18281 --restore-deterministic-wallet

Windows

xcash-wallet-cli --trusted-daemon --daemon-address dpops-test-1.xcash.foundation:18281 --restore-deterministic-wallet

Then fill out the questions and let is fully scan the 880000 testnet blocks. Once done you can vote.

To vote run

vote <delegate_name>

This can take up to 1 hour

Step 6

Once you have registered and voted for your delegate it is now time to run the rpc-wallet and the xcash-dpops

sudo systemctl restart xcash-rpc-wallet && sleep 60s && sudo systemctl restart xcash-dpops

Step 7

You should be done and syncing from other dpops servers and ready to go. check the logs to make sure (you should see it has fully sycned the databases and has a message saying “Waiting for the specific start time”

journalctl --unit=xcash-dpops -n 100 --output cat --follow

If you have any questions ask a team member or in the general community!

--

--