percona 5.6 install on debian fails due to default config reference to /etc/mysql/conf.d

Bug #1206648 reported by Phil Hildebrand
22
This bug affects 5 people
Affects Status Importance Assigned to Milestone
Percona Server moved to https://jira.percona.com/projects/PS
Fix Released
High
Stewart Smith
5.1
Invalid
Undecided
Unassigned
5.5
Invalid
Undecided
Unassigned
5.6
Fix Released
High
Stewart Smith
Percona XtraDB Cluster moved to https://jira.percona.com/projects/PXC
Status tracked in 5.6
5.5
Invalid
Undecided
Unassigned
5.6
Fix Released
Undecided
Unassigned

Bug Description

The default install of percona server 5.6 fails on debian using apt-get. I think because the default config has a reference to bring in /etc/mysql/conf.d, but that directory does not exist and is not created if it does not.

Also - when I upgraded an existing 5.5 server, it appeared to remove the conf.d directory before the install of 5.6 so that did not work either.

The bottom of the default my.conf contains this:

#
# * IMPORTANT: Additional settings that can override those from this file!
# The files must end with '.cnf', otherwise they'll be ignored.
#
!includedir /etc/mysql/conf.d/

output from install:

% sudo -i DEBIAN_FRONTEND=noninteractive apt-get -y install percona-server-server-5.6 percona-server-client-5.6

executing command
stdin: is not a tty
Reading package lists...

Building dependency tree...

Reading state information...

The following extra packages will be installed:
libaio1 libdbd-mysql-perl libdbi-perl libmysqlclient18 libnet-daemon-perl
libplrpc-perl percona-server-common-5.6
Suggested packages:
tinyca
The following packages will be REMOVED:
mysql-common
The following NEW packages will be installed:
libaio1 libdbd-mysql-perl libdbi-perl libnet-daemon-perl libplrpc-perl
percona-server-client-5.6 percona-server-common-5.6
percona-server-server-5.6
The following packages will be upgraded:
libmysqlclient18
1 upgraded, 8 newly installed, 1 to remove and 61 not upgraded.
Need to get 38.6 MB of archives.
After this operation, 129 MB of additional disk space will be used.
Get:1 http://repo.percona.com/apt/ precise/main libmysqlclient18 amd64 1:5.5.32-rel31.0-549.precise [838 kB]
Get:2 http://us.archive.ubuntu.com/ubuntu/ precise/main libaio1 amd64 0.3.109-2ubuntu1 [6,396 B]
Get:3 http://us.archive.ubuntu.com/ubuntu/ precise/main libnet-daemon-perl all 0.48-1 [43.1 kB]
Get:4 http://us.archive.ubuntu.com/ubuntu/ precise/main libplrpc-perl all 0.2020-2 [36.0 kB]
Get:5 http://us.archive.ubuntu.com/ubuntu/ precise/main libdbi-perl amd64 1.616-1build2 [849 kB]
Get:6 http://us.archive.ubuntu.com/ubuntu/ precise/main libdbd-mysql-perl amd64 4.020-1build2 [106 kB]
Get:7 http://repo.percona.com/apt/ precise/main percona-server-common-5.6 amd64 5.6.12-rc60.4-394.precise [2,746 B]
Get:8 http://repo.percona.com/apt/ precise/main percona-server-client-5.6 amd64 5.6.12-rc60.4-394.precise [10.3 MB]
Get:9 http://repo.percona.com/apt/ precise/main percona-server-server-5.6 amd64 5.6.12-rc60.4-394.precise [26.5 MB]
Preconfiguring packages ...
Fetched 38.6 MB in 12s (3,003 kB/s)
(Reading database ...
58231 files and directories currently installed.)
Preparing to replace libmysqlclient18 5.5.31-0ubuntu0.12.04.2 (using .../libmysqlclient18_1%3a5.5.32-rel31.0-549.precise_amd64.deb) ...
Unpacking replacement libmysqlclient18 ...
Processing triggers for install-info ...
install-info: warning:
no info dir entry in `/usr/share/info/mysql.info.gz'

(Reading database ...
58232 files and directories currently installed.)
Removing mysql-common ...
Selecting previously unselected package libaio1.
(Reading database ...
58228 files and directories currently installed.)
Unpacking libaio1 (from .../libaio1_0.3.109-2ubuntu1_amd64.deb) ...
Selecting previously unselected package libnet-daemon-perl.
Unpacking libnet-daemon-perl (from .../libnet-daemon-perl_0.48-1_all.deb) ...
Selecting previously unselected package libplrpc-perl.
Unpacking libplrpc-perl (from .../libplrpc-perl_0.2020-2_all.deb) ...
Selecting previously unselected package libdbi-perl.
Unpacking libdbi-perl (from .../libdbi-perl_1.616-1build2_amd64.deb) ...
Selecting previously unselected package libdbd-mysql-perl.
Unpacking libdbd-mysql-perl (from .../libdbd-mysql-perl_4.020-1build2_amd64.deb) ...
Selecting previously unselected package percona-server-common-5.6.
Unpacking percona-server-common-5.6 (from .../percona-server-common-5.6_5.6.12-rc60.4-394.precise_amd64.deb) ...
Selecting previously unselected package percona-server-client-5.6.
Unpacking percona-server-client-5.6 (from .../percona-server-client-5.6_5.6.12-rc60.4-394.precise_amd64.deb) ...
Selecting previously unselected package percona-server-server-5.6.
Unpacking percona-server-server-5.6 (from .../percona-server-server-5.6_5.6.12-rc60.4-394.precise_amd64.deb) ...
Processing triggers for man-db ...
Processing triggers for ureadahead ...
Setting up libmysqlclient18 (1:5.5.32-rel31.0-549.precise) ...
Setting up libaio1 (0.3.109-2ubuntu1) ...
Setting up libnet-daemon-perl (0.48-1) ...
Setting up libplrpc-perl (0.2020-2) ...
Setting up libdbi-perl (1.616-1build2) ...
Setting up libdbd-mysql-perl (4.020-1build2) ...
Setting up percona-server-common-5.6 (5.6.12-rc60.4-394.precise) ...
Setting up percona-server-client-5.6 (5.6.12-rc60.4-394.precise) ...
Setting up percona-server-server-5.6 (5.6.12-rc60.4-394.precise) ...
* Stopping MySQL (Percona Server) mysqld

/usr/sbin/mysqld
:
Can't read dir of '/etc/mysql/conf.d/' (Errcode: 2 - No such file or directory)

Fatal error in defaults handling. Program aborted
...done.

* Percona Server is distributed with several useful UDF (User Defined Function) from Percona Toolkit.
* Run the following commands to create these functions:

mysql -e "CREATE FUNCTION fnv1a_64 RETURNS INTEGER SONAME 'libfnv1a_udf.so'"
mysql -e "CREATE FUNCTION fnv_64 RETURNS INTEGER SONAME 'libfnv_udf.so'"
mysql -e "CREATE FUNCTION murmur_hash RETURNS INTEGER SONAME 'libmurmur_udf.so'"

* See http://www.percona.com/doc/percona-server/5.5/management/udf_percona_toolkit.html for more details

/usr/sbin/mysqld
:
Can't read dir of '/etc/mysql/conf.d/' (Errcode: 2 - No such file or directory)

Fatal error in defaults handling. Program aborted
* Starting MySQL (Percona Server) database server mysqld

Related branches

Revision history for this message
Nilnandan Joshi (nilnandan-joshi) wrote :
Download full text (5.9 KiB)

Reproduce it with Debian 6.0.7 and PS 5.6.12. If there is no /etc/mysql/conf.d dir created, installer gives error but not creating by itself.

root@debian:/etc/mysql# lsb_release -a
No LSB modules are available.
Distributor ID: Debian
Description: Debian GNU/Linux 6.0.7 (squeeze)
Release: 6.0.7
Codename: squeeze
root@debian:/etc/mysql# B

root@debian:/etc/mysql# sudo -i DEBIAN_FRONTEND=noninteractive apt-get install percona-server-server-5.6 percona-server-client-5.6
Reading package lists... Done
Building dependency tree
Reading state information... Done
The following package was automatically installed and is no longer required:
  libhtml-template-perl
Use 'apt-get autoremove' to remove them.
The following extra packages will be installed:
  libaio1 libmysqlclient18 percona-server-common-5.6
Suggested packages:
  tinyca
The following packages will be REMOVED:
  percona-server-common
The following NEW packages will be installed:
  libaio1 libmysqlclient18 percona-server-client-5.6 percona-server-common-5.6 percona-server-server-5.6
0 upgraded, 5 newly installed, 1 to remove and 0 not upgraded.
Need to get 37.5 MB of archives.
After this operation, 131 MB of additional disk space will be used.
Do you want to continue [Y/n]? y
WARNING: The following packages cannot be authenticated!
  libaio1 libmysqlclient18 percona-server-common-5.6 percona-server-client-5.6 percona-server-server-5.6
Install these packages without verification [y/N]? y
Get:1 http://debianmirror.nkn.in/debian/ squeeze/main libaio1 amd64 0.3.107-7 [7,928 B]
Get:2 http://repo.percona.com/apt/ squeeze/main libmysqlclient18 amd64 5.5.32-rel31.0-549.squeeze [844 kB]
Get:3 http://repo.percona.com/apt/ squeeze/main percona-server-common-5.6 amd64 5.6.12-rc60.4-394.squeeze [2,748 B]
Get:4 http://repo.percona.com/apt/ squeeze/main percona-server-client-5.6 amd64 5.6.12-rc60.4-394.squeeze [10.3 MB]
Get:5 http://repo.percona.com/apt/ squeeze/main percona-server-server-5.6 amd64 5.6.12-rc60.4-394.squeeze [26.4 MB]
Fetched 37.5 MB in 1min 47s (349 kB/s)
Preconfiguring packages ...
(Reading database ... 130049 files and directories currently installed.)
Removing percona-server-common ...
Selecting previously deselected package libaio1.
(Reading database ... 130047 files and directories currently installed.)
Unpacking libaio1 (from .../libaio1_0.3.107-7_amd64.deb) ...
Selecting previously deselected package libmysqlclient18.
Unpacking libmysqlclient18 (from .../libmysqlclient18_5.5.32-rel31.0-549.squeeze_amd64.deb) ...
Selecting previously deselected package percona-server-common-5.6.
Unpacking percona-server-common-5.6 (from .../percona-server-common-5.6_5.6.12-rc60.4-394.squeeze_amd64.deb) ...
Selecting previously deselected package percona-server-client-5.6.
Unpacking percona-server-client-5.6 (from .../percona-server-client-5.6_5.6.12-rc60.4-394.squeeze_amd64.deb) ...
Selecting previously deselected package percona-server-server-5.6.
Unpacking percona-server-server-5.6 (from .../percona-server-server-5.6_5.6.12-rc60.4-394.squeeze_amd64.deb) ...
Proce...

Read more...

tags: added: pkg
Revision history for this message
Nilnandan Joshi (nilnandan-joshi) wrote :
Download full text (3.5 KiB)

Same thing happened with PS 5.5.32

root@debian:~# sudo -i DEBIAN_FRONTEND=noninteractive apt-get install percona-server-server-5.5 percona-server-client-5.5
Reading package lists... Done
Building dependency tree
Reading state information... Done
The following package was automatically installed and is no longer required:
  libhtml-template-perl
Use 'apt-get autoremove' to remove them.
The following extra packages will be installed:
  percona-server-common-5.5
Suggested packages:
  tinyca
The following packages will be REMOVED:
  percona-server-client-5.6 percona-server-common-5.6 percona-server-server-5.6
The following NEW packages will be installed:
  percona-server-client-5.5 percona-server-common-5.5 percona-server-server-5.5
0 upgraded, 3 newly installed, 3 to remove and 0 not upgraded.
1 not fully installed or removed.
Need to get 30.1 MB of archives.
After this operation, 21.3 MB disk space will be freed.
Do you want to continue [Y/n]? Y
WARNING: The following packages cannot be authenticated!
  percona-server-common-5.5 percona-server-client-5.5 percona-server-server-5.5
Install these packages without verification [y/N]? y
Get:1 http://repo.percona.com/apt/ squeeze/main percona-server-common-5.5 amd64 5.5.32-rel31.0-549.squeeze [2,760 B]
Get:2 http://repo.percona.com/apt/ squeeze/main percona-server-client-5.5 amd64 5.5.32-rel31.0-549.squeeze [8,543 kB]
Get:3 http://repo.percona.com/apt/ squeeze/main percona-server-server-5.5 amd64 5.5.32-rel31.0-549.squeeze [21.6 MB]
Fetched 30.1 MB in 1min 31s (331 kB/s)
Preconfiguring packages ...
(Reading database ... 130321 files and directories currently installed.)
Removing percona-server-server-5.6 ...
Stopping MySQL (Percona Server): mysqld/usr/sbin/mysqld: Can't read dir of '/etc/mysql/conf.d/' (Errcode: 2 - No such file or directory)
Fatal error in defaults handling. Program aborted
/usr/sbin/mysqld: Can't read dir of '/etc/mysql/conf.d/' (Errcode: 2 - No such file or directory)
Fatal error in defaults handling. Program aborted
.
Removing percona-server-client-5.6 ...
Removing percona-server-common-5.6 ...
Processing triggers for man-db ...
Processing triggers for menu ...
Selecting previously deselected package percona-server-common-5.5.
(Reading database ... 130067 files and directories currently installed.)
Unpacking percona-server-common-5.5 (from .../percona-server-common-5.5_5.5.32-rel31.0-549.squeeze_amd64.deb) ...
Selecting previously deselected package percona-server-client-5.5.
Unpacking percona-server-client-5.5 (from .../percona-server-client-5.5_5.5.32-rel31.0-549.squeeze_amd64.deb) ...
Selecting previously deselected package percona-server-server-5.5.
Unpacking percona-server-server-5.5 (from .../percona-server-server-5.5_5.5.32-rel31.0-549.squeeze_amd64.deb) ...
Aborting downgrade from (at least) 5.6 to 5.5.
If are sure you want to downgrade to 5.5, remove the file
/var/lib/mysql/debian-*.flag and try installing again.
dpkg: error processing /var/cache/apt/archives/percona-server-server-5.5_5.5.32-rel31.0-549.squeeze_amd64.deb (--unpack):
 s...

Read more...

Revision history for this message
Nilnandan Joshi (nilnandan-joshi) wrote :

And same with PS 5.1.70

root@debian:~# sudo -i DEBIAN_FRONTEND=noninteractive apt-get install percona-server-server-5.1 percona-server-client-5.1
Reading package lists... Done
Building dependency tree
Reading state information... Done
The following extra packages will be installed:
  percona-server-common
Suggested packages:
  tinyca
The following packages will be REMOVED:
  percona-server-client-5.5 percona-server-common-5.5
The following NEW packages will be installed:
  percona-server-client-5.1 percona-server-common percona-server-server-5.1
0 upgraded, 3 newly installed, 2 to remove and 0 not upgraded.
2 not fully installed or removed.
Need to get 0 B/24.6 MB of archives.
After this operation, 131 MB of additional disk space will be used.
Do you want to continue [Y/n]? Y
WARNING: The following packages cannot be authenticated!
  percona-server-common percona-server-client-5.1 percona-server-server-5.1
Install these packages without verification [y/N]? y
Preconfiguring packages ...
(Reading database ... 130109 files and directories currently installed.)
Removing percona-server-client-5.5 ...
Removing percona-server-common-5.5 ...
Processing triggers for menu ...
Processing triggers for man-db ...
Selecting previously deselected package percona-server-common.
(Reading database ... 130066 files and directories currently installed.)
Unpacking percona-server-common (from .../percona-server-common_5.1.70-rel14.8-580.squeeze_amd64.deb) ...
Selecting previously deselected package percona-server-client-5.1.
Unpacking percona-server-client-5.1 (from .../percona-server-client-5.1_5.1.70-rel14.8-580.squeeze_amd64.deb) ...
Processing triggers for menu ...
Processing triggers for man-db ...
Setting up percona-server-common (5.1.70-rel14.8-580.squeeze) ...
Selecting previously deselected package percona-server-server-5.1.
(Reading database ... 130116 files and directories currently installed.)
Unpacking percona-server-server-5.1 (from .../percona-server-server-5.1_5.1.70-rel14.8-580.squeeze_amd64.deb) ...
Aborting downgrade from (at least) 5.6 to 5.1.
If are sure you want to downgrade to 5.1, remove the file
/var/lib/mysql/debian-*.flag and try installing again.
dpkg: error processing /var/cache/apt/archives/percona-server-server-5.1_5.1.70-rel14.8-580.squeeze_amd64.deb (--unpack):
 subprocess new pre-installation script returned error exit status 1
configured to not write apport reports
                                      Errors were encountered while processing:
 /var/cache/apt/archives/percona-server-server-5.1_5.1.70-rel14.8-580.squeeze_amd64.deb
E: Sub-process /usr/bin/dpkg returned an error code (1)
root@debian:~#

Revision history for this message
Roel Van de Paar (roel11) wrote :

Looks like bug 1225189

Revision history for this message
Ignacio Nin (ignacio-nin) wrote :

Hello,

This is currently not reproducible in 5.6.13-60.6. Notice that this release had a change of init script, and we started using a script that may overcome this issue:

* Stopping MySQL (Percona Server) mysqld

/usr/sbin/mysqld
:
Can't read dir of '/etc/mysql/conf.d/' (Errcode: 2 - No such file or directory)

Fatal error in defaults handling. Program aborted
...done.

It's clear that the error surfaced when executing it so it may be a problem with the old init script. Notice that also the directory IS created during installation.

For 5.1/5.5 the issue is not rreproducible: notice as well that in the pasted examples the install failed for other reasons:

Aborting downgrade from (at least) 5.6 to 5.1.
If are sure you want to downgrade to 5.1, remove the file
/var/lib/mysql/debian-*.flag and try installing again.

in both cases, not related to the original bug description.

Revision history for this message
Pierre (darkstuff) wrote :

Same problem in 1:5.6.14-rel62.0-483.raring

Revision history for this message
Matt Whiteley (mwhiteley) wrote :

We have the same problem in 5.6.14-rel62.0-483.precise. In our environment, the mysql-common package is already installed and then we install percona-server-server-5.6 which depends on percona-server-common-5.6 which forces mysql-common to be removed and /etc/mysql along with it. The server then fails to start with the same error as reported above.

  $ dpkg --contents percona-server-common-5.5_5.5.34-rel32.0-591.precise_amd64.deb
  drwxr-xr-x root/root 0 2013-10-25 06:38 ./
  drwxr-xr-x root/root 0 2013-10-25 06:38 ./etc/
  drwxr-xr-x root/root 0 2013-10-25 06:38 ./etc/mysql/
  drwxr-xr-x root/root 0 2013-10-25 06:38 ./etc/mysql/conf.d/
  drwxr-xr-x root/root 0 2013-10-25 06:38 ./usr/
  drwxr-xr-x root/root 0 2013-10-25 06:38 ./usr/share/
  drwxr-xr-x root/root 0 2013-10-25 06:38 ./usr/share/doc/
  drwxr-xr-x root/root 0 2013-10-25 06:38 ./usr/share/doc/percona-server-common-5.5/
  -rw-r--r-- root/root 2694 2013-10-25 06:31 ./usr/share/doc/percona-server-common-5.5/copyright
  -rw-r--r-- root/root 743 2013-10-25 06:31 ./usr/share/doc/percona-server-common-5.5/changelog.Debian.gz

  $ dpkg --contents percona-server-common-5.6_5.6.14-rel62.0-483.precise_amd64.deb
  drwxr-xr-x root/root 0 2013-10-25 06:46 ./
  drwxr-xr-x root/root 0 2013-10-25 06:46 ./usr/
  drwxr-xr-x root/root 0 2013-10-25 06:46 ./usr/share/
  drwxr-xr-x root/root 0 2013-10-25 06:46 ./usr/share/doc/
  drwxr-xr-x root/root 0 2013-10-25 06:46 ./usr/share/doc/percona-server-common-5.6/
  -rw-r--r-- root/root 1422 2013-10-25 06:36 ./usr/share/doc/percona-server-common-5.6/changelog.Debian.gz
  -rw-r--r-- root/root 2694 2013-10-25 06:36 ./usr/share/doc/percona-server-common-5.6/copyright

Revision history for this message
Raghavendra D Prabhu (raghavendra-prabhu) wrote :

@Matt,

Thanks for the details. Yes, the conf.d directory is skipped from the 5.6 packaging. This is because in the bzr tree, the file in place is percona-server-common-5.5.dirs when it should be percona-server-common-5.6.dirs

cat percona-server-common-5.5.dirs
etc/mysql/conf.d/

Revision history for this message
Laurynas Biveinis (laurynas-biveinis) wrote :

This has been fixed with the recent packaging changes.

tags: added: low-hanging-fruit
Revision history for this message
Shahriyar Rzayev (rzayev-sehriyar) wrote :

Percona now uses JIRA for bug reports so this bug report is migrated to: https://jira.percona.com/browse/PXC-1408

Revision history for this message
Shahriyar Rzayev (rzayev-sehriyar) wrote :

Percona now uses JIRA for bug reports so this bug report is migrated to: https://jira.percona.com/browse/PS-710

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.