package mysql-server-5.6 5.6.23-1~exp1~ubuntu3 failed to install/upgrade: subprocess installed post-removal script returned error exit status 1

Bug #1435081 reported by Shevek
42
This bug affects 9 people
Affects Status Importance Assigned to Milestone
mysql-5.6 (Ubuntu)
Confirmed
Undecided
Unassigned

Bug Description

This bug was generated by an automatic process. The real bug is here, and should be merged:

https://bugs.launchpad.net/ubuntu/+source/mysql-5.6/+bug/1435080

ProblemType: Package
DistroRelease: Ubuntu 15.04
Package: mysql-server-5.6 5.6.23-1~exp1~ubuntu3
ProcVersionSignature: Ubuntu 3.19.0-9.9-generic 3.19.1
Uname: Linux 3.19.0-9-generic x86_64
ApportVersion: 2.16.2-0ubuntu4
AptOrdering: mysql-server-5.6: Remove
Architecture: amd64
Date: Sun Mar 22 14:30:24 2015
DpkgTerminalLog:
 Removing mysql-server-5.6 (5.6.23-1~exp1~ubuntu3) ...
 update-alternatives: using /etc/mysql/my.cnf.fallback to provide /etc/mysql/my.cnf (my.cnf) in auto mode
 /usr/bin/deb-systemd-helper: error: unable to link /etc/systemd/system/mysql.service to /dev/null: File exists
DuplicateSignature: package:mysql-server-5.6:5.6.23-1~exp1~ubuntu3:subprocess installed post-removal script returned error exit status 1
ErrorMessage: subprocess installed post-removal script returned error exit status 1
InstallationDate: Installed on 2015-03-05 (17 days ago)
InstallationMedia: Xubuntu 14.04.2 LTS "Trusty Tahr" - Release amd64 (20150218.1)
RelatedPackageVersions:
 dpkg 1.17.24ubuntu1
 apt 1.0.9.3ubuntu1
SourcePackage: mysql-5.6
Title: package mysql-server-5.6 5.6.23-1~exp1~ubuntu3 failed to install/upgrade: subprocess installed post-removal script returned error exit status 1
UpgradeStatus: Upgraded to vivid on 2015-03-19 (3 days ago)

Revision history for this message
Shevek (r-launchpad-anarres-org) wrote :
Revision history for this message
Shevek (r-launchpad-anarres-org) wrote :

root@raven:~# sudo apt-get purge mysql-server-5.6 mysql-server
Reading package lists... Done
Building dependency tree
Reading state information... Done
Package 'mysql-server' is not installed, so not removed
The following packages will be REMOVED:
  mysql-server-5.6
0 upgraded, 0 newly installed, 1 to remove and 0 not upgraded.
1 not fully installed or removed.
After this operation, 52.4 MB disk space will be freed.
Do you want to continue? [Y/n]
(Reading database ... 231499 files and directories currently installed.)
Removing mysql-server-5.6 (5.6.23-1~exp1~ubuntu3) ...
/usr/bin/deb-systemd-helper: error: unable to link /etc/systemd/system/mysql.service to /dev/null: File exists
dpkg: error processing package mysql-server-5.6 (--remove):
 subprocess installed post-removal script returned error exit status 1
Errors were encountered while processing:
 mysql-server-5.6
E: Sub-process /usr/bin/dpkg returned an error code (1)

tags: removed: need-duplicate-check
Revision history for this message
Launchpad Janitor (janitor) wrote :

Status changed to 'Confirmed' because the bug affects multiple users.

Changed in mysql-5.6 (Ubuntu):
status: New → Confirmed
Revision history for this message
David (daharper) wrote :

This is a real pain, can't move forwards, can't move backwards. System is borked.

Revision history for this message
cooolman (coolman) wrote :

the same, I can not install the package, not I can not remove a package

Revision history for this message
cooolman (coolman) wrote :

Reading package lists... Done
Building dependency tree
Reading state information... Done
Package 'mysql-server' is not installed, so not removed
The following packages were automatically installed and are no longer required:
  mysql-client-5.6 mysql-client-core-5.6 mysql-server-core-5.6
Use 'apt-get autoremove' to remove them.
The following packages will be REMOVED:
  mysql-server-5.6
0 upgraded, 0 newly installed, 1 to remove and 0 not upgraded.
1 not fully installed or removed.
After this operation, 50.8 MB disk space will be freed.
Do you want to continue? [Y/n] Y
(Reading database ... 85533 files and directories currently installed.)
Removing mysql-server-5.6 (5.6.23-1~exp1~ubuntu3) ...
/usr/bin/deb-systemd-helper: error: unable to link /etc/systemd/system/mysql.service to /dev/null: File exists
dpkg: error processing package mysql-server-5.6 (--remove):
 subprocess installed post-removal script returned error exit status 1
Errors were encountered while processing:
 mysql-server-5.6
E: Sub-process /usr/bin/dpkg returned an error code (1)

Revision history for this message
cooolman (coolman) wrote :

150323 14:02:18 mysqld_safe mysqld from pid file /var/run/mysqld/mysqld.pid ended
150323 14:03:07 mysqld_safe Starting mysqld daemon with databases from /var/lib/mysql
/usr/sbin/mysqld: Can't read dir of '/etc/mysql/mysql.conf.d/' (Errcode: 13 - Permission denied)
Fatal error in defaults handling. Program aborted

Revision history for this message
aktiwers (aktiwers) wrote :

I wrote the comment below on the duplicate bug here:
https://bugs.launchpad.net/ubuntu/+source/mysql-5.6/+bug/1435080/

I will repost it here if it helps anyone.

Got it fixed - first I followed this:
https://bugs.launchpad.net/ubuntu/+source/mysql-5.6/+bug/1435080/comments/11

It didnt work alone - but after deleting this file:
sudo rm /etc/systemd/system/mysql.service

And :
sudo apt-get purge mysql-server-5.6 mysql-server

I could remove it and then install it again:
sudo apt-get install mysql-server-5.6 mysql-server

Revision history for this message
Nayar Joolfoo (nayar) wrote :

It also prevents mariadb from installing or unistalling

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.