InvokeAI running on Intel Arc GPUs using PyTorch XPU (Level Zero), deployed headlessly on Ubuntu 24.04 LXC with systemd
This repo is basically a “what finally worked” script for running InvokeAI on Intel GPUs (Arc or iGPU) using PyTorch XPU on Ubuntu 24.04, inside a Proxmox LXC.
No CUDA.
No Docker.
No fancy setup.
Just: make InvokeAI run on Intel GPU without fighting it for days.
Disclaimer: this is purely vibecoded
I have an intel Arc B50 and too much free time. I like how easy InvokeAI is to use and wanted to see if i can make it work with the Arc.
After a long debugging session with ChatGPT, this script captures everything that was needed, in the order to actually get it working:
- PyTorch XPU
- InvokeAI 6.10
- Intel Arc / iGPU
- Headless Ubuntu 24.04
- Proxmox LXC
So this is:
- ✅ A reproducible install that runs InvokeAI on Intel XPU
- ✅ Headless, systemd-managed, browser UI accessible
- ✅ Tested on Intel Arc (B-series)
- ❌ Not optimized
- ❌ Not officially supported
- ❌ Not guaranteed to survive future InvokeAI releases
The install script (install-invoke-xpu.sh) performs the following:
- Installs Intel GPU userspace:
- Level Zero
- OpenCL ICD
- Media drivers
- Verifies
/dev/dri/renderD*access inside LXC
- Creates a clean Python virtualenv at:
/opt/invokeai-xpu - Forces PyTorch XPU wheels
- Prevents CUDA wheels from being pulled in
- Installs InvokeAI 6.10.0
- Writes a minimal, XPU-safe InvokeAI config
- Applies required runtime patches, including:
- Making
intel_extension_for_pytorch (IPEX)optional - Guarding against missing
torch.xpu.mem_get_info() - Fixing invocation stats crashes when VRAM info is unavailable
- Making
- Creates a systemd service
- Verifies XPU availability at startup
- Runs InvokeAI fully headless
- Exposes the web UI over HTTP
InvokeAI runs on Intel GPU, images generate successfully, and the UI is accessible from a browser.
- InvokeAI cannot accurately detect available VRAM on Intel XPU
(workarounds are applied; generation still works) Generation preview may not update in real timeUI may require a refresh after generation finishesModel downloads may not show progress until refresh- GPU may stay “awake” after generation unless the service is stopped. This keeps fans spinning quite agressively. On Proxomox current workaround is to run
intel_gpu_top -lon host after you want the fans to spin down OR constantly while running Invoke.
- Intel GPU
- XE driver
- GPU passed through to the LXC
- This is what I added to the container config file on the Proxmox host (
/etc/pve/lxc/<id>.conf):
lxc.cgroup2.devices.allow: c 226:0 rwm
lxc.cgroup2.devices.allow: c 226:129 rwm
lxc.mount.entry: /dev/dri/card0 dev/dri/card0 none bind,optional,create=file
lxc.mount.entry: /dev/dri/renderD129 dev/dri/renderD129 none bind,optional,create=file- Ubuntu 24.04 LTS
- Fresh install recommended
- Internet access
- Privileged, nesting
On a clean Ubuntu 24.04 LXC:
git clone https://github.com/Raasu2/invokeai-xpu.git
cd invokeai-xpu
chmod +x install-invoke-xpu.sh
sudo bash install-invoke-xpu.shHuge thanks to MordragT for the original InvokeAI XPU patches. This setup would not exist without that work.