Comment 2 for bug 985755

Revision history for this message
James Hunt (jamesodhunt) wrote :

= Impact =

If this fix is not applied to Precise, users upgrading from lucid will see errors relating to bug 984474 ("initctl crashed with SIGABRT in nih_error_clear()") as the installer proceeds to upgrade packages containing Upstart services. These services will not be restarted as they should be once the new package version is installed. However, the services will be restarted on reboot.

Users on Oneiric should not experience this issue (since 'initctl show-config' is available on oneiric).

= Development Fix =

The bug has been addressed by modifying /lib/init/upstart-job to only consider a service disabled if both of the following are true:

1) The version of Upstart currently running supports querying of a jobs 'start on' condition (via the 'initctl show-config' command).

2) Upstart reports that no 'start on' condition exists for the job.

Links to the script /lib/init/upstart-job are installed in /etc/init.d/ such that administrators are able to manipulate Upstart jobs as if they were SystemV services (using for example "/etc/init.d/foo restart" or even "service restart").

= Stable Fix =

A patch to /lib/init/upstart-job is attached.

Note that this patch also includes a fix to correct restart handling in lucid: it now stops and then starts the Upstart job rather than just calling "restart" which does *not* reload the job configuration.

= Test Case =

To observe the bug on a lucid system:

1) Check that your Upstart jobs are running (a good example is 'cron'):
   ('/etc/init.d/cron' status, or 'status cron')
2) Upgrade lucid to precise using update-manager(8) or do-release-upgrade(8).
3) Observe errors relating to the initctl(8) command either on-screen or in the installer logs under /var/log/installer/.
4) After the upgrade has completed, observe that your services are no longer running
   ('/etc/init.d/cron' status, or 'status cron').

To be convinced the bug is fixed on a lucid system, a new version of /lib/init/upstart-job is required. Once installed:

1) Check that your Upstart jobs are running (a good example is 'cron'):
   ('/etc/init.d/cron' status, or 'status cron')
2) Upgrade lucid to precise using update-manager(8) or do-release-upgrade(8).
3) There should be no errors relating to the initctl(8) command either on-screen or in the installer logs under /var/log/installer/.
4) After the upgrade has completed, observe that your services are still running as expected
   ('/etc/init.d/cron' status, or 'status cron').

= Regression Potential =

No regression potential.