Chapter 3. Installation of the OTRS framework

Table of Contents

The simple way - Installation of prebuilt packages
Installing the rpm on a SUSE distro
Installing OTRS on a Debian system
Installing OTRS on Microsoft Windows systems
Installation from source (Linux, Unix)
Preparing the installation from source
Installation of needed perl modules
Configuring the apache web server
Configuring the database
Setting up the cron jobs for OTRS

Abstract

This chapter describes the installation and the basic configuration of the central OTRS framework. You'll find information about installing OTRS manually from source or with a binary package, ex. rpm or for Win32.

The configuration of the web and database server, the interface between OTRS and the database, the installation of needed perl modules, setting proper access rights for OTRS, setting up the cron jobs for OTRS and some basic settings in the config files of OTRS are described in this chapter.

When you have finished reading this chapter, you should have a running OTRS system installed on your operating system where you can login and administrate the system via the web interface.

The simple way - Installation of prebuilt packages

The simplest and most comfortable way to install OTRS is to use prebuilt packages. Many prebuilt packages of OTRS can be found in the download area on http://www.otrs.org . The following sections describe the installation of OTRS with a prebuilt or binary package on SUSE, Debian and Microsoft Windows systems. Use prebuilt packages to install OTRS and only setup OTRS manually, if you have no other possibility.

Installing the rpm on a SUSE distro

This section describes the installation of a prebuilt rpm package on a SUSE Linux distro. We tested the SUSE versions from 7.x to 10.0. Before you start the installation please have a look on http://www.otrs.org and check, if a newer OTRS rpm package is available. Please use the newer rpm package, if available.

Please install OTRS with yast (yast2) or via the command line and rpm. Because OTRS needs some perl modules which are not installed on a SUSE system by default, we recommend to use yast, because yast solves the package dependencies automatically.

If you decide to install OTRS via the command line and rpm, you have to install the needed perl modules manually before. Lets say, that you have saved the file otrs.rpm into the directory /tmp, you can execute the following command to install OTRS:

linux:~ # rpm -ivh /tmp/otrs.rpm
otrs                        ##################################################
Check OTRS user (/etc/passwd)... otrs exists.

Next steps:

[SuSEconfig]
 Execute 'SuSEconfig' to configure the webserver.

[start Apache and MySQL]
 Execute 'rcapache restart' and 'rcmysql start' in case they don't run.

[install the OTRS database]
 Use a webbrowser and open this link:
 http://localhost/otrs/installer.pl

[OTRS services]
 Start OTRS 'rcotrs start-force' (rcotrs {start|stop|status|restart|start-force|stop-force}).

Have fun!

 Your OTRS Team
 http://otrs.org/

linux:~ #

After the installation of the OTRS rpm package, you have to run SuSEconfig. Use the following command:

linux:~ # SuSEconfig
Starting SuSEconfig, the SuSE Configuration Tool...
Running in full featured mode.
Reading /etc/sysconfig and updating the system...
Executing /sbin/conf.d/SuSEconfig.aaa_at_first...
Executing /sbin/conf.d/SuSEconfig.apache...
Including /opt/otrs/scripts/apache-httpd.include.conf
Executing /sbin/conf.d/SuSEconfig.bootsplash...
Executing /sbin/conf.d/SuSEconfig.doublecheck...
Executing /sbin/conf.d/SuSEconfig.guile...
Executing /sbin/conf.d/SuSEconfig.hostname...
Executing /sbin/conf.d/SuSEconfig.ispell...
Executing /sbin/conf.d/SuSEconfig.perl...
Executing /sbin/conf.d/SuSEconfig.permissions...
Executing /sbin/conf.d/SuSEconfig.postfix...
Setting up postfix local as MDA...
Setting SPAM protection to "off"...
Executing /sbin/conf.d/SuSEconfig.profiles...
Finished.
linux:~ #

The installation of the OTRS rpm is finished. Restart your webserver to load the OTRS specific changes in your web server configuration:

linux:~ # rcapache restart
Shutting down httpd                                         done
Starting httpd [ PERL ]                                     done
linux:~ #

In the next step you have to setup the OTRS database. If you use MySQL as the database backend, you can use the web installer of OTRS to setup the database. Use the following address to access the web installer start file.

http://localhost/otrs/installer.pl

The web installer starts. Please follow the steps and setup the system.

Warning

It is never a good idea to use default passwords. Please change the default password for the OTRS database!

Please restart the OTRS service now, to use the new configuration settings:

linux:~ # rcotrs restart-force
Shutting down OTRS
 Disable /opt/otrs/bin/PostMaster.pl ... done.
no crontab for otrs
 Shutting down cronjobs ... failed!
Shutting down OTRS (completely)
 Shutting down Apache ... done.
 Shutting down MySQL ... done.
                                                                     done
Starting OTRS (completely)
 Starting Apache ... done.
 Starting MySQL ... done.
Starting OTRS
 Checking Apache ... done.
 Checking MySQL ... done.
 Checking database connect... (It looks Ok!).
 Enable /opt/otrs/bin/PostMaster.pl ... done.
 Checking otrs spool dir...  done.
 Creating cronjobs (source /opt/otrs/var/cron/*) ... done.

  -->> http://linux.example.com/otrs/index.pl <<--
                                                                     done
                                                                     done
linux:~ #

Now the installation of OTRS is finished and you should be able to work with the system. To log into the web interface of OTRS, use the address http://localhost/otrs/index.pl in your web browser. Log in as OTRS admin and configure the system for your needs. To log in as OTRS admin use the username root@localhost and the password root.

Warning

Please change the pasword for the OTRS admin as soon as possible. It is also a default password!

Installing OTRS on a Debian system

This section Describes the installation of OTRS on Debian 3.1 (Sarge).

Install OTRS with apt-get via the command line. OTRS needs some other packages to be installed, for example a database server, a web server or some perl modules. Let apt-get take care of these dependences. Execute the following command to install OTRS:

linux:~# apt-get install otrs
Reading Package Lists... Done
Building Dependency Tree... Done
Suggested packages:
  otrs-doc
The following NEW packages will be installed:
  otrs
0 upgraded, 1 newly installed, 0 to remove and 0 not upgraded.
Need to get 947kB of archives.
After unpacking 6132kB of additional disk space will be used.
Get:1 ftp://ftp.uni-erlangen.de sarge/main otrs 1.3.2p01-5 [947kB]
Fetched 947kB in 10s (93.7kB/s)
Selecting previously deselected package otrs.
(Reading database ... 73351 files and directories currently installed.)
Unpacking otrs (from .../otrs_1.3.2p01-5_all.deb) ...
Setting up otrs (1.3.2p01-5) ...
Adding system user `otrs'...
Adding new user `otrs' (105) with group `www-data'.
Not creating home directory.
SetPermissions.sh <$Revision: 1.8 $> - set OTRS file permissions
Copyright (c) 2001-2003 Martin Edenhofer <martin@otrs.org>
Setting file permissions...
chown -R 0:0 /usr/share/otrs
chown otrs:www-data /usr/share/otrs
chown -R otrs:www-data /usr/share/otrs/var/
chown -R www-data:www-data /usr/share/otrs/var/sessions/
touch && chown otrs:www-data
/usr/share/otrs/var/log/TicketCounter.log
chmod -R 755 /usr/share/otrs/bin/
(chown && chmod 700) otrs:0
/usr/share/otrs/bin/DeleteSessionIDs.pl
(chown && chmod 700) otrs:0 /usr/share/otrs/bin/UnlockTickets.pl
(chown && chmod 700) otrs:0 /usr/share/otrs/bin/otrs.getConfig

linux:~#

After the installation of the OTRS package you need to configure the webserver for the trouble ticket system (on debian systems this is not done automaticly).

Important

The following description is based on the fact, that you use the web server apache 2.x. If you are using apache 1.3.x you have to do the same things. The configuration files of apache 1.3.x are located at /etc/apache.

Create the file otrs.conf and insert the following lines. Save the file into the directory /etc/apache2/conf.d.

#
# Basic apache configuration file for OTRS
#
# agent, admin and customer frontend
#
ScriptAlias /otrs/ "/usr/share/otrs/bin/cgi-bin/"
Alias /otrs-web/ "/usr/share/otrs/var/httpd/htdocs/"
#
<Directory "/usr/share/otrs/bin/cgi-bin/">
    AllowOverride None
    Options +ExecCGI -Includes
    Order allow,deny
    Allow from all
</Directory>
<Directory "/usr/share/otrs/var/httpd/htdocs/">
    AllowOverride None
    Order allow,deny
    Allow from all
</Directory>

Restart your webserver to use the new config settings.

linux:~# /etc/init.d/apache2 restart
Forcing reload of web server: Apache2.
linux:~#

In the next step you have to setup the OTRS database. If you use MySQL for the database backend, you can use the web installer of OTRS to setup the database. Use the following address to access the web installer start file.

http://localhost/otrs/installer.pl

The web installer starts. Please follow the steps and setup the system.

Warning

It is never a good idea to use default passwords. Please change the default password for the OTRS database!

Now the installation of OTRS is finished. You should be able to use the web interface of OTRS. The cron jobs, which are needed for OTRS, are automaticallyi installed and configured. Log in as OTRS admin and configure the system for your needs. Go to the address http://localhost/otrs/index.pl with a web browser and use "root@localhost" as username and "root" as password to access the web interface of the ticket system.

Warning

Please change this password as soon as possible too! It is also a default password!

Installing OTRS on Microsoft Windows systems

Installing OTRS on a Microsoft Window system is very easy. Download the latest installer for Win32 from http://www.otrs.org and save the file to your local file system. Then simply click on the file to execute the installer. Follow the few installation steps to setup the system, after installation you should be able to login as OTRS administrator.

Important

The Win32 installer for OTRS contains all needed components for the trouble ticket system. That means, that also the apache2 web server, the MySQL database server, perl with all needed modules and cron for Windows will be installed. For that reason you should only install OTRS on Windows systems that don't already have apache2 or another web server and MySQL installed.