The problem
This short article will show you how to fix a common error in the lxd-to-incus tool, where Incus is unable to start after the migration tool has finished its execution.
Normally you will first see a working migration like in this example:
root@ubuntu:~# lxd-to-incus
=> Looking for source server
==> Detected: snap package
=> Looking for target server
==> Detected: systemd
=> Connecting to source server
=> Connecting to the target server
=> Checking server versions
==> Source version: 5.21.4
==> Target version: 6.0.0
=> Validating version compatibility
=> Checking that the source server isn't empty
=> Checking that the target server is empty
=> Validating source server configuration
The migration is now ready to proceed.
At this point, the source server and all its instances will be stopped.
Instances will come back online once the migration is complete.
Proceed with the migration? [default=no]: yes
=> Stopping the source server
=> Stopping the target server
=> Wiping the target server
=> Migrating the data
=> Migrating database
=> Writing database patch
=> Cleaning up target paths
=> Starting the target serverOnly to then wait 10 minutes for the tool to timeout with the following error:
Error: Failed to start the target server: Failed to run: systemctl start incus.service incus.socket: exit status 1 (Job for incus.service failed because the control process exited with error code.
See "systemctl status incus.service" and "journalctl -xeu incus.service" for details.)The Incus service log shows the reason for this behaviour:
Failed to execute queries from /var/lib/incus/database/patch.global.sql:
No such trigger: on_instance_snaphot_deleteThis specific SQL trigger indeed has a typo (on_instance_snaphot_delete instead of on_instance_snapshot_delete) and is therefore unable to execute properly. This is a known lxd-to-incus migration bug that has already been fixed upstream.
The solution
You have to fix the typo in this SQL file and then guard Incus in case the trigger in question is not yet in place. For that, issue the following two commands:
sed -i 's/on_instance_snaphot_delete/on_instance_snapshot_delete/g' /var/lib/incus/database/patch.global.sql
sed -i 's/^DROP TRIGGER /DROP TRIGGER IF EXISTS /' /var/lib/incus/database/patch.global.sqlNow you can start your Incus daemon again with
systemctl start incusAnd you should be greeted with a working Incus instance:
root@ubuntu:~# systemctl status incus
● incus.service - Incus - Main daemon
Loaded: loaded (/usr/lib/systemd/system/incus.service; indirect; preset: enabled)
Active: active (running) since Wed 2026-03-04 19:14:15 UTC; 5s ago
TriggeredBy: ● incus.socket
Docs: man:incusd(1)
Process: 1451 ExecStartPre=/usr/libexec/incus/incus-apparmor-load (code=exited, status=0/SUCCESS)
Process: 1457 ExecStartPre=/bin/mkdir -p /var/log/incus/ (code=exited, status=0/SUCCESS)
Process: 1459 ExecStartPre=/bin/chown -R root:incus-admin /var/log/incus/ (code=exited, status=0/SUCCESS)
Process: 1462 ExecStartPost=/usr/bin/incus admin waitready --timeout=600 (code=exited, status=0/SUCCESS)
Main PID: 1461 (incusd)
Tasks: 25
Memory: 364.1M (peak: 370.7M)
CPU: 2.366s
CGroup: /system.slice/incus.service
└─1461 /usr/libexec/incus/incusd --group incus-admin --logfile=/var/log/incus/incus.logYou’re welcome.