1 OTRS的简介
– OTRS即英文“Open-source Ticket Request System”的简写
– OTRS帮助IT部门,服务台等相关部门跟踪和处理用户方请求(俗称工单系统)
– OTRS是全球范围内最成功和使用寿命最长的开源项目
注:笔者安装过程中发现该项目过度商业化,已经消弱开源的支持(文档支持不够详尽,感觉为利益有所保留)
2 服务端的安装
2.1 环境信息
Server:
IP Address = 10.168.0.70
OS = CentOS 7.4 x86_64
hostname = otrs.cmdschool.org
2.2 基本配置
2.2.1 配置主机名称
hostnamectl set-hostname otrs.cmdschool.org
2.2.2 配置SELinux
setenforce 0
sed -i 's/SELINUX=enforcing/SELINUX=disabled/g' /etc/selinux/config
2.2.3 配置yum源
yum install -y http://dl.fedoraproject.org/pub/epel/7/x86_64/Packages/e/epel-release-7-11.noarch.rpm
2.2.4 安装常用的工具
yum install -y vim wget
2.2.5 配置时区和NTP服务
时区配置
timedatectl set-timezone Asia/Shanghai
安装chrony时间同步工具
yum install -y chrony
启动ntp服务
systemctl start chronyd
systemctl enable chronyd
2.2.6 安装编译环境
yum install -y gcc gcc-c++ make expat-devel
2.2.7 防火墙配置
firewall-cmd --permanent --add-service http
firewall-cmd --reload
firewall-cmd --list-all
2.3 安装MariaDB数据库
2.3.1 安装MariaDB相关包
yum install -y mariadb-server mariadb mariadb-devel
2.3.2 修改配置文件
vim /etc/my.cnf
加入如下配置:
[mysqld]
max_allowed_packet = 64M
query_cache_size = 32M
innodb_log_file_size = 256M
2.3.3 启动并配置服务自启动
systemctl start mariadb
systemctl enable mariadb
2.3.4 初始化MariaDB服务
mysql_secure_installation
向导如下:
Set root password? [Y/n] y
New password: ******
Re-enter new password: ******
[…]
Remove anonymous users? [Y/n] y
[…]
Disallow root login remotely? [Y/n] y
[…]
Remove test database and access to it? [Y/n] y
[…]
Reload privilege tables now? [Y/n] y
2.4 安装OTRS
2.4.1 基础配置
2.4.1.1 下载安装模块
cd ~
wget http://ftp.otrs.org/pub/otrs/otrs-6.0.6.tar.gz
注:其他版本下载请参看以下链接,
http://ftp.otrs.org/pub/otrs/RPMS/rhel/7/
2.4.1.2 解压安装包
tar -xf otrs-6.0.6.tar.gz
2.4.1.3 部署安装包
mv otrs-6.0.6 /opt/otrs
2.4.1.4 安装依赖的软件包
yum install -y perl-core httpd mod_perl
2.4.1.5 检查依赖关系
perl /opt/otrs/bin/otrs.CheckModules.pl
留意以下提示信息:
o Apache::DBI......................ok (v1.12)
o Apache2::Reload..................ok (v0.13)
o Archive::Tar.....................ok (v1.92)
o Archive::Zip.....................Not installed! Use: 'yum install "perl(Archive::Zip)"' (required - Required for compressed file gen