Software update

From Halon, SMTP software for hosting providers
Jump to: navigation, search
By completely overwriting the system partition from an update partition, updates are quick and reliable

Halon SMTP software nodes are updated with a single click (or halonctl). This is generally considered much more convenient than what many system administrators are used to; having to update many small software components in several different systems, worrying about regressions or broken dependencies. By completely overwriting the system partition from a recovery partition, updates are quick and reliable.

Software updates are released on regular basis with no strict schedule to allow fast updates when necessary. There's an RSS feed on the release note page.

Software update

In practice, performing an update is no more complicated than pressing a button in the web administration, and waiting. However, in order to be prepared for the unexpected, following the guidelines below are recommended.

  • Read the release notes
  • Dedicate a possible maintenance window of at least an hour, even though the process typically takes 5 minutes
  • Be prepared to access the console in case of failure
  • Make an external backup (export; copy-paste for example) of your configuration before updating
  • If you're using a virtualised system, take a snapshot of the machine (and merge the snapshot after verifying that it works)

Online update

To perform an online update, go to the Operations > Software update page, select the hosts that you would like to update, press the install button to start the update.

Offline update

To peform an offline update over SSH (with root access), start by placing the latest image on your storage partition with e.g. FTP or SCP

# cd /storage/
# ftp http://192.168.0.1/halon-sp-image-x.x-amd64

then run the following command to initiate the update process, reboot the device to apply the update

# updated --install halon-sp-image-x.x-amd64
Update instructions ready for next reboot
# reboot

Technical description

Under the hood, the complete software update cycle consists of the following steps.

  1. Download is requested by the SOAP call updateDownloadStart
    • The updated process
      • Queries dl.halon.se/sp/version/?version=3.4... for software update information
      • Downloads the update file (tarball) to /storage/halonrecoveryimage and verifies it
  2. Installation is requested by the SOAP call updateInstall
    • The updated process
      • Writes an "update instruction" file to /cfg
      • Reboots
    • The boot loader detects the update instruction file, and boots the recovery OS
    • The recovery OS
      • Reads the update instruction file and start in non-interactive mode
      • Mounts the disk specified in the update instruction
      • Checks so that the specified update file exists
      • Erases the system partition
      • Extracts the update file to the system partition
      • Removes the update instruction file
      • Reboots
    • The system returns to normal operation, using the new software release