Starting a Forger
This part should only be followed if you intend to run a delegate or are planning to become one. First you need to make sure you register your ARK address as a delegate. You can do this inside the Desktop Wallet, by clicking on your wallet (make sure you have enough funds in the address you want to register) and click on the 3 dots in the upper right corner in the wallet address for which you wish to register the delegate, and click on ‘Register delegate’, sign the tx, and let it confirm. After that, we need to configure it on our relay node we previously configured. Login to your server and run this command:
This will bring up an interactive menu where you have two options of setting up your forger passphrase, ‘Encrypted BIP38’ or ‘Plain BIP39’.
Chose the preferred method using the
down arrow keys, confirm it with the
enter key, and configure according to the screen instructions. Note that when writing a BIP39 passphrase (12 words) make sure you either paste it from the file or write it as it was shown when you generated it — all lower case, words separated by space, no space at the end.
1✔ Please select how you wish to store your delegate passphrase? › - Use arrow-keys. Return to submit.23› Encrypted BIP38 (Recommended)4 Plain BIP39
- Encrypted BIP38 will encrypt your BIP39 passphrase with your custom password and save the encrypted passphrase. In order to decrypt it you will need to provide your set password so back it up as well. Once you set this up, you will need to confirm with the “y” and “enter” keys.
- Plain BIP39 will save your mnemonic passphrase in plain text. Once you set this up, you will need to confirm with the “y” and “enter” keys.
Do NOT share login details with unauthorized individuals. BIP38 encryption offers additional protections but does not prevent malicious extraction of a BIP39 mnemonic by those with access to your server.
An example of setting up Encrypted BIP38 passphrase:
1ark config:forger23✔ Please select how you wish to store your delegate passphrase? › - Use arrow-keys. Return to submit.45› Encrypted BIP38 (Recommended)6 Plain BIP3978✔ Please enter your delegate plain text passphrase. Referred to as BIP39.910✔ Please enter your custom password that encrypts the BIP39. Referred to as BIP38.1112✔ Confirm custom password that encrypts the BIP39. Referred to as BIP38.1314 ✔ Validating passphrase is BIP39 compliant.15 ✔ Prepare crypto.16 ✔ Loading private key.17 ✔ Encrypting BIP39 passphrase.
An example of setting up Plain BIP39 passphrase:
1ark config:forger23✔ Please select how you wish to store your delegate passphrase? › - Use arrow-keys. Return to submit.45 Encrypted BIP38 (Recommended)6› Plain BIP3978✔ Please enter your delegate plain text passphrase. Referred to as BIP39.910✔ Can you confirm? › (y/N)1112 ✔ Validating passphrase is BIP39 compliant.13 ✔ Writing BIP39 passphrase to configuration.
Note: passphrase (encrypted or not) is saved in file delegates.json in:
/home/ark/.config/ark-core/<network>/delegates.json(where you replace <network> with network you operate on (mainnet, devnet, testnet). You can also run command
ark env:pathsto get this information.
Starting the Forger Process
Once you set this up you need to start the Forger process by writing:
When the process has started, you will get a message:
1Starting ark-forger... done
This will initiate and read your passphrase and start the Forger process. You can check Forger logs by writing one of this commands:
1pm2 logs ark-forger2// OR RUN3ark forger:log
If you set it up successfully, after your node is fully synced, you should see an output similar to this, but with your own delegate name and your delegate’s public key:
12|ark-forger | [2019-03-20 12:12:36][DEBUG]: Loaded 1 delegate: undefined (02297e602dcb3e6ee81205e9e0a7754d50cf3791b06b01fb6e9dde17059b1fb1ba)22|ark-forger | [2019-03-20 12:12:36][INFO]: Forger Manager started with 1 forger
This is it — you have now successfully set up a Relay and Forger!