Skip to content

Updating xahaud

The process for updating xahaud varies depending on the install method used, however, all three methods rely on the releases published at https://build.xahau.tech. When updating a validator, hub, or other ‘critical’ infrastructure, please check the network health prior to restarting a server to install an update. It is possible to automate the update process using a crontab entry and an update script, however, administrators are discouraged from doing so, as automatic updates may result in restarts at times when the network is unstable. Similarly, human presence allows operators to ensure updates are successful, thereby minimizing downtime.

Users should always keep backups of:

  1. The primary configuration file: xahaud.cfg
    • Location varies based on install type.
  2. The trusted validators file: validators-xahau.txt
    • Location is specified in ‘xahaud.cfg’.
  3. The server’s identity credentials: wallet.db
    • Located in the database directory defined in ‘xahaud.cfg’.
  4. Validators must keep their validation private key backed up in a secure, offline location.

Updating xahaud inside a Docker container involves replacing the currently running binary with the new version, downloaded from https://build.xahau.tech. This can be accomplished either by replacing the xahaud binary inside the container or by updating the entire container.


To update the xahaud binary inside a running Docker container:

  1. Download the script: wget https://gist.githubusercontent.com/WietseWind/2ed35d85dcd056d82645de2958934f86/raw/34be773fd6af42e82cc3a21baf70bfb1e2a6c583/update.sh
  2. Edit the script and change the first line to the release version you would like to install.
  3. Run the script: bash ./update.sh
  4. Verify xahaud is running: docker exec xahaud-[mainnet/testnet] xahaud server_info

To replace the current Docker image with a new version, without overwriting databases or configuration files (which are ignored via the .gitignore file):

  1. Navigate to the repository: cd [/path/to/docker-repo]
  2. Update to the latest version git pull
  3. List running Docker containers and note the name of the xahaud container: docker ps
  4. Stop the old xahaud instance: docker stop xahaud-[mainnet/testnet]
  5. Remove the old instance: docker rm xahaud-[mainnet/testnet]
  6. Start the new instance: ./build && ./up

To update a locally installed version of xahaud, simply replace the current binary with a new binary:

  1. Download the new binary from: https://build.xahau.tech
  2. Mark the new binary executable: chmod +x [/path/to/download]
  3. Stop the currently running xahaud instance: /opt/xahaud/bin/xahaud stop
  4. Replace the old binary with the new: mv [/path/to/download] /opt/xahaud/bin/xahaud
  5. Start xahaud: systemctl start xahaud
  6. Verify xahaud is running: /opt/xahaud/bin/xahaud server_info

A script that automates the above steps is available.

Updating the xahaud binary files is essentially the same as the original install instructions:

  1. Remove the currently running version: rm [/path/to/xahaud]
  2. Download the new version: https://build.xahau.tech
  3. Mark the download as executable: chmod 500 [/path/to/xahaud]
  4. Start xahaud: ./[path/to/xahud] --net --conf [/path/to/xahaud.cfg]