Updating
Update HF Panel from Server Admin or the command line, switch on automatic updates, and what an update changes and keeps.
New versions of HF Panel install in place. Accounts, websites, email, databases and settings are kept, and the panel stays reachable during the update.
Where: Server Admin › Server › HF Panel updates
Update from the panel
The HF Panel updates screen shows the Installed version, the Newest version, when it Last checked, and the release notes of the new version.
- Click Check now to look for a new version straight away.
- Read the notes, then click Update now.
- The update runs in the background. The page shows "An update is running — this page refreshes by itself." and reloads when it is done.
The update downloads the signed release, checks its signature and runs it. Updates started from the panel are logged
in /var/log/hostfog-selfupdate.log.
Automatic updates
Under Automatic updates, tick Install new versions automatically at night and click Save. New versions then install every night at 03:20.
When automatic updates are off, the administrator gets an email when a new version is out, and installs it from this screen.
Update from the command line
Run the install command again, as root:
cd /home && curl -o latest -L https://get.hostfog.io/latest && bash latest
On a server that already has HF Panel, this updates it to the newest release with your saved settings. Licensed
servers may pass their key: bash latest --licence HFL-XXXXX-XXXXX-XXXXX-XXXXX. Other installer options are ignored
on an update.
What an update does
- Checks that it runs as root on a server with HF Panel, and that the new program runs on this machine. If not, it stops with the reason and nothing changes.
- Refuses to install an older version over a newer one.
- Replaces the program files. The previous ones are kept until the end, so a failed update leaves a complete old copy behind.
- Applies this release's server fixes, upgrades the panel database and rewrites every website's web server settings.
- Restarts the panel without a gap, reloads PHP and Nginx, and waits until the panel answers again.
It also adds the new features' software when needed, for example the MongoDB databases service or the backup tools.
Accounts, websites, email, databases, the panel database and every setting are kept. Customers' websites keep running throughout.
Note: an update never installs an older version. To force one, set
HOSTFOG_ALLOW_DOWNGRADE=1, but an older version cannot undo database changes a newer one made. To go back, restore the provider snapshot you took before the update.
Read the update's messages
The update prints what it changed and what you should do. The most common messages:
| Message | What to do |
|---|---|
Reverse DNS (PTR) of … The mail server is now called mail.yourdomain.com — set the PTR … |
Set the reverse DNS of the server's IP to the name shown, at your server provider. |
The mail server's new name is …: add the DNS records of mail., smtp. and imap. … |
Add the records (hf-panel dns-setup). Mail moves to the new names by itself once they point at the server. |
HF Studio has its own address: https://db.yourdomain.com/ … |
Add the db. A record. |
The API has its own address: https://api.yourdomain.com/v1 … |
Add the api. A record and open port 2087 in your provider's firewall. |
Apache is not running … |
Run hf-panel apache-fix. |
This server already has HF Panel …, newer than … — nothing to do |
The server is already up to date. |
Before a big update
For an update that changes how the server works (read the release notes), or on a busy server:
- Make a copy of the panel's data:
hf-panel panel-backup. - Take a snapshot of the server at your provider, while it is quiet.
- Update a test server first, then the least busy live server, then the rest one at a time.
- After each update, run
hf-panel health, sign in to each panel and HF Mail, open a customer website and send yourself an email.
Important: with more than one server, update the main server first, then the extra servers. A main server refuses to move accounts to a server that runs an older version.
Updating to 1.0.0
Updating from an earlier release moves the server to its new names:
- HF Studio moves to
db.yourdomain.com. - The mail server is
mail.yourdomain.com(the MX), withsmtp.yourdomain.comandimap.yourdomain.comfor mail apps. The oldmx.yourdomain.comis removed once no domain with its DNS elsewhere still uses it as its MX; the update and Server health list any that do. - The API is at
https://api.yourdomain.com:2087/v1. Open port 2087. - The panels stay at
server.,panel.andreseller.yourdomain.com:8443; those names without the port send visitors to your website.
Add the new DNS records (hf-panel dns-setup) and change the server IP's reverse DNS (PTR) to mail.yourdomain.com.
Older addresses used by programs, such as https://panel.yourdomain.com:8443/api/v1, keep working.
Upgrading the operating system
Upgrading the operating system in place (for example Ubuntu 22.04 to 24.04, or Debian 12 to 13) isn't tested. The safe way is a new server with the newer release and HF Panel, then Move accounts from the old server to the new one.