Bugzilla Installation in CentOS

Bugzilla is a “Defect Tracking System” or “Bug-Tracking System” that allows individual or groups of developers to keep track of outstanding bugs in their product effectively.

In this tutorial we’ll install Bugzilla in CentOS 5.

 

1.- Prerequisites.

  • Basic Knowledge of Linux Shell Commands.
  • Download latest version of Bugzilla. You can download it here.

 

2.- Install Perl.

Before installing Perl, check if it’s already installed with the following command.

If you see the following output Perl is properly installed in your machine.

Otherwise you have to install Perl running this command:

 

3.- Install MySQL.

Maybe you want to install MySQL as Yum Group Installation to get all the available packages including the server, the client, python and perl libraries. First run the following command to check the availability:

Then run this command to check what is inside the “MySQL Database” Bundle:

As you can see, this bundle installs all additional packages that maybe you will want to add in the future. (If you want to restrict the installation to just certain packages, this list is useful too).

Install “MySQL Database” Bundle

Start the MySQL Service.

Change the root password.

 

4.- MySQL post installation activities.

Once you have MySQL installed, you need to do the next steps that are listed in the Bugzilla’s documentation to avoid errors in runtime.

Update /etc/my.cnf file with the following lines in the [mysqld] section:

Create a database and its user named bugs as follows:

Restart MySQL service:

 

5.- Install Apache.

To install Apache you just have to run the following command as root:

This will install Apache in its latest version with SSL suppport.

6.- Check dependencies before installing Bugzilla.

Copy Bugzilla tar file to /var/www/html/ directory.

Extract the bugzilla-4.2.4.tar.gz file

Run the bugzilla checksetup.pl command to check if the required and optional modules are available.

As you can see there are many libraries that are not installed, so don’t be scared and execute the following command:

After waiting for a while you may want to run bugzilla checksetup.pl command again to check if all the libraries have been installed.

At this point the command installed all the libraries it could, but there are some libraries that couldn’t be installed because of the dependencies that the libraries might need. So you’ll need to install them one by one before continuing.

At the end of the post I’ve added a Missing Libraries Installation Section to cover those problems.

 

7.- Check dependencies once again.

If you have all the missing libraries already installed run checksetup.pl again just to be sure everything is OK.

8.- Install Bugzilla.

Run ./checksetup.pl once again but this time without any argument to create the ./localconfig file in which we have to change some options to configure MySQL as the DB Server.

Update ./localconfig file changing the following lines:

Then run ./checksetup.pl for the last time, in this occasion the database will be created and the admin user information is requested:

 

9.- Bugzilla post installation activities.

Go to /var/www/html directory.

Delete bugzilla-4.2.4.tar.gz file to save space.

Move bugzilla-4.2.4 directory to a folder called just bugzilla.

Make apache user the owner of bugzilla directory

Configure MySQL to accept larger attachments in bugs database:

 

10.- Configure Apache to run Bugzilla.

Create a file named bugzilla.conf in /etc/httpd/conf.d/ directory with the following content:

Restart Apache.

 

11.- Run Bugzilla.

Open a browser and go to http://localhost/bugzilla.

That’s it, Bugzilla is up and running.

12.- Missing Libraries Installation Section.

DBD-mysql (v4.001) is missing

The DBD-mysql (v4.001) is missing

Solution: install mysql-dlevel library.

To set up properly DBD-mysql (v4.001) you need to install mysql-devel first. Run the following command:

Once installed run the following command:

 

Can’t install GD (v1.20).

There’s an option to install GD when we get the following error:

Solution: install gd-level package.

then run the following command to install GD:

 

XML-Twig is missing.

The XML-Twig library is missing. It doesn’t matter how many times you want to run:

XML-Twig will not be installed in your system.

Solution: install XML Twig via yum.

Just run the following command:

 

Encode::Detect is missing.

This library is hard to find in the repositories, the best option is to install it manually. You can download the rpm here.

Solution: install manually perl-Encode-Detect rpm.

 

mod_perl is missing.

mod_per is not installed in your computer.

Solution: install mod_perl via yum.

 

Can’t install Apache2::SizeLimit.

When you try to install Apache Size Limit it returns the following error:

Solution: create the /usr/include/httpd directory.

 

6 comments: On Bugzilla Installation in CentOS

  • The DBD-mysql (v4.001) is missing

    -Solution: install mysql-dlevel library.
    +Solution: install mysql-devel library.

    To set up properly DBD-mysql (v4.001) you need to install mysql-devel first. Run the following command:

  • Dear Sir,

    Great Tut…But after following all the steps i am not able to open it on local server it gaves an error of 500 Internal server error.

  • Thanks Akshay, Hum the 500 error could be related to apache mode_ssl, Did you install a fresh apache?

  • Thanks Marco for the great job.

    In my case, creating directory /usr/include/httpd doesn’t work for the issue “Can’t install Apache2::SizeLimit.” The solution is “yum install mod_perl-devel”, and then “/usr/bin/perl install-module.pl Apache2::SizeLimit”

  • Do you know how long will it take to complete perl installation approximately assuming had good internet speed? hours ? minutes ?

  • With a good internet speed, the perl installation usually takes a few minutes, no more than five.

Leave a reply:

Your email address will not be published.

Copyright © 2016 Marco Tello.