canonical / maas-ansible-playbook

An Ansible playbook for installing and configuring MAAS
Apache License 2.0
44 stars 34 forks source link

maas-dhcpd does not start/work when installing 3.3 on 22.04 from deb #124

Open jklare opened 1 year ago

jklare commented 1 year ago

After a lot of testing, i am now pretty convinced that there is something broken/or missing in the MaaS 3.3 installation when choosing to install from "deb" instead of "snap" (while using the playbooks from the current main branch). The playbook finishes successfully and initially all looks good, but i was not able to make the maas-dhcpd actually start. I have done all the usual "have you tried turning it off and on again" things like rebooting, restarting maas-rackd and regiond, enabling and disabling DHCP for the network again and again... and so on. I am currently not sure what the reason behind this is, but when choosing "snap" as installation method, everything seems to work just fine and exactly as expected (meaning dhcpd starts immediately after enabling DHCP for at least one subnet/vlan).

While debugging, i also found this related ticket: https://discourse.maas.io/t/maas-3-3-dhcdp-process-not-running/6544

yaggen commented 7 months ago

Facing the same problem, done multiple deployments with this ansible playbooks and maas-dhcpd does not start. Tried with deb deployment of version 3.4 and 3.3 with no luck.

Restarting the maas-dhcpd service and then running service maas-dhcpd status displays that the dhcpd-interfaces file is missing

○ maas-dhcpd.service - MAAS instance of ISC DHCP server for IPv4
     Loaded: loaded (/lib/systemd/system/maas-dhcpd.service; enabled; vendor preset: enabled)
     Active: inactive (dead)
  Condition: start condition failed at Thu 2024-01-25 08:44:57 UTC; 1s ago
             └─ ConditionPathExists=/var/lib/maas/dhcpd-interfaces was not met
       Docs: man:dhcpd(8)

If i create that file, then it complains that dhcpd.conf is missing. I do not want to manually write this configuration file so my troubleshooting stops there.

○ maas-dhcpd.service - MAAS instance of ISC DHCP server for IPv4
     Loaded: loaded (/lib/systemd/system/maas-dhcpd.service; enabled; vendor preset: enabled)
     Active: inactive (dead)
  Condition: start condition failed at Thu 2024-01-25 08:47:27 UTC; 1s ago
             └─ ConditionPathExists=/var/lib/maas/dhcpd.conf was not met
       Docs: man:dhcpd(8)`

Any idea where to start solving this in scope of these playbooks?

SK1Y101 commented 7 months ago

This is a potentially hacky solution, but the maas snap creates both of these files If you're willing to try copying those into the deb environment? (I can't guarantee this will work, I've not tried it)

dincercelik commented 2 months ago

This bug occurs on 3.4/5 deb setup too.