Introduction
OTRS (Open-source Ticket Request System) is a free and open-source trouble ticket system software package that a company, organization, or other entity can use to assign tickets to incoming queries and track further communications about them. It is a means of managing incoming inquiries, complaints, support requests, defect reports, and other communications.
Helpdesk System
Installation
Ubuntu already has a package for OTRS in the repositories. The problem is that often times some of OTRS' built-in features don't work with the provided package or the OTRS software itself is outdated. The following steps will enable you to download and install OTRS on an Ubuntu server using the files provided by OTRS and Perl modules from within Ubuntu's repositories.
Prerequisites
The following conditions must be met before proceeding with the installation of OTRS
- Basic Ubuntu 12.04 LTS server / 13.04 server, fully updated
sudo aptitude update sudo aptitude dist-upgrade
- OpenSSH server
- LAMP Server
sudo tasksel
- Fetchmail Package
sudo aptitude install fetchmail
Source
Obtain a copy of a recent version of OTRS from the OTRS site (http://www.otrs.com/en/open-source).
wget http://ftp.otrs.org/pub/otrs/otrs-3.2.5.tar.gz
Extract the archive
tar -xzf otrs-3.2.5.tar.gz
Move the extracted directory to its permanent location
sudo mv otrs-3.2.5 /opt/otrs
Users and Permissions
OTRS needs to run as its own user. This presents an interesting situation as, by default, Apache2 runs as the user www-data. The following commands will add an OTRS service account/user and correct permissions for directories and files.
sudo useradd -r -d /opt/otrs/ -c 'OTRS user' otrs sudo usermod -g www-data otrs cd /opt/otrs/bin sudo ./otrs.SetPermissions.pl --otrs-user=otrs --otrs-group=otrs --web-user=www-data --web-group=www-data /opt/otrs
Perl Modules
There are many features in OTRS, some of which require the installation of additional Perl modules. The base Ubuntu server install will leave your OTRS implementation with some broken requirements. You can check to see which Perl modules have failed by running the following:
cd /opt/otrs/bin sudo ./otrs.CheckModules.pl
The following command should fix the failed Perl modules.
sudo aptitude install liblwp-useragent-determined-perl libapache2-reload-perl libnet-smtp-ssl-perl libnet-smtp-tls-butmaintained-perl
You can/should verify that, at the very least, all required modules are listed as "ok"
There are a number of optional moduels that should prove to be useful (i.e. PDF functionality, LDAP connectivity, etc.) The following command will install Perl modules that will enable many useful features in OTRS.
sudo aptitude install libgd-gd2-perl libgd-graph-perl libgd-text-perl libjson-xs-perl libnet-dns-perl libyaml-libyaml-perl libpdf-api2-simple-perl libtext-csv-xs-perl libxml-parser-perl libmail-imapclient-perl libnet-ldap-perl
*Please note that this does not install ALL optional modules.
Cron Jobs
The cron jobs for OTRS must be run as the OTRS user you created previously. The following steps/commands will enable you to setup the cron jobs for the OTRS user
cd /opt/otrs/var/cron sudu su for foo in *.dist; do cp $foo `basename $foo .dist`; done sudo su otrs cd /opt/otrs/bin ./Cron.sh start
While still logged in as the 'otrs' user, verify that the cron jobs are in place with the following command
crontab -l
Configuration
Apache2
The OTRS source files include a conf file specifically for Apache. The commands below make a copy of that conf file and includes it into the working Apache configuration
sudo cp -va /opt/otrs/scripts/apache2-httpd.include.conf /etc/apache2/sites-available/otrs.conf cd /etc/apache2/sites-available/ sudo chown root:root otrs.conf sudo a2ensite otrs sudo service apache2 reload
Finalization
At this point, you're ready to finalize everything. To do so, you need to access OTRS' web interface isntaller. You'll need to load your web browser with the URL for your OTRS instal. For instance, if it's going to be on host 192.168.1.50, you'll need to load http://192.168.1.50/otrs/installer.pl
ITSM
Installation
Installation of the ITSM module can be performed using the web interface for OTRS. This can be problematic if your connectivity to the server is interrupted or your browser is interrupted. The following steps allow you to install the ITSM module into OTRS from the command line. You don't have to install the complete ITSM package. If there are only certain pieces of ITSM you'd like to install, please feel free to download and install only those packages.
Prerequisites
In order to install the ITSM module, you must first have the OTRS Helpdesk/Ticketing system up and running.
Source
Obtain a copy of the ITSM module from the OTRS site (http://www.otrs.com/en/open-source) and move it to a location that youc an remember (i.e /tmp).
http://ftp.otrs.org/pub/otrs/itsm/bundle32/ITSM-3.2.3.opm sudo mv ITSM-3.2.3.opm /tmp/
Change into the /opt/otrs/bin directory and run the install command for the OPM file
cd ~otrs/bin sudo -u otrs ./opm -a install -p /tmp/ITSM-3.2.3.opm