Let’s face it – there isn’t alot of helpful documentation out there when it comes to installing request-tracker. Hopefully this guide can answer some questions.
For those of you who don’t know what request-tracker is, it’s a rather extensive open source ticket and request management system.
I’m making the assumption that you do not have apache2, mysql and a few other bits and pieces installed.
If you do, you may need to approach some of the steps differently.
Become root:
sudo -s
Ensure your system is up to date:
apt-get update
apt-get upgrade
Install build-essential and unzip:
apt-get install build-essential unzip
Update cpan configuration:
cpan
o conf init
o conf prerequisites_policy follow
o conf commit
exit
Install apache2/libapache2/mysql/postfix (if you haven’t already):
apt-get install apache2 libapache2-mod-perl2 mysql-server postfix
Download request-tracker 3.8.2:
wget http://download.bestpractical.com/pub/rt/release/rt-3.8.2.tar.gz
Untar the archive:
tar zxvf rt-3.8.2.tar.gz
cd rt-3.8.2
Configure:
./configure
Check if you have the required dependencies (chances are you need to install them):
make testdeps
If you are warned that you have missing dependencies, escape and perform the following. Otherwise, skip to make install (below).
Install YAML:
perl -MCPAN -e 'install +YAML'
Download and install the required dependencies (select yes at all prompts):
make fixdeps
You might find a dependency or two may fail, try (select yes at all prompts):
RT_FIX_DEPS_CMD='/usr/bin/perl -MCPAN -e"install %s"'
perl -MCPAN -e 'install Bundle::LWP'
make fixdeps
Now let’s make sure that all the dependencies have been installed:
make testdeps
If successful, we should be prompted with:
All dependencies have been found.
We can now install request-tracker 3.8.2:
make install
This will install request-tracker to /opt/rt3
Create a copy of request-tracker’s main configuration file (incase things go wrong):
cp /opt/rt3/etc/RT_SiteConfig.pm /opt/rt3/etc/RT_SiteConfig.pm.old
Open RT_SiteConfig.pm for editing:
pico /opt/rt3/etc/RT_SiteConfig.pm
Replace the contents of the existing file with the following:
# RT_SiteConfig.pm
#
# These are the bits you absolutely *must* edit.
#
# To find out how, please read
# /usr/share/doc/request-tracker3.6/NOTES.Debian
# THE BASICS:
Set($rtname, 'support.example.org');
Set($Organization, 'example.org');
Set($CorrespondAddress , 'support@example.org');
Set($CommentAddress , 'support-comment@example.org');
Set($Timezone , ‘GMT’); # obviously choose what suits you
# THE DATABASE:
Set($DatabaseType, 'mysql'); # e.g. Pg or mysql
# These are the settings we used above when creating the RT database,
# you MUST set these to what you chose in the section above.
Set($DatabaseUser , 'rtuser');
Set($DatabasePassword , 'wibble');
Set($DatabaseName , 'rt3'); # Ensure this is set to rt3!
# THE WEBSERVER:
Set($WebPath , "/rt");
Set($WebBaseURL , "http://host.example.org");
1;
Administer mysql as root:
mysql -u root -p
Create the rt3 database and grant the appropriate permissions:
GRANT ALL PRIVILEGES ON rt3.* TO 'rtuser'@'localhost' IDENTIFIED BY 'wibble'; FLUSH PRIVILEGES;
Exit mysql administration:
exit
Populate the rt3 database:
make initialize-database
Make a copy of httpd.conf:
cp /etc/apache2/httpd.conf /etc/apache2/httpd.conf.old
Edit httpd.conf:
pico /etc/apache2/httpd.conf
Replace the contents of this file with the following:
<VirtualHost *:80>
ServerName www.example.com
ServerAdmin Email.Address@example.com
# config for your main content
DocumentRoot /var/www
<Directory /var/www>
# here and in other places goes config
# of your main host
</Directory>
# as RT is out of document root then we want alias
# and should define directory access
Alias /rt/ /opt/rt3/share/html/
<Directory /opt/rt3/share/html/>
Order allow,deny
Allow from all
</Directory>
PerlRequire /opt/rt3/bin/webmux.pl
<Location /rt/>
AddDefaultCharset UTF-8
SetHandler perl-script
PerlHandler RT::Mason
</Location>
</VirtualHost>
Restart apache2:
/etc/init.d/apache2 restart
Browse to:
http://yourbox/rt/
Update:
The default username and password for the request-tracker portal is root/password.
Bingo!
I understand that request-tracker has the ability to amend incoming e-mail to a specific request queue, however, I am having difficulty getting postfix to play nice with my Exchange server.
This guide will be updated when I figure it out!