package mysql-hostname-5.7 (not installed) failed to install/upgrade: installed mysql-hostname-5.7 package post-installation script subprocess returned error exit status 1

Bug #1783106 reported by Kathirvel
8
This bug affects 1 person
Affects Status Importance Assigned to Milestone
mysql-5.7 (Ubuntu)
Expired
Undecided
Unassigned

Bug Description

unable install

ProblemType: Package
DistroRelease: Ubuntu 18.04
Package: mysql-server-5.7 (not installed)
ProcVersionSignature: Ubuntu 4.15.0-29.31-generic 4.15.18
Uname: Linux 4.15.0-29-generic x86_64
ApportVersion: 2.20.9-0ubuntu7
Architecture: amd64
Date: Mon Jul 23 07:40:18 2018
ErrorMessage: installed mysql-server-5.7 package post-installation script subprocess returned error exit status 1
Python3Details: /usr/bin/python3.6, Python 3.6.5, python3-minimal, 3.6.5-3
PythonDetails: /usr/bin/python2.7, Python 2.7.15rc1, python-minimal, 2.7.15~rc1-1
RelatedPackageVersions:
 dpkg 1.19.0.5ubuntu2
 apt 1.6.1
SourcePackage: mysql-5.7
Title: package mysql-hostname-5.7 (not installed) failed to install/upgrade: installed mysql-hostname-5.7 package post-installation script subprocess returned error exit status 1
UpgradeStatus: No upgrade log present (probably fresh install)

Revision history for this message
Kathirvel (velukathir-msc) wrote :
Revision history for this message
Marc Deslauriers (mdeslaur) wrote : Bug is not a security issue

Thanks for taking the time to report this bug and helping to make Ubuntu better. We appreciate the difficulties you are facing, but this appears to be a "regular" (non-security) bug. I have unmarked it as a security issue since this bug does not show evidence of allowing attackers to cross privilege boundaries nor directly cause loss of data/privacy. Please feel free to report any other bugs you may find.

information type: Private Security → Public
tags: removed: need-duplicate-check
Revision history for this message
Andreas Hasenack (ahasenack) wrote :

The dmesg output is full with these:
[ 9163.715239] audit: type=1400 audit(1532331617.751:43): apparmor="DENIED" operation="mknod" profile="/usr/sbin/mysqld" name="/opt/stack/mysql/server.lower-test" pid=3528 comm="mysqld" requested_mask="c" denied_mask="c" fsuid=0 ouid=0

Ubuntu mysql won't write to /opt by default. Did you make local configuration changes in that regard?

Changed in mysql-5.7 (Ubuntu):
status: New → Incomplete
Revision history for this message
Kathirvel (velukathir-msc) wrote : Re: [Bug 1783106] Re: package mysql-hostname-5.7 (not installed) failed to install/upgrade: installed mysql-hostname-5.7 package post-installation script subprocess returned error exit status 1

Hi,

Yes in my.cnf i updated to use the path /opt/mysql

On Wed, Aug 1, 2018 at 11:41 PM Andreas Hasenack <email address hidden>
wrote:

> The dmesg output is full with these:
> [ 9163.715239] audit: type=1400 audit(1532331617.751:43):
> apparmor="DENIED" operation="mknod" profile="/usr/sbin/mysqld"
> name="/opt/stack/mysql/server.lower-test" pid=3528 comm="mysqld"
> requested_mask="c" denied_mask="c" fsuid=0 ouid=0
>
>
> Ubuntu mysql won't write to /opt by default. Did you make local
> configuration changes in that regard?
>
>
> ** Changed in: mysql-5.7 (Ubuntu)
> Status: New => Incomplete
>
> --
> You received this bug notification because you are subscribed to the bug
> report.
> https://bugs.launchpad.net/bugs/1783106
>
> Title:
> package mysql-hostname-5.7 (not installed) failed to install/upgrade:
> installed mysql-hostname-5.7 package post-installation script
> subprocess returned error exit status 1
>
> Status in mysql-5.7 package in Ubuntu:
> Incomplete
>
> Bug description:
> unable install
>
> ProblemType: Package
> DistroRelease: Ubuntu 18.04
> Package: mysql-server-5.7 (not installed)
> ProcVersionSignature: Ubuntu 4.15.0-29.31-generic 4.15.18
> Uname: Linux 4.15.0-29-generic x86_64
> ApportVersion: 2.20.9-0ubuntu7
> Architecture: amd64
> Date: Mon Jul 23 07:40:18 2018
> ErrorMessage: installed mysql-server-5.7 package post-installation
> script subprocess returned error exit status 1
> Python3Details: /usr/bin/python3.6, Python 3.6.5, python3-minimal,
> 3.6.5-3
> PythonDetails: /usr/bin/python2.7, Python 2.7.15rc1, python-minimal,
> 2.7.15~rc1-1
> RelatedPackageVersions:
> dpkg 1.19.0.5ubuntu2
> apt 1.6.1
> SourcePackage: mysql-5.7
> Title: package mysql-hostname-5.7 (not installed) failed to
> install/upgrade: installed mysql-hostname-5.7 package post-installation
> script subprocess returned error exit status 1
> UpgradeStatus: No upgrade log present (probably fresh install)
>
> To manage notifications about this bug go to:
>
> https://bugs.launchpad.net/ubuntu/+source/mysql-5.7/+bug/1783106/+subscriptions
>

Revision history for this message
Christian Ehrhardt  (paelzer) wrote :

This is then a non default configuration that you have to adapt more than just this config for.
The used default apparmor profile is in /etc/apparmor.d/usr.sbin.mysqld

You either need to disable that protection completele (aa-disable) which is easy but takes away quite some protection.

Or you need to modify the provided profile to work with your non default paths.
To do so I'd recommend adding extra rules in /etc/apparmor.d/local/usr.sbin.mysqld which is intended for local overrides like the one you need.

Revision history for this message
Launchpad Janitor (janitor) wrote :

[Expired for mysql-5.7 (Ubuntu) because there has been no activity for 60 days.]

Changed in mysql-5.7 (Ubuntu):
status: Incomplete → Expired
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.