service_pause and service_resume do not work as documented on systemd

Bug #1692178 reported by Paul Gear
8
This bug affects 1 person
Affects Status Importance Assigned to Milestone
Charm Helpers
Fix Released
Undecided
Unassigned

Bug Description

The documentation for service_pause() is documented as:

"Pause a system service. Stop it, and prevent it from starting again at boot."

This is not accurate, because service_pause stops the service and prevents it from starting at all, both on boot and when called manually.

Similarly, service_resume() is documented as:

"Resume a system service. Reenable starting again at boot. Start the service."

However, if a service is disabled, running service_pause() and service_resume() will not cause the service to be enabled at boot.

This behaviour is due to service_pause/resume using systemctl mask/unmask rather than disable/enable as it does for other init systems.

Related branches

Paul Gear (paulgear)
Changed in charm-helpers:
status: New → Fix Committed
Changed in charm-helpers:
status: Fix Committed → Fix Released
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

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