0
votes

Bugzilla ./checksetup.pl report:

YOU MUST RUN ONE OF THE FOLLOWING COMMANDS (depending on which database you use):

SQLite: /usr/bin/perl install-module.pl DBD::SQLite
MySQL: /usr/bin/perl install-module.pl DBD::mysql PostgreSQL: /usr/bin/perl install-module.pl DBD::Pg
Oracle: /usr/bin/perl install-module.pl DBD::Oracle

Here is the output of

$ /usr/bin/perl install-module.pl DBD::mysql

Checking for CPAN (v1.81) ok: found v2.11
Checking for YAML (any) ok: found v1.20
Checking for ExtUtils-MakeMaker (v6.31) ok: found v7.0401
Reading '/root/.cpan/Metadata'
Database was generated on Sat, 10 Dec 2016 15:17:02 GMT
Installing DBD::mysql version 4.041...
Running install for module 'DBD::mysql'
Checksum for /root/.cpan/source/authors/id/M/MI/MICHIELB/DBD-mysql-4.041.tar.gz ok
Configuring M/MI/MICHIELB/DBD-mysql-4.041.tar.gz with Makefile.PL
Can't exec "mysql_config": No such file or directory at Makefile.PL line 88.

Cannot find the file 'mysql_config'! Your execution PATH doesn't seem not contain the path to mysql_config. Resorting to guessed values!

PLEASE NOTE:

For 'make test' to run properly, you must ensure that the database user 'root' can connect to your MySQL server and has the proper privileges that these tests require such as 'drop table', 'create table', 'drop procedure', 'create procedure' as well as others.

mysql> grant all privileges on test.* to 'root'@'localhost' identified by 's3kr1t';

You can also optionally set the user to run 'make test' with:

perl Makefile.PL --testuser=username

Can't exec "mysql_config": No such file or directory at Makefile.PL line 561. Can't find mysql_config. Use --mysql_config option to specify where mysql_config is located Failed to determine directory of mysql.h. Use

perl Makefile.PL --cflags=-I

to set this directory. For details see DBD::mysql::INSTALL, section "C Compiler flags" or type

perl Makefile.PL --help Warning: No success on command[/usr/bin/perl
Makefile.PL INSTALLDIRS=site LIB="/var/www/bugzilla/lib"
INSTALLMAN1DIR="/var/www/bugzilla/lib/man/man1"
INSTALLMAN3DIR="/var/www/bugzilla/lib/man/man3"
INSTALLBIN="/var/www/bugzilla/lib/bin"
INSTALLSCRIPT="/var/www/bugzilla/lib/bin" INSTALLDIRS=perl]
MICHIELB/DBD-mysql-4.041.tar.gz /usr/bin/perl Makefile.PL
INSTALLDIRS=site LIB="/var/www/bugzilla/lib"
INSTALLMAN1DIR="/var/www/bugzilla/lib/man/man1"
INSTALLMAN3DIR="/var/www/bugzilla/lib/man/man3"
INSTALLBIN="/var/www/bugzilla/lib/bin"
INSTALLSCRIPT="/var/www/bugzilla/lib/bin" INSTALLDIRS=perl -- NOT OK

When trying

$ /usr/bin/perl install-module.pl DBD::mysql --mysql_config /etc/mysql/mysql.conf.d

This error is reported

There is no Perl module on CPAN named /etc/mysql/mysql.conf.d/usr/bin/perl

Here are the details of the system I am working with

Linux

Ubuntu 16.04.1 LTS

Apache:

Server version: Apache/2.4.18 (Ubuntu)
Server built: 2016-07-14T12:32:26

MySQL:

Ver 14.14 Distrib 5.7.16, for Linux (x86_64) using EditLine wrapper

Perl:

perl 5, version 22, subversion 1 (v5.22.1) built for x86_64-linux-gnu-thread-multi

3
What is odel in your subject line? It doesn't appear anywhere else. - Borodin
The cause is clearly Can't exec "mysql_config": No such file or directory at Makefile.PL line 88 This is the sort of thing that happens if a module has been copied into place instead of being installed. You could try using cpan to install DBD::mysql, but it looks like your perl installation is awry and there isn't a simple fix. What changes did you make before trying to install BugZilla? - Borodin
Sounds like you don't have the mysql dev files installed - ikegami
Is there a reason why you chose /usr/bin/perl install-module.pl DBD::mysql? I don't know about BugZilla's install-module.pl, but I can't imagine a reason why you should use a non-standard installation procedure, especially for a driver module for the main DBI module. If you think you are following a list of instructions from somewhere then please will you give us a hyperlink to those instructions on line? - Borodin
@Borodin - this was a typo. I corrected the title. tks. - Dominic Harvey

3 Answers

1
votes

After reading @Borodin's comment, I issued:

$ sudo apt-get install libdbd-mysql-perl

and the $ ./checksetup.pl --check-modules no longer report any errors.

(Many thanks @Borodin for the hint :-)

0
votes

I was having the same issue while trying to install bugzilla,

Assumed that you have bugzilla in directory var/www/html

What i did was

Just go to the directory : var/www/html/bugzilla and execute command:

perl install-module.pl --all
0
votes

If in the end you don't get an automatic installation, try a manual installation. DBD::mysql manual installation