Anda di halaman 1dari 13

BUGZILLA Installation On RHEL 6.

5
1. Download latest Bugzilla tar file
Download the latest stable release from bugzilla download page. Extract the
bugzilla*.tar.gz file to the apache document root directory as shown below.
Copy the downloaded tar file into var/www/html
#cp r bugzilla-4.4.4.tar.gz /var/ww/html
#tar xvfz bugzilla-4.4.4.tar.gz

2. Verify Perl Version


Make sure your perl version is >= 5.8.1 as shown below.
#perl v

3. Install MySQL Database


# yum install mysql*
To set root user mysql password:
> USE mysql;
> UPDATE user SET Password = Password('redhat') WHERE user='root';
> FLUSH PRIVILEGES

4. Install Apache
Yum install httpd

5. Execute the bugzilla checksetup.pl


Bugzilla checksetup.pl program will verify whether all the required perl modules are
installed. This will also display a list of all missing bugzilla modules that needs to be installed.
You can run the checksetup.pl program as many times as you like until youve verified all
the required perl modules are installed.
Following is the output of 1st run of checksetup.pl, where is has listed all the missing
optional and required modules.
# cd /var/www/html/bugzilla-4.4.4
# ./checksetup.pl --check-modules

COMMANDS TO INSTALL OPTIONAL MODULES:


GD:
Chart:
Template-GD:
GDTextUtil:
GDGraph:
XML-Twig:
MIME-tools:
libwww-perl:
PatchReader:
PerlMagick:
perl-ldap:
Authen-SASL:
RadiusPerl:

/usr/bin/perl
/usr/bin/perl
/usr/bin/perl
/usr/bin/perl
/usr/bin/perl
/usr/bin/perl
/usr/bin/perl
/usr/bin/perl
/usr/bin/perl
/usr/bin/perl
/usr/bin/perl
/usr/bin/perl
/usr/bin/perl

install-module.pl
install-module.pl
install-module.pl
install-module.pl
install-module.pl
install-module.pl
install-module.pl
install-module.pl
install-module.pl
install-module.pl
install-module.pl
install-module.pl
install-module.pl

GD
Chart::Base
Template::Plugin::GD::Image
GD::Text
GD::Graph
XML::Twig
MIME::Parser
LWP::UserAgent
PatchReader
Image::Magick
Net::LDAP
Authen::SASL
Authen::Radius

SOAP-Lite: /usr/bin/perl install-module.pl SOAP::Lite


HTML-Parser: /usr/bin/perl install-module.pl HTML::Parser
HTML-Scrubber: /usr/bin/perl install-module.pl HTML::Scrubber
Email-MIME-Attachment-Stripper: /usr/bin/perl install-module.pl
Email::MIME::Attachment::Stripper
Email-Reply: /usr/bin/perl install-module.pl Email::Reply
TheSchwartz: /usr/bin/perl install-module.pl TheSchwartz
Daemon-Generic: /usr/bin/perl install-module.pl Daemon::Generic
mod_perl: /usr/bin/perl install-module.pl mod_perl2
YOU MUST RUN ONE OF THE FOLLOWING COMMANDS (depending on which database you
use):
PostgreSQL: /usr/bin/perl install-module.pl DBD::Pg
MySQL: /usr/bin/perl install-module.pl DBD::mysql
Oracle: /usr/bin/perl install-module.pl DBD::Oracle
COMMANDS TO INSTALL REQUIRED MODULES (You *must* run all these commands and
then re-run checksetup.pl):
/usr/bin/perl
/usr/bin/perl
/usr/bin/perl
/usr/bin/perl
/usr/bin/perl
/usr/bin/perl
/usr/bin/perl
/usr/bin/perl
/usr/bin/perl
/usr/bin/perl
/usr/bin/perl

install-module.pl
install-module.pl
install-module.pl
install-module.pl
install-module.pl
install-module.pl
install-module.pl
install-module.pl
install-module.pl
install-module.pl
install-module.pl

CGI
Digest::SHA
Date::Format
DateTime
DateTime::TimeZone
Template
Email::Send
Email::MIME
Email::MIME::Encodings
Email::MIME::Modifier
URI

To attempt an automatic install of every required and optional module with one
command, do:
/usr/bin/perl install-module.pl all

6. Execute bugzilla install-module.pl


As suggested by the output of the checksetup.pl, you can execute the install-module.pl to install
all bugzilla required and optional perl modules.
# /usr/bin/perl install-module.pl --all

Please review the output of the above install-module.pl to make sure everything got install
properly. There is a possibility that some of the modules failed to install (may be because some
required OS packages were missing).
Execute the checksetup.pl to verify whether all the modules got installed properly.
Following is the output of 2nd run of the checksetup.pl:
# ./checksetup.pl --check-modules
COMMANDS TO INSTALL OPTIONAL MODULES:
GD:
Chart:
Template-GD:
GDTextUtil:
GDGraph:
XML-Twig:
PerlMagick:
SOAP-Lite:
mod_perl:

/usr/bin/perl
/usr/bin/perl
/usr/bin/perl
/usr/bin/perl
/usr/bin/perl
/usr/bin/perl
/usr/bin/perl
/usr/bin/perl
/usr/bin/perl

install-module.pl
install-module.pl
install-module.pl
install-module.pl
install-module.pl
install-module.pl
install-module.pl
install-module.pl
install-module.pl

GD
Chart::Base
Template::Plugin::GD::Image
GD::Text
GD::Graph
XML::Twig
Image::Magick
SOAP::Lite
mod_perl2

YOU MUST RUN ONE OF THE FOLLOWING COMMANDS (depending on which database
you use):
PostgreSQL: /usr/bin/perl install-module.pl DBD::Pg
MySQL: /usr/bin/perl install-module.pl DBD::mysql
Oracle: /usr/bin/perl install-module.pl DBD::Oracle

7. Install missing Perl Modules


As we see from the above checksetup.pl output, some of the optional modules and required
module installed was not completed when we ran the install-module.pl.
So, we have to install the missing modules manually one-by-one to figure out the issues and fix it
one-by-one.
Refer to the Troubleshooting Section at the end for list of all the issues that I faced while
installing the perl modules required for bugzilla (along with the solution on how to fix those
issues).

8. Final checksetup.pl check-modules verification


Execute checksetup.pl check-modules again as shown below as final verification to make sure
all the modules got installed successfully.
# ./checksetup.pl --check-modules

* This is Bugzilla 3.4.6 on perl 5.8.8


* Running on Linux 2.6.18-164.el5PAE #1 SMP Thu Sep 3 04:10:44 EDT 2009
Checking
Checking
Checking
Checking
Checking
Checking
Checking
Checking
Checking
Checking
Checking
Checking
Checking

perl modules...
for
CGI.pm (v3.21)
for
Digest-SHA (any)
for
TimeDate (v2.21)
for
DateTime (v0.28)
for
DateTime-TimeZone (v0.71)
for
DBI (v1.41)
for
Template-Toolkit (v2.22)
for
Email-Send (v2.00)
for
Email-MIME (v1.861)
for Email-MIME-Encodings (v1.313)
for Email-MIME-Modifier (v1.442)
for
URI (any)

ok: found v3.49


ok: found v5.48
ok: found v2.24
ok: found v0.55
ok: found v1.17
ok: found v1.52
ok: found v2.22
ok: found v2.198
ok: found v1.903
ok: found v1.313
ok: found v1.903
ok: found v1.54

Checking
Checking
Checking
Checking

available perl DBD modules...


for
DBD-Pg (v1.45)
for
DBD-mysql (v4.00)
for
DBD-Oracle (v1.19)

not found
ok: found v4.013
not found

The following Perl modules are optional:


Checking for
GD (v1.20)
ok: found v2.44
Checking for
Chart (v1.0)
ok: found v2.4.1
Checking for
Template-GD (any)
ok: found v1.56
Checking for
GDTextUtil (any)
ok: found v0.86
Checking for
GDGraph (any)
ok: found v1.44
Checking for
XML-Twig (any)
ok: found v3.34
Checking for
MIME-tools (v5.406) ok: found v5.427
Checking for
libwww-perl (any)
ok: found v5.834
Checking for
PatchReader (v0.9.4) ok: found v0.9.5
Checking for
PerlMagick (any)
ok: found v6.2.8
Checking for
perl-ldap (any)
ok: found v0.4001
Checking for
Authen-SASL (any)
ok: found v2.1401
Checking for
RadiusPerl (any)
ok: found v0.17
Checking for
SOAP-Lite (v0.710.06) ok: found v0.711
Checking for
HTML-Parser (v3.40)
ok: found v3.65
Checking for
HTML-Scrubber (any)
ok: found v0.08
Checking for Email-MIME-Attachment-Stripper (any)
ok: found v1.316
Checking for
Email-Reply (any)
ok: found v1.202
Checking for
TheSchwartz (any)
ok: found v1.10
Checking for
Daemon-Generic (any)
ok: found v0.61
Checking for
mod_perl (v1.999022) ok: found v2.000004

9. Create localconfig file using checksetup.pl


Execute checksetup.pl without any argument, which will create a localconfig file in the current
directory. The localconfig file contains the key configuration parameters used by the bugzilla (for
example, mysql db username and password).
# ./checksetup.pl
Reading ./localconfig...
This version of Bugzilla contains some variables that you may want to
change and adapt to your local settings. Please edit the file
./localconfig and rerun checksetup.pl.

The following variables are new to ./localconfig since you last ran
checksetup.pl: create_htaccess, webservergroup, db_driver, db_host, db_name,
db_user, db_pass, db_port, db_sock, db_check, index_html, cvsbin,
interdiffbin, diffpath, site_wide_secret

10. Modify the localconfig file.


The only thing you need to modify the localconfig file is MySQL database db password by
changing the $db_pass variable as shown below.
# vi ./localconfig
$db_pass = 'Bugs4All';

11. Modify /etc/my.cnf to increase bugzilla attachment size


Set the max_allowed_packet to 4M in the /etc/my.cnf to increase bugzilla attachment size.
# cat /etc/my.cnf
[mysqld]
datadir=/var/lib/mysql
socket=/var/lib/mysql/mysql.sock
user=mysql
# Default to using old password format for compatibility with mysql 3.x
# clients (those using the mysqlclient10 compatibility package).
old_passwords=1
# Disabling symbolic-links is recommended to prevent assorted security risks;
# to do so, uncomment this line:
# symbolic-links=0
# Allow packets up to 4MB
max_allowed_packet=4M
[mysqld_safe]
log-error=/var/log/mysqld.log
pid-file=/var/run/mysqld/mysqld.pid

Restart the mysqld after this change.


# service mysqld restart

12. Create bugs mysql user


Add bugzilla user (bugs) to the mysql database as shown below.
# mysql -u root -p
mysql> GRANT SELECT, INSERT,
UPDATE, DELETE, INDEX, ALTER, CREATE, LOCK TABLES,
CREATE TEMPORARY TABLES, DROP, REFERENCES ON bugs.*
TO bugs@localhost IDENTIFIED BY 'Bugs4All';
mysql> FLUSH PRIVILEGES;

13. Create the bugzilla database

Execute the checksetup.pl (without any arguments) again to create the mysql bugzilla database.
Since the localconfig file already exist, the second time when you execute the checksetup.pl, it
will create the mysql database based on the information from localconfig file.
# ./checksetup.pl
Creating database bugs...
Building Schema object from database...
Adding new table bz_schema ...
Initializing the new Schema storage...
Adding new table attach_data ...
Adding new table attachments ...
Adding new table bug_group_map ...
Adding new table bug_see_also ...
Adding new table bug_severity ...
Adding new table bug_status ...
Inserting values into the 'priority' table:
Inserting values into the 'bug_status' table:
Inserting values into the 'rep_platform' table:
Creating ./data directory...
Creating ./data/attachments directory...
Creating ./data/duplicates directory...
Adding foreign key: attachments.bug_id -> bugs.bug_id...
Adding foreign key: attachments.submitter_id -> profiles.userid...
Adding foreign key: bug_group_map.bug_id -> bugs.bug_id...

14. Create bugzilla administrator account.


At the end of the ./checksetup.pl execution, it will detect that you dont have an adminsitrator
account and request you to enter administration login information as shown below.
Looks like we don't have an administrator set up yet. Either this is
your first time using Bugzilla, or your administrator's privileges
might have accidentally been deleted.
Enter the e-mail address of the administrator: ramesh@thegeekstuff.com
Enter the real name of the administrator: Ramesh Natarajan
Enter a password for the administrator account: NotRealPwd
Please retype the password to verify: welcome
ramesh@thegeekstuff.com is now set up as an administrator.
Creating default classification 'Unclassified'...
Creating initial dummy product 'TestProduct'...
Now that you have installed Bugzilla, you should visit the 'Parameters'
page (linked in the footer of the Administrator account) to ensure it
is set up as you wish - this includes setting the 'urlbase' option to
the correct URL.

15. Configure apache for mod_perl


Rename the bugzilla directory. (i.e remove the version number in it)
# cd /var/www/html

# mv bugzilla-3.4.6/ bugzilla

Add the following two lines to httpd.conf


# tail -2 /etc/httpd/conf/httpd.conf
PerlSwitches -I/var/www/html/bugzilla -I/var/www/html/bugzilla/lib -w -T
PerlConfigRequire /var/www/html/bugzilla/mod_perl.pl

Verify the Group in httpd.conf matches the webservergroup in localconfig


# cd /var/www/html/bugzilla/
# grep webservergroup localconfig
$webservergroup = 'apache';
# grep Group /etc/httpd/conf/httpd.conf
Group apache

16. Final checksetup.pl execution


Execute the checksetup.pl again.
# ./checksetup.pl
Reading ./localconfig...
Removing existing compiled templates...
Precompiling templates...done.
Fixing file permissions...
Now that you have installed Bugzilla, you should visit the 'Parameters'
page (linked in the footer of the Administrator account) to ensure it
is set up as you wish - this includes setting the 'urlbase' option to
the correct URL.

17. Login to bugzilla and complete one time setup.


Start the apache, go to http://{your-ip-address}/bugzilla and login using the administrator
account you created above.
From the bugzilla UI, at the footer -> Administration -> Parameters -> Required Settings
section -> Fill-out following information:
maintainer: prashanth.mpmc@gmail.com
urlbase: http://{your-ip-address}/

Troubleshooting Bugzilla Install Issues


Issue1: DBD::mysql module failed
The DBD:mysql perl module failed with the mysql.h: No such file or directory error message
as shown below.
# /usr/bin/perl install-module.pl DBD::mysql
dbdimp.h:22:49: error: mysql.h: No such file or directory
dbdimp.h:23:45: error: mysqld_error.h: No such file or directory
dbdimp.h:25:49: error: errmsg.h: No such file or directory
In file included from dbdimp.c:20:
dbdimp.h:144: error: expected specifier-qualifier-list before MYSQL
dbdimp.h:236: error: expected specifier-qualifier-list before MYSQL_RES

Solution1: install mysql-devel


Error message mysql.h: No such file or directory is because mysql-devel package was missing
as shown below.
# rpm -qa | grep -i mysql
MySQL-python-1.2.1-1
mysql-5.0.77-4.el5_4.2
mysql-connector-odbc-3.51.26r1127-1.el5
mysql-server-5.0.77-4.el5_4.2
libdbi-dbd-mysql-0.8.1a-1.2.2
perl-DBD-MySQL-3.0007-2.el5

Install the mysql-devel package as shown below.


# yum install mysql-devel
# rpm -qa | grep -i "mysql-devel"
mysql-devel-5.0.77-4.el5_4.2

DBD::mysql installation will go through without any issues now.


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

Issue2: GD failed with missing gdlib-config / libgd


Installing GD module failed with the following error message.
# /usr/bin/perl install-module.pl GD
**UNRECOVERABLE ERROR**
Could not find gdlib-config in the search path. Please install libgd 2.0.28 or
higher.
If you want to try to compile anyway, please rerun this script with the option
--ignore_missing_gd.
Running make test
Make had some problems, maybe interrupted? Won't test
Running make install

Make had some problems, maybe interrupted? Won't install

Solution2: Install gd-devel package


Install libgd (i.e gd-devel package) as shown below to fix the GD module issue.
# yum install gd-devel
# rpm -qa | grep gd
gd-2.0.33-9.4.el5_4.2
gd-devel-2.0.33-9.4.el5_4.2

GD got installed without any issues after insingalling gd-devel package.


# /usr/bin/perl install-module.pl GD

Solution3: mod_perl was missing


Dont install mod_perl using /usr/bin/perl install-module.pl mod_perl2 . Insetad, use yum to
install mod_perl as shown below.
# yum install mod_perl

Solution4: Install Template-Tool Kit as shown below


Install Template-Tool kit to fix the above apache error message
# cpan
cpan> i /Template-Toolkit/
Distribution
A/AB/ABEL/Eidolon-Driver-Template-Toolkit-0.01.tar.gz
Distribution
A/AB/ABW/Template-Toolkit-1.07.tar.gz
Distribution
A/AB/ABW/Template-Toolkit-2.22.tar.gz
Distribution
I/IN/INGY/Template-Toolkit-Simple-0.03.tar.gz
4 items found

Installing COLLABNET SUBVERSION EDGE on RHEL Linux

Requirements:-

1)

Java 1.6 JRE/JDK must be installed.

2)

Python 2.4 or higher version must be installed.

3)

CollabNetSubversionEdge-4.0.9_linux-x86_64.tar (32/64 bit)

Installation Notes:Note: Do not untar CollabNetSubversionEdge-4.0.9_linux-x86_64.tar package using root or


sudo.This will cause the UID/GID on the files to carry the values from our build system instead
of being reset.
1. Install JAVA Runtime Environment package from Add/Remove Software
(System>Administration>Add/Remove Software) by searching for Java/JRE.
OR
# yum install java-1.6.0-openjdk.x86_64
2. After Java installation is over, type the following command in Terminal window.
export JAVA_HOME=/usr/lib/jvm/jre-1.6.0-openjdk.x86_64
And also add the above line to /etc/profile (at the bottom of the file)
#sudo gedit /etc/profile
OR
#sudo vi /etc/profile
Now you can check the installed java version by the following command.
# java version
Probably this would be the output:
java version "1.6.0_22"
OpenJDK Runtime Environment (IcedTea6 1.10.4) (rhel-1.42.1.10.4.el6_2-x86_64)
OpenJDK 64-Bit Server VM (build 20.0-b11, mixed mode)

3. Add any normal (non-root) user to etc/sudoers file or by the following command.
# visudo
And add the following line anywhere in the file.
username ALL=(ALL) ALL
EX:(dma ALL=(ALL) ALL)

4. Now migrate to non-root (normal) user and select the folder where you want to install CollabNet
Subversion Edge. I would recommend you to install the Subversion in the normal user folder.
[root@localhost ]# su username
[taashee@localhost]$ mkdir opt/subversion
Note: If you are not able to create folder subversion in opt directory, then you can create it
through root or sudo.
[taashee@localhost]$ cd opt/subversion
[taashee@localhost]$ sudo chmod o+wx /opt/subversion/
Now move the downloaded CollabNetSubversionEdge-4.0.9_linux-x86_64.tar package to
opt/subversion.

5. Now Untar the CollabNetSubversionEdge-4.0.9_linux-x86_64.tar package by the following


command.

[username@localhost subversion]$ tar zxf CollabNetSubversionEdge-4.0.9_linux-x86_64.tar


Note: The above command will create a folder named csvn.
[dma@localhost subversion]$ cd csvn
Now we will install the application so that subversion will start automatically when the server
restarts. For doing this type the following command.
Note: To set up the server so that i
t starts automatically when rebooted, you will need to have root/sudo access and follow these
steps.

Edit the configuration. When a process is started at server startup it runs as root. You do not want
the CSVN console to run as root, you want it to run as a specific user -- whatever your login user
is.
a. To do this, edit the file data/conf/csvn.conf.
$ vi data/conf/csvn.conf
b. Scroll down a little bit until you see #RUN_AS_USER= . Uncomment it out and add
your username.
Example:
RUN_AS_USER= username
(RUN_AS_USER= dma)
c. Save the changes.

[taashee@localhost csvn]$ sudo E bin/csvn install

Now we will start the server. Be sure that you are not logged in as root.

[taashee@localhost csvn]$ bin/csvn start

This will take a few minutes and the script will loop until it sees that the server is running.
Note: If the server does not start, then try starting the server with this command:
[taashee@localhost csvn]$ bin/csvn console
6. Add the following line to /etc/sysconfig/iptables
# iptables -A INPUT p tcp --dport 3343 j ACCEPT
Restart firewall to update the changes
# service iptables restart

Installation is done, now open the following link:

http://localhost:3343/csvn
username: admin
password: admin
Note: If you are not able to see your CSVN server on the browser, then just disabled the your
system Firewall by entering setup command in the terminal window.
# setup
Or
Go to System>Administration>Firewall and disable it.
Note: You can change the IP address of your subversion server with your machine IP address by
editing
opt/subversion/csvn/data/conf/csvn.conf file (at line no. 62) by the following command.
$ sudo vi data/conf/csvn.conf
OR
$ sudo gedit data/conf/csvn.conf
Subversion Edge also starts an SSL-protected version using a self-signed SSL certificate.
You can access the SSL version on this URL:
https://localhost:4434/csvn
http://ravindrasinghgohil.blogspot.in/2012/02/steps-to-install-bugzilla-42-on-centos.html
http://help.collab.net/index.jsp?topic=/csvn/action/configurecsvn.html

Anda mungkin juga menyukai