MAAS needs to write power off jobs to to systemd units instead of upstart

Bug #1432828 reported by Andres Rodriguez
14
This bug affects 2 people
Affects Status Importance Assigned to Milestone
MAAS
Fix Released
Critical
Unassigned

Bug Description

/etc/maas/templates/commissioning-user-data/user_data_disk_erasing.template: cat >/etc/init/maas-poweroff.conf <<EOF
/etc/maas/templates/commissioning-user-data/user_data_poweroff.template: cat >/etc/init/maas-poweroff.conf <<EOF
/etc/maas/templates/commissioning-user-data/user_data.template: cat >/etc/init/maas-poweroff.conf <<EOF
/etc/maas/preseeds/enlist_userdata: cat >/etc/init/maas-poweroff.conf <<EOF

Related branches

Changed in maas:
importance: Undecided → Critical
summary: - MAAS needs to write power off jobs to upstart to systemd units
+ MAAS needs to write power off jobs to to systemd units instead of
+ upstart
Changed in maas:
status: New → Triaged
milestone: none → next
Revision history for this message
Scott Moser (smoser) wrote :

just copying comment from the bug i opened.

$ grep -r etc.init etc/ contrib/
etc/maas/templates/commissioning-user-data/user_data_disk_erasing.template: cat >/etc/init/maas-poweroff.conf <<EOF
etc/maas/templates/commissioning-user-data/user_data_poweroff.template: cat >etc/init/maas-poweroff.conf <<EOF
etc/maas/templates/commissioning-user-data/user_data.template: cat >/etc/init/maas-poweroff.conf <<EOF
contrib/preseeds_v2/enlist_userdata: cat >/etc/init/maas-poweroff.conf <<EOF

Those are all places where maas writes a upstart job via cloud-init executed user-data.
Those will simply not execute in vivid now without upstart.

The result in all of those cases is that maas doesn't turn off or reboot.

In all cases, all maas really does is something like:
cat > /etc/init/maas-poweroff.conf <<EOF
   description "poweroff when maas task is done"
   start on stopped cloud-final
   console output
   task
   script
     [ ! -e /tmp/block-poweroff ] || exit 0
     poweroff
   end script
EOF

so maas will just need to write systemd jobs similarly. Its probably easiest and acceptable to just write both in all cases.

Changed in maas:
status: Triaged → Fix Committed
milestone: next → 1.8.0
Changed in maas:
status: Fix Committed → Fix Released
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Duplicates of this bug

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.