本文将介绍如何在Ubuntu 11.10中如何源码安装OTRS。从http://www.otrs.com/open-source/get-otrs/software-download/下载最新的.tar.gz的源文件包。下载完毕后,我们将开始正式安装。
创建otrs用户
sudo useradd -g www-data -ms /bin/bash otrs
在ubuntu中web的组是www-data
设置密码
sudo passwd otrs
sudo apt-get install libapache2-mod-perl2 libdbd-mysql-perl libnet-dns-perl libnet-ldap-perl libio-socket-ssl-perl libpdf-api2-perl libsoap-lite-perl libgd-text-perl libgd-graph-perl libapache-dbi-perl libencode-hanextra-perl libjson-xs-perl libtext-csv-xs-perl
sudo tar -zxf otrs-3.0.11.tar.gz -C /opt cd /opt sudo mv otrs-3.0.11 otrs
cd /opt/otrs/Kernel sudo cp Config.pm.dist Config.pm sudo cp Config/GenericAgent.pm.dist Config/GenericAgent.pm
cd /opt/otrs/bin sudo ./otrs.CheckModules.pl查看是否有没有安装的包,如果没有会现在Not Install,Google或百度就可以找到对应包名,apt-get install就可以了。
所有包都通过后,继续下面的安装。
配置权限
cd /opt/otrs/bin sudo ./otrs.SetPermissions.pl --otrs-user=otrs --otrs-group=www-data --web-user=www-data --web-group=www-data /opt/otrs
sudo cp /opt/otrs/scripts/apache2-httpd.include.conf /etc/apache2/conf.d/otrs.conf service apache2 restart
访问http://localhost/otrs/installer.pl,就到看到配置页面了,填写相应的信息,下一步下一步就可以了,第三步配置Email,可以先选择跳过,以后在配置。
配置OTRS计划任务
su otrs切换OTRS用户
cd /opt/otrs/var/cron for foo in *.dist; do cp $foo `basename $foo .dist`;done cd /opt/otrs/bin ./Cron.sh start
crontab -l
Script | Function |
---|---|
aaa_base | Sets the basics for the crontab of the 'otrs' user. |
cache | Removes expired cache entries from disk. Clears the loader cache for CSS and JavaScript files. |
fetchmail | Used only if new mails will be fetched with fetchmail into the ticket system. |
generic_agent | Executes the jobs of the GenericAgent that are not stored in the database but in own config files. |
generic_agent-database | Executes the jobs of the GenericAgent that are stored in the database. |
pending_jobs | Checks system for pending tickets, and closes them or sends reminders if needed. |
postmaster | Checks the message queue of the ticket system, and delivers messages that are still in the queues. |
postmaster_mailbox | Fetches the mails from the POP3 accounts that were specified in the admin area, in the section for "PostMaster Mail Accounts". |
rebuild_ticket_index | Rebuilds the ticket index, which improves the speed of the QueueVie |
session | Removes old and no longer needed session IDs. |
unlock | Unlocks tickets in the system. |
到这里就已经全部安装完成,访问http://localhost/otrs/index.pl,来看看你装的OTRS吧,默认的用户名:root@localhost,密码:root。