Skip to content

Upgrading hMailServer

chrisholloway5 edited this page Sep 8, 2026 · 35 revisions

Upgrading hMailServer

This page began as a chapter of the 6.2.10 manual and has been corrected for 6.2.24. The Control Panel's pages are grouped differently now, so the paths below use today's groups; the TLS ports 465, 993 and 995 exist only after you create them on the TCP/IP ports page (a fresh install seeds 25, 587, 110 and 143); and everything added since 6.2.10 is in Changes Since 6.2.10. Where a value here disagrees with the Settings Reference, which is generated from the code, the reference is right.

18.1 How upgrades work

hMailServer upgrades in place. The installer stops the service, replaces the program files, upgrades the database schema if needed, and restarts. Your mail, accounts, domains and settings are preserved.

Two things change during an upgrade:

  1. Program files in C:\Program Files\hMailServer\Bin are replaced.
  2. The database schema is upgraded by DBUpdater, which the installer runs automatically. Current schema version: 6031.

Your data directory (the messages) and hMailServer.INI are left alone.

18.2 The upgrade path

The database upgrade chain is continuous from every earlier hMailServer release, on MySQL, MS SQL, PostgreSQL and SQL CE. You do not need to step through intermediate versions:

  5.3.x ┐
  5.4.x ┤
  5.5.x ┼──▶  6.2.27   (DBUpdater walks every intermediate schema step for you)
  5.6.x ┤
  5.7.x ┤
  6.0.x ┤
  6.1.x ┤
  6.2.x ┘
Coming from Path Notes
6.2.x Run the current installer Drop-in; the installer upgrades the database schema as needed (6031 today, see Changes Since 6.2.10)
6.0 / 6.1 Run the current installer Schema upgraded automatically
5.6 / 5.7 Run the current installer Schema upgraded automatically. Read §18.5 — the GUI has changed
5.3 – 5.5 Run the current installer As above. Very old installs: back up first and test the restore
Original hMailServer (unmaintained) Run the current installer This fork is a drop-in successor

18.3 Before you upgrade

  1. Back up. Database, data directory and hMailServer.INI. See chapter 15.
  2. Write down your version. Help → About, or the Control Panel's About page.
  3. Pick a quiet time. The service is down for a minute or two; senders will retry, so nothing is lost, but users will notice.

18.4 Doing it

  1. Download hMailServer-6.2.27-x64.exe.
  2. Run it as administrator.
  3. The installer detects the existing installation and offers to upgrade. Accept.
  4. Keep your existing database settings when asked.
  5. Let it finish, then confirm the service is running.
  6. Open the Control Panel and check About shows the version you just installed (6.2.27 today).
  7. Send a test message in and out.

18.5 Things that changed, and what to do about them

Coming from 5.x or early 6.x, the administration GUI is different.

The classic hMailServer Administrator (hMailAdmin.exe) was retired in 6.2 and its source removed in 6.2.10. It is replaced by the Control Panel (hMailCP.exe), which does everything the old tool did — domains, accounts, aliases, distribution lists, routes, rules, IP ranges, TCP/IP ports and SSL bindings, server settings, status, queue, logs, backup, certificates, scripts and public folders — plus a live dashboard, complete settings coverage and optional two-factor authentication.

  • The navigation tree deliberately mirrors the old Administrator's layout, so muscle memory mostly transfers.
  • Your TOTP secret carries over — the Control Panel uses the same one.
  • The Control Panel needs the .NET 10 Desktop Runtime, which the installer installs silently if missing.

The PHP WebAdmin is gone. It stored the administrator password in plaintext in a PHP session and needed DCOM opened up for the web server account. It was 2008-era unmaintained code. If you used it to administer the server remotely, use the Control Panel instead — it connects to a remote host directly, which is both simpler and safer.

"Administrative tools" means something narrower now. With both old front-ends gone, the component's only job is registering the COM type library so scripts on another machine can administer this server. If you do not script remotely, you do not need it.

18.6 Rolling back

If an upgrade goes wrong:

  1. Uninstall the version you just installed.
  2. Install your previous version.
  3. Restore the database from your backup — this is the essential step, because the schema was upgraded and an older server will refuse a newer schema.
  4. Restore the data directory and hMailServer.INI.

This is why §18.3 step 1 is not optional. Without a database backup there is no rollback.

18.7 Staying up to date

  • Watch the repository on GitHub to be notified of releases.
  • Every release lists exactly what changed and why, and carries SBOMs.
  • Security fixes are called out explicitly in the release notes.
  • Let the server check for you (in the tree after 6.2.27, not yet in a published release). With UpdateCheckEnabled=1 in hMailServer.INI the server reads the project's release feed at startup and then every UpdateCheckHours (default 24), compares the newest release on UpdateChannel (stable, the default, or prerelease) with its own version, and reports a newer one in the application log, on the Control Panel's Server status page, in Status.UpdateState / Status.AvailableVersion over COM and in GET /api/v1/update. The check is off by default; Status.CheckForUpdate and POST /api/v1/update/check run one on demand whether or not it is on.

Home — full index

Start here

1. Install and run

2. Secure it

3. Operate it

4. Extend it

5. Contribute to it

Look it up — from any journey


About this wiki

Clone this wiki locally