"The following VM hosts must be removed first:" DHCP assigned a host's address

I’ve a lab setup, in which Intel LXD host is working fine, a RPi4 host running LXD too, has IP 172.16.0.5. Thanks to a missed DHCP setup step, MAAS’s DHCP has assigned the same 172.16.0.5 address to a VM on the Pi. If I now try and delete the VM from MAAS, I get the "The following VM hosts must be removed first: " I can’t delete the VM or Host.
Running lxc on the Pi host, checking all projects, there’s no sign of the VM.
The MAAS GUI shows “Error” in the Machine view, the mouse-over “Failed to query node’s BMC- Pod emk4nd: LXD VM not found.”
Are there any things I can do in postgres to delete these entries? I’d rather not wipe the environment and start over.

Maybe I didn’t miss a step? My /var/snap/maas/common/maas/dhcpd.conf has the following, which matches what I see in the GUI for the Dynamic range.
pool {
# No DHCP snippets for pool
range 172.16.0.191 172.16.0.254;
}

The /var/snap/maas/common/maas/dhcp/dhcpd.leases file only details addresses above 172.16.0.191.

If I click Reconfigure DHCP, I see this:

BOTH are shown as Dynamic. Only last night, a deployed VM got allocated 172.16.0.1:

emerym@x86-ldx-host:~$ lxc list
+-------------+---------+-------------------+------+-----------------+-----------+
|    NAME     |  STATE  |       IPV4        | IPV6 |      TYPE       | SNAPSHOTS |
+-------------+---------+-------------------+------+-----------------+-----------+
| grand-snake | RUNNING | 172.16.0.1 (eth0) |      | VIRTUAL-MACHINE | 0         |
+-------------+---------+-------------------+------+-----------------+-----------+
| juju        | RUNNING | 172.16.0.6 (eth0) |      | VIRTUAL-MACHINE | 0         |
+-------------+---------+-------------------+------+-----------------+-----------+

Have I done something wrong, or is this a bug?

I’ve moved the Pi to a new static address and added it as a KVM host, having removed and reinstalled the LXD snap. With it added, MAAS was happy to delete the problem entry.

This topic was automatically closed 2 days after the last reply. New replies are no longer allowed.