mysql upstart job must depend on upstart >= 0.6.7-2

Bug #907465 reported by Cristian Petcu
18
This bug affects 3 people
Affects Status Importance Assigned to Milestone
debhelper (Ubuntu)
Invalid
Undecided
Unassigned
mysql-5.5 (Ubuntu)
Fix Released
Medium
Clint Byrum

Bug Description

Description: Ubuntu precise (development branch)
Release: 12.04

ProblemType: Package
DistroRelease: Ubuntu 12.04
Package: mysql-server-5.5 5.5.17-4ubuntu6
ProcVersionSignature: Ubuntu 3.2.0-4.10-generic 3.2.0-rc5
Uname: Linux 3.2.0-4-generic i686
ApportVersion: 1.90-0ubuntu1
AptOrdering:
 mysql-server-5.5: Install
 mysql-server: Install
 mysql-server-5.5: Configure
 mysql-server: Configure
Architecture: i386
Date: Wed Dec 21 19:54:18 2011
ErrorMessage: subprocess installed post-installation script returned error exit status 1
SourcePackage: mysql-5.5
Title: package mysql-server-5.5 5.5.17-4ubuntu6 failed to install/upgrade: subprocess installed post-installation script returned error exit status 1
UpgradeStatus: Upgraded to precise on 2011-12-14 (6 days ago)

Revision history for this message
Cristian Petcu (cristian-petcu) wrote :
tags: removed: need-duplicate-check
Revision history for this message
Clint Byrum (clint-fewbar) wrote :

Hello Cristian, it seems mysqld failed to start. Can you please attach /var/log/mysql/* to this bug report so we can try to see any errors?

Thanks!

Changed in mysql-5.5 (Ubuntu):
importance: Undecided → High
status: New → Incomplete
Revision history for this message
Alastair Porter (alastairporter) wrote :

I got this error upgrading as well. Error files in /var/log/mysql were empty. The problem seems to be the line
    /lib/init/apparmor-profile-load usr.sbin.mysqld
in the startup script /etc/init/mysql.conf

since when I run it manually:
root@brixton:/root# /lib/init/apparmor-profile-load usr.sbin.mysqld
bash: /lib/init/apparmor-profile-load: No such file or directory

After commenting out this line, apt-get -f install continues as expected.

Revision history for this message
Alastair Porter (alastairporter) wrote :

After some further digging I found https://bugs.launchpad.net/ubuntu/+source/upstart/+bug/692801

I also note that my version of upstart was upgraded *after* mysql:
Preparing to replace upstart 0.6.5-8 (using .../upstart_1.4-0ubuntu2_i386.deb)

I'm upgrading from Lucid LTS server, by changing sources.list / apt-get dist-upgrade.

Revision history for this message
Clint Byrum (clint-fewbar) wrote :

Nice job tracking down the problem Alastair. I believe the problem lies in debhelper then, as dh_apparmor needs to add a misc:Depends on upstart >= 0.6.7-2.

Changed in mysql-5.5 (Ubuntu):
status: Incomplete → Triaged
summary: + dh_apparmor needs to add misc:Depends on upstart >= 0.6.7-2 (was:
package mysql-server-5.5 5.5.17-4ubuntu6 failed to install/upgrade:
subprocess installed post-installation script returned error exit status
- 1
+ 1)
Revision history for this message
Clint Byrum (clint-fewbar) wrote : Re: dh_apparmor needs to add misc:Depends on upstart >= 0.6.7-2 (was: package mysql-server-5.5 5.5.17-4ubuntu6 failed to install/upgrade: subprocess installed post-installation script returned error exit status 1)

Hrm, I was mistaken, on investigation, dh_apparmor's added postinst actually doesn't cause this issue, the upstart job included in mysql does, so this is just a mysql issue.

tags: added: lucid2precise
Changed in debhelper (Ubuntu):
status: New → Invalid
Changed in mysql-5.5 (Ubuntu):
status: Triaged → In Progress
assignee: nobody → Clint Byrum (clint-fewbar)
summary: - dh_apparmor needs to add misc:Depends on upstart >= 0.6.7-2 (was:
- package mysql-server-5.5 5.5.17-4ubuntu6 failed to install/upgrade:
- subprocess installed post-installation script returned error exit status
- 1)
+ mysql upstart job must depend on upstart >= 0.6.7-2
Changed in mysql-5.5 (Ubuntu):
milestone: none → ubuntu-12.04-beta-1
Revision history for this message
Clint Byrum (clint-fewbar) wrote :

So, if do-release-upgrade -d is used, upstart is in fact upgraded before mysql, and this problem does not appear. I'm lowering this to Medium, since that is by far the preffered method.

Unfortunately a much more serious issue turned up, where /run/mysql/mysqld.sock is not writable due to the apparmor profile.

Changed in mysql-5.5 (Ubuntu):
importance: High → Medium
Revision history for this message
Launchpad Janitor (janitor) wrote :

This bug was fixed in the package mysql-5.5 - 5.5.20-0ubuntu1

---------------
mysql-5.5 (5.5.20-0ubuntu1) precise; urgency=low

  * New upstream release.
  * d/mysql-server-5.5.mysql.upstart: Fix stop on to make sure mysql is
    fully stopped before shutdown commences. (LP: #688541) Also simplify
    start on as it is redundant.
  * d/control: Depend on upstart version which has apparmor profile load
    script to prevent failure on upgrade from lucid to precise.
    (LP: #907465)
  * d/apparmor-profile: need to allow /run since that is the true path
    of /var/run files. (LP: #917542)
  * d/control: mysql-server-5.5 has files in it that used to be owned
    by libmysqlclient-dev, so it must break/replace it. (LP: #912487)
  * d/rules, d/control: 5.5.20 Fixes segfault on tests with gcc 4.6,
    change compiler back to system default.
  * d/rules: Turn off embedded libedit/readline.(Closes: #659566)
 -- Clint Byrum <email address hidden> Tue, 14 Feb 2012 23:59:22 -0800

Changed in mysql-5.5 (Ubuntu):
status: In Progress → 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.