The supported installation route is HHVM’s APT repository at https://dl.hhvm.com/ubuntu. Before changing APT sources, identify your Ubuntu codename and verify that the repository publishes a matching suite. The official Linux instructions do not confirm Ubuntu 24.04 (codename noble), so a 24.04 VPS must be checked rather than assumed to work. If no Noble repository exists, use the official Docker image or build HHVM from source on a supported distribution.
Need a server to try this on? Antihost offers Linux VPS plans with NVMe storage, full root access and a 14-day free trial.
Check whether your Ubuntu release is supported
HHVM packages are published by Ubuntu suite, so the codename matters more than the marketing version number. Run the check as an administrator:
As an Amazon Associate I earn from qualifying purchases.
What’s actually slowing this PC down?
Pick the symptom - the matching free tool is one click away.
sudo -i
lsb_release -cs
Typical output is a codename such as focal, jammy or noble. The official installation page does not state that noble is supported. Check the repository layout before adding it:
curl -I https://dl.hhvm.com/ubuntu/dists/noble/
Replace noble with the value printed by lsb_release -cs when you are running another Ubuntu release. A missing suite, a 404 response or an APT error saying that the repository has no Release file means the normal package installation cannot proceed for that codename. Do not substitute another Ubuntu codename just to make APT continue; packages built for a different release can have incompatible dependencies.
#1 Best Overall
What you need on the VPS
- Root access, either through
sudo -iorsu -. The official procedure performs repository and package changes as root. - An Ubuntu VPS with working network access to the Ubuntu mirrors and
dl.hhvm.com. - The APT repository helper packages used by the official guide. Install those before importing the signing key; the exact helper command can vary with the Ubuntu image you selected.
- The system codename from
lsb_release -cs, so the source entry matches the operating system.
Older web tutorials often target Ubuntu 14.04 through 20.04 and use apt-key. Treat their repository lines and version claims as historical, not as evidence that the same instructions support your current VPS.
Install HHVM from the official APT repository
1. Open a root shell
sudo -i
If your account does not have sudo access, switch to root with:
Recommended Free Tools
su -
Every command below assumes that root shell. If you remain in a normal shell, prefix administrative commands with sudo.
2. Install the repository helper packages
Run the helper-package command shown in the official HHVM Linux guide before adding the source. This step supplies the APT, HTTPS and key-management support required by the following operations. On a minimal VPS image, omitting it commonly causes the key or repository command to fail before HHVM itself is considered.
Rank #2
3. Import HHVM’s signing key
The official guide documents this keyserver command:
apt-key adv --keyserver keyserver.ubuntu.com --recv-keys B4112585D386EB94
Newer Ubuntu releases may warn that apt-key is deprecated or may not include it by default. The HHVM guide also describes an alternative key-import method for that case; use that documented alternative rather than downloading an unverified key from a third-party site. A successful import should complete without an unknown-key or signature error.
4. Add the HHVM source for your codename
Create an APT source entry that uses the codename reported by your VPS:
CODENAME="$(lsb_release -cs)"
echo "deb https://dl.hhvm.com/ubuntu ${CODENAME} main" > /etc/apt/sources.list.d/hhvm.list
The repository URL is https://dl.hhvm.com/ubuntu. Inspect the file if you want to confirm the result:
cat /etc/apt/sources.list.d/hhvm.list
It should contain the expected codename, not a hard-coded value copied from a different tutorial or a different VPS.
5. Refresh package metadata
apt update
This is the first decisive compatibility test. A successful run downloads HHVM metadata for your Ubuntu suite. Stop if APT reports that the suite is missing, has no Release file, or cannot verify the repository signature; troubleshooting those messages is covered below.
Windows Errors? Fix Them Before They Spread
Repair common Windows errors and clear accumulated junk for a smoother, more stable PC - no reinstall needed.Free scan · no reinstallOutdated Drivers Are Slowing You Down
One free scan finds every outdated or missing driver and matches the right update for your exact hardware.Free scan · exact hardware match6. Install the main package
apt install hhvm
The primary runtime package is named hhvm. Accepting the transaction installs the version selected by the repository and your normal APT policy.
7. Verify the executable and version
hhvm --version
The command should print HHVM version information and return to the shell without an error. This verifies that the binary is installed and available on the root user’s PATH. It does not, by itself, configure a web server, application, virtual host or process manager; those are separate deployment tasks.
Rank #4
Choose a stable line and understand version pinning
The HHVM repository can be targeted at a major.minor line. When you pin that line in the repository entry, patch releases within it arrive through normal APT updates, but APT does not automatically move you to the next minor line. The official documentation uses the 4.56 series as an example: a later 4.56 patch such as 4.56.1 is included, while 4.57 and newer minor lines are not.
Use the exact major.minor repository syntax shown in the current HHVM guide when you need that behavior. Keep the codename and the HHVM line together; changing only one can make APT select an unintended package set. If you leave the repository on the general stable channel, future repository changes can select a newer minor series according to the repository’s publication and APT’s version rules.
- Use the general stable entry when you want the repository’s current stable line and have a process for testing upgrades.
- Pin a major.minor line when application compatibility requires a known series. You still receive security and bug-fix patch releases published within that series.
- Do not infer a current release number from an old tutorial. A third-party tutorial mentioning HHVM 4.110.0 is not a verified current version claim.
Packages provided by the repository
| Package | What is established |
|---|---|
hhvm |
The main HHVM package used for a normal installation. |
hhvm-dbg |
Listed by the documentation; the guide does not define an installation scenario for it. |
hhvm-dev |
Listed by the documentation; the guide does not define an installation scenario for it. |
hhvm-nightly |
A nightly package listed by the documentation rather than the normal stable package. |
hhvm-nightly-dbg |
A nightly debug package listed by the documentation. |
hhvm-dev-nightly |
A nightly development package listed by the documentation. |
For a production-style VPS installation, start with hhvm. Choose a debug, development or nightly package only when you have a specific reason and have checked the version and support implications for your application.
Troubleshoot common installation failures
“The repository does not have a Release file” or a 404 for the suite
This means the repository did not publish metadata for the codename in your source entry. Re-run lsb_release -cs and compare it with the path you tested. If the result is noble and https://dl.hhvm.com/ubuntu/dists/noble/ is absent, the official APT route is not established for Ubuntu 24.04. Remove or disable the unusable source rather than pointing Noble at another Ubuntu release, then select Docker or a source build.
Best Value
“Unable to locate package hhvm”
- Confirm that
/etc/apt/sources.list.d/hhvm.listcontains the intended codename and the URLhttps://dl.hhvm.com/ubuntu. - Run
apt updateagain and read the output for a repository, signature or suite error. - Check that the repository actually publishes packages for that codename. A successful command in step 3 does not guarantee that every Ubuntu release has an HHVM package.
- Only after metadata downloads successfully, retry
apt install hhvm.
Signature or NO_PUBKEY errors
APT is refusing to trust the repository metadata. Recheck the documented key import, including key ID B4112585D386EB94, and use the current alternative method from the HHVM guide if apt-key is missing or rejected. Do not bypass signature verification with insecure APT options.
Do these 3 things before closing this tab:
1Fix the driver behind crashes, sound loss and screen glitches2Clear out junk files and repair common Windows errors3Scan for outdated or missing drivers - takes under a minuteThe keyserver command fails
Keyservers can be unreachable from a VPS or blocked by network policy. The official page notes an alternative import procedure for this failure. Use that procedure, then run apt update and confirm that the signature error has gone before installing packages.
“hhvm: command not found” after installation
First check whether the installation completed and whether APT selected the package:
apt policy hhvm
command -v hhvm
hhvm --version
If apt policy shows no candidate, the problem is repository metadata rather than your shell. If a candidate is present but installation was interrupted, complete the package transaction and run the verification command again. Do not download a random binary to compensate for a missing repository package.
What to do when Ubuntu 24.04 packages are unavailable
Use the official Docker image
The official HHVM documentation provides a Docker route. It is the most direct fallback when the host’s Ubuntu codename is not represented in the APT repository, because the container carries the userspace environment expected by its image. Follow the current Docker instructions from HHVM’s official documentation and keep the host application, volume and network configuration separate from the host’s APT packages.
Quick wins for a faster PC:
Clear out junk files and repair common Windows errorsFree Scan →Scan for outdated or missing drivers - takes under a minuteDriver Scan →Build HHVM from source
HHVM’s source-build documentation limits supported builds to distributions for which HHVM makes binaries and warns that compilation requires several gigabytes of RAM. A small VPS can therefore fail or become unusable during the build even when the source itself is correct. Confirm that your Ubuntu release is within the documented support set, provision enough memory, and follow the matching build dependencies and steps from the official build guide.
Be cautious with unofficial Noble scripts
Community scripts exist that target Ubuntu 24.04 nightly builds, but they are not official packages. They can change repository keys, compiler settings or system libraries outside the normal support path. Treat them as experimental and do not use them for a production VPS unless you can audit, reproduce and maintain the entire build.
Quick Recap
Keep the installation maintainable
- Record the Ubuntu codename and the HHVM major.minor line in your deployment notes.
- Keep the source file in
/etc/apt/sources.list.d/hhvm.listso it is easy to audit or disable. - Run
apt updatebefore upgrades and read warnings instead of ignoring them. - After an upgrade, rerun
hhvm --versionand test the application that depends on HHVM. - Do not mix stable, nightly and manually built packages on the same host without a rollback plan.
Installation decision checklist
- Identify the release: run
lsb_release -cs. - Check the suite: inspect
https://dl.hhvm.com/ubuntu/dists/<codename>/for the actual codename. In shell documentation, replace the angle-bracket expression with the value printed bylsb_release; do not paste the brackets literally. - Choose the channel: use the stable repository or pin a documented major.minor line.
- Prepare trust: install the guide’s helper packages and import key
B4112585D386EB94. - Add and refresh: write the source entry, run
apt update, and resolve every error. - Install and verify: run
apt install hhvm, thenhhvm --version. - Fallback cleanly: if the suite is unavailable, remove the unusable source and use the official Docker image or a supported source build.
Product prices and availability are accurate as of the date/time indicated and are subject to change. Any price and availability information displayed on Amazon at the time of purchase will apply.




