XCP-ng needs guest tools inside each Linux VM so the hypervisor can see the guest OS, report metrics to Xen Orchestra, and perform clean shutdowns or live migrations. On Ubuntu, that usually means installing xe-guest-utilities—the management agent (xe-daemon) plus xe-linux-distribution. Paravirtual drivers are already in the kernel; you are adding the agent, not replacing the whole kernel stack.
This guide covers how to install XCP-ng guest tools on Ubuntu: the fast apt path, installation from the guest-tools ISO (when apt is missing or outdated), service checks, and what to expect when you are not running inside an XCP-ng VM. I ran these steps on Ubuntu 25.04 and simulated the ISO installer with the same install.sh flow Xen Orchestra mounts from guest-tools.iso.
Tested on: Ubuntu 25.04 (Plucky Puffin); kernel 6.14.0-37-generic.
Quick command summary
| Task | Command |
|---|---|
| Install from Ubuntu repos | sudo apt update && sudo apt install -y xe-guest-utilities |
| Check package version | apt-cache policy xe-guest-utilities |
| Check service (inside XCP-ng VM) | systemctl status xe-daemon.service |
| Mount guest-tools ISO | sudo mount /dev/cdrom /mnt |
| Install from ISO | sudo bash /mnt/Linux/install.sh |
| Force ISO install (unknown derivative) | sudo bash /mnt/Linux/install.sh -d ubuntu -m 24 -n |
| Unmount ISO | sudo umount /mnt |
| Remove tools | sudo apt purge -y xe-guest-utilities |
What XCP-ng guest tools do on Ubuntu
XCP-ng documentation splits guest support into two layers for Linux:
| Layer | Provided by | Purpose |
|---|---|---|
| PV drivers | Linux kernel (built-in for years) | Fast disk and network I/O on Xen |
| Management agent | xe-guest-utilities package |
OS name, IP, memory and disk stats, graceful power operations |
Without the agent, Xen Orchestra may show Management agent not detected even though the VM runs fine. With tools installed and xe-daemon running, you typically see OS details, memory graphs, and working Shutdown / Reboot buttons from the control plane.
The Ubuntu package installs:
/usr/sbin/xe-daemon— periodic XenStore updates/usr/sbin/xe-linux-distribution— writes distro identity at bootxe-daemon.service— systemd unit (enabled on install)
Prerequisites
Inside your Ubuntu guest VM on XCP-ng:
- Network access to Ubuntu mirrors (for
apt) or the guest-tools ISO attached from Xen Orchestra /xe. - sudo for package install and ISO mount.
- universe enabled if
aptcannot find the package (sudo add-apt-repository universe).
On the hypervisor (Xen Orchestra):
- Select the VM → Console or Advanced.
- Attach
guest-tools.iso(sometimes labeled XCP-ng VM Tools).
For ISO mounting inside the guest, you need a free mount point such as /mnt—same idea as mounting removable media.
Method 1: Install XCP-ng guest tools with apt (recommended)
This is the easiest way to install XCP-ng tools on Ubuntu when universe ships xe-guest-utilities.
Install the package
sudo apt update
sudo apt install -y xe-guest-utilitiesOn Ubuntu 25.04:
Get:1 http://archive.ubuntu.com/ubuntu plucky/universe amd64 xe-guest-utilities amd64 7.20.2-0ubuntu1 [765 kB]
Selecting previously unselected package xe-guest-utilities.
Unpacking xe-guest-utilities (7.20.2-0ubuntu1) ...
Setting up xe-guest-utilities (7.20.2-0ubuntu1) ...
Created symlink '/etc/systemd/system/multi-user.target.wants/xe-daemon.service' → '/usr/lib/systemd/system/xe-daemon.service'.Confirm:
apt-cache policy xe-guest-utilities
dpkg -l xe-guest-utilities
systemctl is-enabled xe-daemon.serviceInstalled: 7.20.2-0ubuntu1
ii xe-guest-utilities 7.20.2-0ubuntu1 amd64 daemon for monitoring Xen Virtual machines
enabledThe apt package enables xe-daemon.service automatically. You do not need a separate systemctl enable on Ubuntu.
Verify inside an XCP-ng VM
On a real XCP-ng guest, after install (reboot if Xen Orchestra still shows the old state):
systemctl status xe-daemon.service --no-pager
ls /proc/xen/capabilitiesYou want Active: active (running) and a readable /proc/xen/capabilities file.
What happens on a non-Xen machine
I also ran this on a regular Oracle VM outside XCP-ng. The package installs, but systemd skips the daemon:
○ xe-daemon.service - Xen Guest Monitoring Agent
Active: inactive (dead)
Condition: start condition unmet
└─ ConditionPathExists=/proc/xen/capabilities was not metThat is expected. Do not treat a skipped service on KVM or VirtualBox as a failed install—only an XCP-ng/Xen guest has /proc/xen.
Method 2: Install from the XCP-ng guest-tools ISO
Use the ISO when:
apt-cache policy xe-guest-utilitiesshows no candidate (some interim Ubuntu releases, or right after a new LTS launch).- Xen Orchestra reports an older agent than the tools bundled with your XCP-ng host (forum reports often cite ISO 7.30.x vs Ubuntu apt 7.20.2).
- You upgraded Ubuntu in-place and want the installer script’s sysctl and udev tweaks.
Attach and mount the ISO
In Xen Orchestra, mount guest-tools.iso on the VM. Inside Ubuntu:
sudo mkdir -p /mnt
sudo mount /dev/cdrom /mnt
ls /mnt/You should see at least:
Linux README.txtIf /dev/cdrom is missing, try /dev/sr0 or check lsblk for the virtual CD drive.
Run the installer
sudo bash /mnt/Linux/install.shAnswer y when prompted, or use non-interactive mode:
sudo bash /mnt/Linux/install.sh -nOn my host, simulating the ISO layout with install.sh auto-detection produced:
Detected `Ubuntu 25.04' (ubuntu version 25).
The following changes will be made to this Virtual Machine:
* update arp_notify sysctl.
* packages to be installed/upgraded:
- xe-guest-utilities_7.20.2-0ubuntu1_amd64.deb
Selecting previously unselected package xe-guest-utilities.
Unpacking xe-guest-utilities (7.20.2-0ubuntu1) ...
Setting up xe-guest-utilities (7.20.2-0ubuntu1) ...
Created symlink '/etc/systemd/system/multi-user.target.wants/xe-daemon.service' → '/usr/lib/systemd/system/xe-daemon.service'.Unmount and eject:
sudo umount /mntDetach the ISO from Xen Orchestra so the VM does not boot from the virtual CD on next start.
Force install when detection fails
For derivatives the script does not recognize:
sudo bash /mnt/Linux/install.sh -d ubuntu -m 24 -nReplace 24 with your Ubuntu major version (22 for 22.04 LTS, 24 for 24.04 LTS, 25 for 25.04).
xe-guest-utilities in the archive; it was added later via jammy-updates. If apt install still fails on an old mirror, use the ISO path above—forum threads confirm both methods work on 22.04 VMs.
Confirm tools in Xen Orchestra and on the host
Xen Orchestra (GUI)
Open the VM → General tab:
- Management agent detected (or a version string) — agent is running
- PV drivers detected — paravirtual drivers active (Linux guests usually yes once tools are healthy)
If the agent line stays red after install, reboot the VM once and refresh the view.
XCP-ng host CLI
On the hypervisor (not inside Ubuntu):
xe vm-param-get param-name=PV-drivers-detected uuid=<VM-UUID>
xe vm-param-get param-name=PV-drivers-version uuid=<VM-UUID>PV-drivers-version should be non-empty when the management agent reports in.
Optional: xenstore-utils inside the guest
xe-guest-utilities does not ship the xenstore-read CLI. For debugging inside a Xen VM you can install:
sudo apt install -y xenstore-utils
xenstore-read nameOn a non-Xen test host:
xenstore-read: xs_open: No such file or directoryThat error simply means you are not on a Xen guest—normal outside XCP-ng.
Upgrade, reinstall, and remove
Upgrade via apt
sudo apt update
sudo apt install --only-upgrade xe-guest-utilitiesReinstall from ISO over apt
Remove the Ubuntu package first only when the ISO installer conflicts; usually you can run install.sh directly and it upgrades in place:
sudo apt install --reinstall xe-guest-utilitiesUninstall
sudo apt purge -y xe-guest-utilities
systemctl is-enabled xe-daemon.serviceAfter purge, is-enabled should report not-found or disabled.
Troubleshooting
| Symptom | Likely cause | Fix |
|---|---|---|
Unable to locate package xe-guest-utilities |
universe off or unsupported interim release | sudo add-apt-repository universe && sudo apt update; else use ISO |
xe-daemon skipped / inactive |
Not running under Xen | Expected off XCP-ng; inside VM, check /proc/xen exists |
| Management agent not detected in XO | Service not started or stale UI | sudo systemctl restart xe-daemon; reboot VM |
mount: /mnt: wrong fs type on ISO |
CD not attached | Attach guest-tools.iso in XO; try /dev/sr0 |
install.sh cannot detect distro |
Unknown derivative | install.sh -d ubuntu -m <major> -n |
| Clean shutdown still forced | No agent communication | Confirm xe-daemon active; reinstall tools |
| apt version older than XCP-ng ISO | Ubuntu lags upstream | Install from guest-tools ISO for newer build |
References
- XCP-ng VMs and guest tools documentation
- XCP-ng forum: xe-guest-utilities on Ubuntu 22.04
- xcp-ng/xe-guest-utilities (GitHub)
- Launchpad: xe-guest-utilities source
Summary
To install XCP-ng guest tools on Ubuntu, run sudo apt install xe-guest-utilities when the package exists in universe—on current releases that pulls 7.20.2 and enables xe-daemon.service. When apt is empty or too old, attach guest-tools.iso from Xen Orchestra, mount /dev/cdrom /mnt, and run bash /mnt/Linux/install.sh. Inside a real XCP-ng VM, systemctl status xe-daemon should show active (running) and Xen Orchestra should report the management agent. Off Xen hardware the service stays skipped, which is normal.









