Installation of OTRS 3.x on CentOS 5.5
How To install OTRS 3.0b6 on CentOS 5.5
Minimum prerequisites
Basic install of CentOS 5.5
CentOS SELinux is set to permissive.
CentOS firewall must have HTTP as trusted.
OTRS requires Apache webserver & backend database to be installed, configured, and running. In a basic install of CentOS 5.5 Apache was installed & MySQL (my database of choice) was not.
Internet connection
Apache
Verify that Apache (httpd) is installed by using the below command. Confirm that httpd<something> is under installed packages.
# yum list httpd Loaded plugins: fastestmirror Loading mirror speeds from cached hostfile * addons: mirror.trouble-free.net * base: mirror.steadfast.net * extras: mirror.trouble-free.net * updates: styx.biochem.wfubmc.edu Installed Packages httpd.x86_64 2.2.3-43.el5.centos installed
Verify default run level of httpd:
# chkconfig --list httpd httpd 0:off 1:off 2:off 3:off 4:off 5:off 6:off
Enable httpd on run levels:
# chkconfig httpd on
Verify run levels enabled for httpd:
# chkconfig --list httpd httpd 0:off 1:off 2:on 3:on 4:on 5:on 6:off
Start httpd:
# service httpd start
MySQL
I installed MySQL (mysqld) using yum versus RPM or source. You can use a group command to install MySQL group or select individual packages. I opted for individual packages.
I provided steps for individual and group install below.
Install MySQL Database group
Use yum to query which packages are available in MySQL group to determine whether you want group install:
# yum groupinfo 'MySQL Database' Loaded plugins: fastestmirror Setting up Group Process Loading mirror speeds from cached hostfile * addons: mirror.steadfast.net * base: mirror.nexcess.net * extras: mirror.steadfast.net * updates: mirrors.gigenet.com Group: MySQL Database Description: This package group contains packages useful for use with MySQL. Mandatory Packages: mysql Default Packages: MySQL-python libdbi-dbd-mysql mysql-connector-odbc mysql-server perl-DBD-MySQL unixODBC Optional Packages: mod_auth_mysql mysql-bench mysql-devel php-mysql qt-MySQL
To install MySQL group use this command (skip this step to install individual packages):
# yum groupinstall 'MySQL Database'
Install MySQL individual packages
Here are commands I used to install specific packages:
# yum install mysql-server mysql php-mysql Loaded plugins: fastestmirror Loading mirror speeds from cached hostfile * addons: mirror.trouble-free.net * base: mirror.steadfast.net * extras: mirror.trouble-free.net * updates: styx.biochem.wfubmc.edu Setting up Install Process Resolving Dependencies --> Running transaction check ---> Package mysql.i386 0:5.0.77-4.el5_5.3 set to be updated --> Processing Dependency: perl(DBI) for package: mysql ---> Package mysql.x86_64 0:5.0.77-4.el5_5.3 set to be updated ---> Package mysql-server.x86_64 0:5.0.77-4.el5_5.3 set to be updated --> Processing Dependency: perl-DBD-MySQL for package: mysql-server ---> Package php-mysql.x86_64 0:5.1.6-27.el5 set to be updated --> Processing Dependency: php-common = 5.1.6-27.el5 for package: php-mysql --> Processing Dependency: php-pdo for package: php-mysql --> Running transaction check ---> Package perl-DBD-MySQL.x86_64 0:3.0007-2.el5 set to be updated ---> Package perl-DBI.x86_64 0:1.52-2.el5 set to be updated ---> Package php-common.x86_64 0:5.1.6-27.el5 set to be updated ---> Package php-pdo.x86_64 0:5.1.6-27.el5 set to be updated --> Finished Dependency Resolution Dependencies Resolved ================================================================================ Package Arch Version Repository Size ================================================================================ Installing: mysql i386 5.0.77-4.el5_5.3 updates 4.8 M mysql x86_64 5.0.77-4.el5_5.3 updates 4.8 M mysql-server x86_64 5.0.77-4.el5_5.3 updates 9.8 M php-mysql x86_64 5.1.6-27.el5 base 89 k Installing for dependencies: perl-DBD-MySQL x86_64 3.0007-2.el5 base 148 k perl-DBI x86_64 1.52-2.el5 base 600 k php-common x86_64 5.1.6-27.el5 base 153 k php-pdo x86_64 5.1.6-27.el5 base 66 k Transaction Summary ================================================================================ Install 8 Package(s) Upgrade 0 Package(s) Total download size: 20 M Is this ok [y/N]: y Downloading Packages: (1/8): php-pdo-5.1.6-27.el5.x86_64.rpm | 66 kB 00:00 (2/8): php-mysql-5.1.6-27.el5.x86_64.rpm | 89 kB 00:00 (3/8): perl-DBD-MySQL-3.0007-2.el5.x86_64.rpm | 148 kB 00:00 (4/8): php-common-5.1.6-27.el5.x86_64.rpm | 153 kB 00:00 (5/8): perl-DBI-1.52-2.el5.x86_64.rpm | 600 kB 00:00 (6/8): mysql-5.0.77-4.el5_5.3.i386.rpm | 4.8 MB 00:17 (7/8): mysql-5.0.77-4.el5_5.3.x86_64.rpm | 4.8 MB 00:15 (8/8): mysql-server-5.0.77-4.el5_5.3.x86_64.rpm | 9.8 MB 00:24 -------------------------------------------------------------------------------- Total 355 kB/s | 20 MB 00:58 Running rpm_check_debug Running Transaction Test Finished Transaction Test Transaction Test Succeeded Running Transaction Installing : perl-DBI 1/8 Installing : mysql 2/8 Installing : php-common 3/8 Installing : php-pdo 4/8 Installing : perl-DBD-MySQL 5/8 Installing : mysql 6/8 Installing : mysql-server 7/8 Installing : php-mysql 8/8 Installed: mysql.i386 0:5.0.77-4.el5_5.3 mysql.x86_64 0:5.0.77-4.el5_5.3 mysql-server.x86_64 0:5.0.77-4.el5_5.3 php-mysql.x86_64 0:5.1.6-27.el5 Dependency Installed: perl-DBD-MySQL.x86_64 0:3.0007-2.el5 perl-DBI.x86_64 0:1.52-2.el5 php-common.x86_64 0:5.1.6-27.el5 php-pdo.x86_64 0:5.1.6-27.el5 Complete!
mysqld has been installed but not configured for run level:
# chkconfig --list mysqld mysqld 0:off 1:off 2:off 3:off 4:off 5:off 6:off
Set mysqld to run level 2, 3, & 5:
# chkconfig --levels 235 mysqld on
Confirm run levels for mysqld:
# chkconfig --list mysqld mysqld 0:off 1:off 2:on 3:on 4:off 5:on 6:off
Starting MySQL 1st Time
Start mysqld. Note that when you run mysqld for first time you will receive some friendly reminders:
# service mysqld start <<text removed for clarity>> Starting MySQL: [ OK ]
We now follow the great directions provided & run the mysql secure installation script:
# /usr/bin/mysql_secure_installation
You will be presented with some questions regarding securing your mysqld installation:
<<some text removed for clarity>> Set root password? [Y/n] Y New password: Re-enter new password: Password updated successfully! Reloading privilege tables.. ... Success! Remove anonymous users? [Y/n] Y ... Success! Disallow root login remotely? [Y/n] Y ... Success! Remove test database and access to it? [Y/n] Y - Dropping test database... ... Success! - Removing privileges on test database... ... Success! Reload privilege tables now? [Y/n] Y ... Success! Cleaning up... All done! If you've completed all of the above steps, your MySQL installation should now be secure. Thanks for using MySQL!
MySQL should be ready for OTRS.
OTRS
Download OTRS
Download OTRS from http://otrs.org/download/
$ wget http://ftp.otrs.org/pub/otrs/RPMS/fedora/4/otrs-3.0.0-beta6.noarch.rpm --2010-10-29 15:24:32-- http://ftp.otrs.org/pub/otrs/RPMS/fedora/4/otrs-3.0.0-beta6.noarch.rpm Resolving ftp.otrs.org... 88.198.19.81 Connecting to ftp.otrs.org|88.198.19.81|:80... connected. HTTP request sent, awaiting response... 200 OK Length: 17954266 (17M) [application/x-rpm] Saving to: `otrs-3.0.0-beta6.noarch.rpm' 100%[======================================>] 17,954,266 4.23M/s in 5.2s 2010-10-29 15:24:38 (3.29 MB/s) - `otrs-3.0.0-beta6.noarch.rpm' saved [17954266/17954266]
Verify file integrity by matching MD5 hash with entry on http://otrs.org/download/
$ md5sum otrs-3.0.0-beta6.noarch.rpm 488cabcf544202f6affc1b54dc911597 otrs-3.0.0-beta6.noarch.rpm
Resolve dependencies
Determine the dependencies of otrs rpm file:
# rpm -qpR otrs-3.0.0-beta1.noarch.rpm perl perl-DBI perl-DBD-MySQL perl-URI mod_perl httpd mysql mysql-server procmail perl-libwww-perl perl-Net-DNS perl-IO-Socket-SSL perl-XML-Parser /bin/sh
You can query your system or try to install & read errors to determine which packages are missing. I opted to install & read errors:
# rpm -ivh otrs-3.0.0-beta1.noarch.rpm error: Failed dependencies: perl-URI is needed by otrs-3.0.0-beta1.noarch mod_perl is needed by otrs-3.0.0-beta1.noarch perl-libwww-perl is needed by otrs-3.0.0-beta1.noarch perl-Net-DNS is needed by otrs-3.0.0-beta1.noarch perl-IO-Socket-SSL is needed by otrs-3.0.0-beta1.noarch perl-XML-Parser is needed by otrs-3.0.0-beta1.noarch
Now I know which dependencies to install.
Note: Optionally you can install RPM using yum & yum should automatically resolve your dependencies. However, since you are reading this I suspect you need practice.
Note: You can install all dependencies at once using one yum command simply put space between each package (like I did with mysql single packages above). However, since you are reading this I suspect you need the practice. :)
Resolve perl-URI dependency:
# yum install perl-URI Loaded plugins: fastestmirror Loading mirror speeds from cached hostfile * addons: mirror.trouble-free.net * base: mirror.steadfast.net * extras: mirror.trouble-free.net * updates: styx.biochem.wfubmc.edu Setting up Install Process Resolving Dependencies --> Running transaction check ---> Package perl-URI.noarch 0:1.35-3 set to be updated --> Finished Dependency Resolution Dependencies Resolved ================================================================================ Package Arch Version Repository Size ================================================================================ Installing: perl-URI noarch 1.35-3 base 116 k Transaction Summary ================================================================================ Install 1 Package(s) Upgrade 0 Package(s) Total download size: 116 k Is this ok [y/N]: y Downloading Packages: perl-URI-1.35-3.noarch.rpm | 116 kB 00:00 Running rpm_check_debug Running Transaction Test Finished Transaction Test Transaction Test Succeeded Running Transaction Installing : perl-URI 1/1 Installed: perl-URI.noarch 0:1.35-3 Complete!
Resolve mod_perl dependency:
# yum install mod_perl Loaded plugins: fastestmirror Loading mirror speeds from cached hostfile * addons: mirror.trouble-free.net * base: mirror.steadfast.net * extras: mirror.trouble-free.net * updates: styx.biochem.wfubmc.edu Setting up Install Process Resolving Dependencies --> Running transaction check ---> Package mod_perl.x86_64 0:2.0.4-6.el5 set to be updated --> Processing Dependency: perl(BSD::Resource) for package: mod_perl --> Running transaction check ---> Package perl-BSD-Resource.x86_64 0:1.28-1.fc6.1 set to be updated --> Finished Dependency Resolution Dependencies Resolved ================================================================================ Package Arch Version Repository Size ================================================================================ Installing: mod_perl x86_64 2.0.4-6.el5 base 4.0 M Installing for dependencies: perl-BSD-Resource x86_64 1.28-1.fc6.1 base 29 k Transaction Summary ================================================================================ Install 2 Package(s) Upgrade 0 Package(s) Total download size: 4.1 M Is this ok [y/N]: y Downloading Packages: (1/2): perl-BSD-Resource-1.28-1.fc6.1.x86_64.rpm | 29 kB 00:00 (2/2): mod_perl-2.0.4-6.el5.x86_64.rpm | 4.0 MB 00:00 -------------------------------------------------------------------------------- Total 3.9 MB/s | 4.1 MB 00:01 Running rpm_check_debug Running Transaction Test Finished Transaction Test Transaction Test Succeeded Running Transaction Installing : perl-BSD-Resource 1/2 Installing : mod_perl 2/2 Installed: mod_perl.x86_64 0:2.0.4-6.el5 Dependency Installed: perl-BSD-Resource.x86_64 0:1.28-1.fc6.1 Complete!
Resolve perl-libwww-perl dependency:
# yum install perl-libwww-perl Loaded plugins: fastestmirror Loading mirror speeds from cached hostfile * addons: mirror.trouble-free.net * base: mirror.steadfast.net * extras: mirror.trouble-free.net * updates: styx.biochem.wfubmc.edu Setting up Install Process Resolving Dependencies --> Running transaction check ---> Package perl-libwww-perl.noarch 0:5.805-1.1.1 set to be updated --> Processing Dependency: perl-HTML-Parser >= 3.33 for package: perl-libwww-perl --> Processing Dependency: perl(HTML::Entities) for package: perl-libwww-perl --> Processing Dependency: perl(Compress::Zlib) for package: perl-libwww-perl --> Running transaction check ---> Package perl-Compress-Zlib.x86_64 0:1.42-1.fc6 set to be updated ---> Package perl-HTML-Parser.x86_64 0:3.55-1.fc6 set to be updated --> Processing Dependency: perl-HTML-Tagset >= 3.03 for package: perl-HTML-Parser --> Processing Dependency: perl(HTML::Tagset) for package: perl-HTML-Parser --> Running transaction check ---> Package perl-HTML-Tagset.noarch 0:3.10-2.1.1 set to be updated --> Finished Dependency Resolution Dependencies Resolved ================================================================================ Package Arch Version Repository Size ================================================================================ Installing: perl-libwww-perl noarch 5.805-1.1.1 base 376 k Installing for dependencies: perl-Compress-Zlib x86_64 1.42-1.fc6 base 52 k perl-HTML-Parser x86_64 3.55-1.fc6 base 92 k perl-HTML-Tagset noarch 3.10-2.1.1 base 15 k Transaction Summary ================================================================================ Install 4 Package(s) Upgrade 0 Package(s) Total download size: 534 k Is this ok [y/N]: y Downloading Packages: (1/4): perl-HTML-Tagset-3.10-2.1.1.noarch.rpm | 15 kB 00:00 (2/4): perl-Compress-Zlib-1.42-1.fc6.x86_64.rpm | 52 kB 00:00 (3/4): perl-HTML-Parser-3.55-1.fc6.x86_64.rpm | 92 kB 00:00 (4/4): perl-libwww-perl-5.805-1.1.1.noarch.rpm | 376 kB 00:00 -------------------------------------------------------------------------------- Total 858 kB/s | 534 kB 00:00 Running rpm_check_debug Running Transaction Test Finished Transaction Test Transaction Test Succeeded Running Transaction Installing : perl-Compress-Zlib 1/4 Installing : perl-HTML-Tagset 2/4 Installing : perl-HTML-Parser 3/4 Installing : perl-libwww-perl 4/4 Installed: perl-libwww-perl.noarch 0:5.805-1.1.1 Dependency Installed: perl-Compress-Zlib.x86_64 0:1.42-1.fc6 perl-HTML-Parser.x86_64 0:3.55-1.fc6 perl-HTML-Tagset.noarch 0:3.10-2.1.1 Complete!
Resolve perl-Net-DSN dependency:
# yum install perl-Net-DSN Loaded plugins: fastestmirror Loading mirror speeds from cached hostfile * addons: mirror.trouble-free.net * base: mirror.steadfast.net * extras: mirror.trouble-free.net * updates: styx.biochem.wfubmc.edu Setting up Install Process No package perl-Net-DSN available. Nothing to do [root@null-0023ae875f47 opt]# yum install perl-Net-DNS Loaded plugins: fastestmirror Loading mirror speeds from cached hostfile * addons: mirror.trouble-free.net * base: mirror.steadfast.net * extras: mirror.trouble-free.net * updates: styx.biochem.wfubmc.edu Setting up Install Process Resolving Dependencies --> Running transaction check ---> Package perl-Net-DNS.x86_64 0:0.59-3.el5 set to be updated --> Processing Dependency: perl(Digest::HMAC_MD5) for package: perl-Net-DNS --> Processing Dependency: perl(Net::IP) for package: perl-Net-DNS --> Running transaction check ---> Package perl-Digest-HMAC.noarch 0:1.01-15 set to be updated --> Processing Dependency: perl(Digest::SHA1) for package: perl-Digest-HMAC ---> Package perl-Net-IP.noarch 0:1.25-2.fc6 set to be updated --> Running transaction check ---> Package perl-Digest-SHA1.x86_64 0:2.11-1.2.1 set to be updated --> Finished Dependency Resolution Dependencies Resolved ================================================================================ Package Arch Version Repository Size ================================================================================ Installing: perl-Net-DNS x86_64 0.59-3.el5 base 215 k Installing for dependencies: perl-Digest-HMAC noarch 1.01-15 base 12 k perl-Digest-SHA1 x86_64 2.11-1.2.1 base 49 k perl-Net-IP noarch 1.25-2.fc6 base 31 k Transaction Summary ================================================================================ Install 4 Package(s) Upgrade 0 Package(s) Total download size: 306 k Is this ok [y/N]: y Downloading Packages: (1/4): perl-Digest-HMAC-1.01-15.noarch.rpm | 12 kB 00:00 (2/4): perl-Net-IP-1.25-2.fc6.noarch.rpm | 31 kB 00:00 (3/4): perl-Digest-SHA1-2.11-1.2.1.x86_64.rpm | 49 kB 00:00 (4/4): perl-Net-DNS-0.59-3.el5.x86_64.rpm | 215 kB 00:00 -------------------------------------------------------------------------------- Total 565 kB/s | 306 kB 00:00 Running rpm_check_debug Running Transaction Test Finished Transaction Test Transaction Test Succeeded Running Transaction Installing : perl-Digest-SHA1 1/4 Installing : perl-Digest-HMAC 2/4 Installing : perl-Net-IP 3/4 Installing : perl-Net-DNS 4/4 Installed: perl-Net-DNS.x86_64 0:0.59-3.el5 Dependency Installed: perl-Digest-HMAC.noarch 0:1.01-15 perl-Digest-SHA1.x86_64 0:2.11-1.2.1 perl-Net-IP.noarch 0:1.25-2.fc6 Complete!
Resolve perl-IO-Socket-SSL dependency:
# perl-IO-Socket-SSL -bash: perl-IO-Socket-SSL: command not found [root@null-0023ae875f47 opt]# perl-IO-Socket-SSyum L -bash: perl-IO-Socket-SSyum: command not found [root@null-0023ae875f47 opt]# yum install perl-IO-Socket-SSL Loaded plugins: fastestmirror Loading mirror speeds from cached hostfile * addons: mirror.trouble-free.net * base: mirror.steadfast.net * extras: mirror.trouble-free.net * updates: styx.biochem.wfubmc.edu Setting up Install Process Resolving Dependencies --> Running transaction check ---> Package perl-IO-Socket-SSL.noarch 0:1.01-1.fc6 set to be updated --> Processing Dependency: perl(Net::SSLeay) >= 1.21 for package: perl-IO-Socket-SSL --> Running transaction check ---> Package perl-Net-SSLeay.x86_64 0:1.30-4.fc6 set to be updated --> Finished Dependency Resolution Dependencies Resolved ================================================================================ Package Arch Version Repository Size ================================================================================ Installing: perl-IO-Socket-SSL noarch 1.01-1.fc6 base 49 k Installing for dependencies: perl-Net-SSLeay x86_64 1.30-4.fc6 base 192 k Transaction Summary ================================================================================ Install 2 Package(s) Upgrade 0 Package(s) Total download size: 241 k Is this ok [y/N]: y Downloading Packages: (1/2): perl-IO-Socket-SSL-1.01-1.fc6.noarch.rpm | 49 kB 00:00 (2/2): perl-Net-SSLeay-1.30-4.fc6.x86_64.rpm | 192 kB 00:00 -------------------------------------------------------------------------------- Total 785 kB/s | 241 kB 00:00 Running rpm_check_debug Running Transaction Test Finished Transaction Test Transaction Test Succeeded Running Transaction Installing : perl-Net-SSLeay 1/2 Installing : perl-IO-Socket-SSL 2/2 Installed: perl-IO-Socket-SSL.noarch 0:1.01-1.fc6 Dependency Installed: perl-Net-SSLeay.x86_64 0:1.30-4.fc6 Complete!
Resolve perl-XML-Parser dependency:
# yum install perl-XML-Parser Loaded plugins: fastestmirror Loading mirror speeds from cached hostfile * addons: mirror.trouble-free.net * base: mirror.steadfast.net * extras: mirror.trouble-free.net * updates: styx.biochem.wfubmc.edu Setting up Install Process Resolving Dependencies --> Running transaction check ---> Package perl-XML-Parser.x86_64 0:2.34-6.1.2.2.1 set to be updated --> Finished Dependency Resolution Dependencies Resolved ================================================================================ Package Arch Version Repository Size ================================================================================ Installing: perl-XML-Parser x86_64 2.34-6.1.2.2.1 base 210 k Transaction Summary ================================================================================ Install 1 Package(s) Upgrade 0 Package(s) Total download size: 210 k Is this ok [y/N]: y Downloading Packages: perl-XML-Parser-2.34-6.1.2.2.1.x86_64.rpm | 210 kB 00:00 Running rpm_check_debug Running Transaction Test Finished Transaction Test Transaction Test Succeeded Running Transaction Installing : perl-XML-Parser 1/1 Installed: perl-XML-Parser.x86_64 0:2.34-6.1.2.2.1 Complete!
Install via RPM command
Now that all dependencies have been met you can install RPM using yum:
# yum --nogpgcheck install otrs-3.0.0-beta1.noarch.rpm Loaded plugins: fastestmirror Loading mirror speeds from cached hostfile * addons: mirror.trouble-free.net * base: mirror.steadfast.net * extras: mirror.trouble-free.net * updates: styx.biochem.wfubmc.edu Setting up Install Process Examining otrs-3.0.0-beta1.noarch.rpm: otrs-3.0.0-beta1.noarch Marking otrs-3.0.0-beta1.noarch.rpm to be installed Resolving Dependencies --> Running transaction check ---> Package otrs.noarch 0:3.0.0-beta1 set to be updated --> Finished Dependency Resolution Dependencies Resolved ================================================================================ Package Arch Version Repository Size ================================================================================ Installing: otrs noarch 3.0.0-beta1 /otrs-3.0.0-beta1.noarch 28 M Transaction Summary ================================================================================ Install 1 Package(s) Upgrade 0 Package(s) Total size: 28 M Is this ok [y/N]: y Downloading Packages: Running rpm_check_debug Running Transaction Test Finished Transaction Test Transaction Test Succeeded Running Transaction Check OTRS user ... otrs added. Installing : otrs 1/1 Next steps: [httpd services] Restart httpd 'service httpd restart' [mysqld service] Start mysqld 'service mysqld start' [install the OTRS database] Use a webbrowser and open this link: http://null-0023ae875f47.dhcp.sprint/otrs/installer.pl [OTRS services] Start OTRS 'service otrs start' (service otrs {start|stop|status|restart). ((enjoy)) Your OTRS Team Installed: otrs.noarch 0:3.0.0-beta1 Complete!
Basic Apache config
Make backup of httpd.conf file.
# cp httpd.conf httpd.conf.back
Edit httpd.conf file:
# vi httpd.conf
At minimum update these entries:
ServerAdmin ptay@yourdomain.com ServerName [hostname or IP address]:80 Listen yourIP:80
Restart httpd:
# service httpd restart Stopping httpd: [ OK ] Starting httpd: [ OK ]
Setup MySQL database
Follow simple steps provided on OTRS docs page. Thank you OTRS devs for providing a simple web installer!
If on same machine as OTRS install you point your browser to http://localhost/otrs/installer.pl otherwise replace localhost with domain name or IP address.
Logging into OTRS
After configuring MySQL via web installer you should be able to log into OTRS via http://IPaddress/otrs/index.pl with user root@localhost and default password.
Enjoy OTRS!
Tweaking OTRS
Coming soon..
OTRS wiki
Another copy of this guide will be maintained on OTRS wiki for a larger audience.