Bug #69844 Problem with scripts/mysql_install_db --user=mysql
Submitted: 26 Jul 2013 3:00 Modified: 19 Feb 2014 18:53
Reporter: Anthony Pong Email Updates:
Status: Closed Impact on me:
None 
Category:MySQL Server: Installing Severity:S3 (Non-critical)
Version:5.6.12 OS:Linux (Fedora 19)
Assigned to: CPU Architecture:Any

[26 Jul 2013 3:00] Anthony Pong
Description:
I am installing MySQL on Linux (Fedora 19) using Generic Binaries download file mysql-5.6.12-linux-glibc2.5-x86_64.tar.gz.

When I come to the command "shell> scripts/mysql_install_db --user=mysql", there is an error and it stops. The output shows:

Can't locate Data/Dumper.pm in @INC (@INC contains: /usr/local/lib64/perl5 /usr/local/share/perl5 /usr/lib64/perl5/vendor_perl /usr/share/perl5/vendor_perl /usr/lib64/perl5 /usr/share/perl5 .) at scripts/mysql_install_db line 42.
BEGIN failed--compilation aborted at scripts/mysql_install_db line 42.

How to repeat:
Run the following command in a Fedora 19 machines.
shell> scripts/mysql_install_db --user=mysql

But the command works fine in Fedora 14 machines.

Suggested fix:
There is no Dumper.pm file in /usr and any of its sub-directories in Fedora 19.
There is a Dumper.pm file in /usr/lib/perl5/Data/Dumper.pm in Fedora 14.

I have little knowledge on Perl. Why data are missing in this version of Perl5?

Please use available data of Perl5 in Fedora 19.

(I am not sure if it is mysql, Perl or Fedora problem. Sorry.)
[28 Jul 2013 1:58] MySQL Verification Team
Are you tried to run it with --basedir=path_for_install_directory too ?. Thanks.
[29 Aug 2013 1:00] Bugs System
No feedback was provided for this bug for over a month, so it is
being suspended automatically. If you are able to provide the
information that was originally requested, please do so and change
the status of the bug back to "Open".
[5 Feb 2014 12:31] Terje Røsten
Problem is that your system don't have the required perl module Data::Dumper installed. To install this module on Fedora, please try (as root):

$ yum install 'perl(Data::Dumper)'

mysql_install_db script should be improved by giving user a better error message
when required perl modules are missing.
[19 Feb 2014 18:53] Paul DuBois
Noted in 5.6.17, 5.7.4 changelogs.

mysql_install_db provides a more informative diagnostic message when
required Perl modules are missing.
[28 Mar 2014 19:35] Laurynas Biveinis
5.6$ bzr log -r 5802 -n0
------------------------------------------------------------
revno: 5802
committer: Balasubramanian Kandasamy <balasubramanian.kandasamy@oracle.com>
branch nick: mysql-5.6
timestamp: Fri 2014-02-07 10:43:59 +0100
message:
  - BUG 18187451 - PROBLEM WITH SCRIPTS/MYSQL_INSTALL_DB --USER=MYSQL 
  - Removed mysql-embedded-check.c packaging/rpm-fedora/CMakeLists.txt
  - Removed the patch steps from mysql-5.6.16-mysql-install.patch