For the complete documentation index, see llms.txt. This page is also available as Markdown.

Running the binary

Run an Aleph node on the testnet for validating transactions with these instructions.

File descriptor limit

Since you are not running the node in a docker, there is one additional OS level configuration you have to take care of. The node uses a lot of file descriptors, both for network connections as well as database handling. To check the limit run:

ulimit -Hn

If the returned value is at least 10000 you are set. Otherwise increase the limit to the recommended value by running:

DESCRIPTOR_CONFIG="$USER hard nofile 10000"
sudo echo $DESCRIPTOR_CONFIG >> /etc/security/limits.conf

Relogin and check the limit again to ensure the change took effect.

Run!

First, source the script you created two chapters back and set the config variables:

source set_env.sh

Once all of the variables mentioned in the previous chapters are set, you can start the node with the following command:

aleph-node \
  --validator \
  --enable-pruning \
  --database rocksdb
  --execution Native \
  --database paritydb \
  --name "${NAME}" \
  --base-path "${BASE_PATH}" \
  --pool-limit "${POOL_LIMIT}" \
  --chain "${CHAIN}" \
  --node-key-file "${NODE_KEY_PATH}" \
  --backup-path "${BACKUP_PATH}" \
  --rpc-port "${RPC_PORT}" \
  --ws-port "${WS_PORT}" \
  --port "${PORT}" \
  --validator-port "${VALIDATOR_PORT}" \
  --public-addr "${PUBLIC_ADDR}" \
  --public-validator-addresses "${PUBLIC_VALIDATOR_ADDRESS}" \
  --rpc-cors all \
  --no-mdns \
  --ws-max-connections "${WS_MAX_CONNECTIONS}" \
  --enable-log-reloading \
  --rpc-methods Unsafe \
  --bootnodes "${BOOT_NODES}" \
  --telemetry-url "${TELEMETRY_URL} ${TELEMETRY_VERBOSITY_LEVEL}" > ${LOG_FILE} 2>&1

Further improvements

We recommend restarting the node automatically whenever it crashes. This is a rare occurrence, but were the node to crash you might miss the performance targets for a session and receive lower rewards. You should also set up some monitoring to check whether the node operates correctly – the prometheus endpoint is likely to be useful – including checking for crashloops. The details of such setups are beyond the scope of this guide.

Last updated

Was this helpful?