LXD refuses to start after ARCH-OS-Upgrade, complains about YAML-Issue


I updated my Arch Linux installation today after quite a long time.
Sadly now LXD refuses to start. In the logs, I can see the following error:

level=error msg="Failed to start the daemon" err="Failed applying patch \"dnsmasq_entries_include_device_name\": Could not read pid file: Unable to parse Process YAML: yaml: unmarshal errors:\n line 1: cannot unmarshal !!int 1876 into subprocess.Process"

So far I was not able to spot the YAML-File that it tries to load. Therefore I have to way of checking, if there is an actual syntax error in.

I am trying to run lxd in version 5.3.

My Linux-Version:
Linux archlinux5.18.6-arch1-1 #1 SMP PREEMPT_DYNAMIC Wed, 22 Jun 2022 18:10:56 +0000 x86_64 GNU/Linux

Any ideas, where I can look for the issue?

Thanks a lot

What does /var/lxd/networks/<network_name>/dnsmasq.pid contain for each network?

cat /var/lib/lxd/networks/lxdbr0/dnsmasq.pid

Awesome. That’s where 1876 comes from.

I checked

ps aux | grep 1876

And it looks like, no process is owning this pid.
(I guess that makes sense, because after a reboot, LXD never started).

Is it safe to just delete this file and lxd will recreate it, does does it require an actual dnsmaq-process running, in order to start?

Yeah try deleting that file and see if that fixes it, it looks like you have a very old leftover pid file that is in the old format.

I’ve improved the errors for those who come across this issue in the future:

That worked, thank you so much.

1 Like