OTRS 系统安装

otrs安装配置

一、otrs安装

1.安装perl mysql-server mysql-devel httpd gcc make perl cpan 关闭防火墙,selinux

yum install perl mysql-server mysql-devel httpd

2.设置mysql账户密码,创建otrs 用户,创建otrs数据库,并给otrs用户对otrs数据库的所有权限

(1)mysqladmin -u root -p password 123456

(2)create database otrs character set utf8;

(3)insert into mysql.user(Host,User,Password) values('localhost','otrs',password('123456'));

(4)grant all on *.* to 'otrs'@'%' identified by '123456' with grant option;(或使用图形化数据库管理工具)

3.设置mysql允许包大小

max_allowed_packet=256M

4重新启动mysql,设置开机启动

service mysqld restart

chkconfig mysqld on

5.下载otrs系统包,解压,修改文件名

mv otrs-x.x otrs

6.检查所需模块

perl /opt/otrs/bin/otrs.CheckModules.pl

7.安装所需要的模块

yum install 或者cpan

8.创建OTRS用户

useradd -d /opt/otrs/ -c 'OTRS user' otrs

9.激活配置文件

cd /opt/otrs/

cp /opt/otrs/Kernel/Config.pm.dist /opt/otrs/Kernel/Config.pm

cp /opt/otrs/Kernel/Config/GenericAgent.pm.dist /opt/otrs/Kernel/Config/GenericAgent.pm

10.检查重要文件

1.perl -cw /opt/otrs/bin/cgi-bin/index.pl

2.perl -cw /opt/otrs/bin/cgi-bin/customer.pl

3.perl -cw /opt/otrs/bin/otrs.PostMaster.pl

11配置apache

1.修改配置文件

(1)vim /etc/httpd/conf/httpd.conf

查找 Include conf.d/*.conf

在下面添加一句:Include /opt/otrs/scripts/apache2-httpd.include.conf

查找User 修改为otrs

2.重启,设置开机启动。

12.文件授权 /opt/otrs/bin/otrs.SetPermissions.pl --web-group=apache

完成后重启http mysql otrs(/opt/otrs/bin/Cron.sh)

13.初始化配置

(1)输入地址 http://服务器地址/otrs/installer.pl

(2)下一步,选择使用现有数据库,填写otrs数据库和数据库用户及密码,下一步。

(3)使用smtp代理发信,填写代理服务器的地址。

14.

(1)使用页面给出的用户名密码,即可登录 http://服务器地址/otrs/index.pl管理员页面。

(2)初始密码过于复杂,可以在/opt/otrs/otrs.SetPassword.pl root@localhost 123.bmk 修改密码

(3)登录 http://服务器地址/otrs/customer.pl 可以进入用户页面

15.激活守护进程

cd /opt/otrs/var/cron 下,

su otrs

for foo in *.dist; do cp $foo `basename $foo .dist`; done (复制所有.dist 文件去掉末尾的.dist 激活文件)

/opt/otrs/bin/Cron.sh start

/opt/otrs/bin/otrs.SetPermission.pl --web-group=apache

二、otrs配置

1.设置smtp发信,在系统管理界面,系统配置栏,搜索smtp ,进入配置 ,添加参数

SendmailModule::AuthUser  : [email protected]
SendmailModule::AuthPassword  : XXXXXX
SendmailModule::Host : smtp.exmail.qq.com

2.配置ldap ,在系统管理界面,系统配置栏,搜索ldap 进入配置

Customer::AuthModule : LDAP
Customer::AuthModule::LDAP::Host : 192.168.7.222
Customer::AuthModule::LDAP::BaseDN:dc=bmk,dc=local
Customer::AuthModule::LDAP::UID: sAMAccountName
Customer::AuthModule::LDAP::GroupDN: dc=bmk,dc=local
Customer::AuthModule::LDAP::SearchUserDN : [email protected] (必须这样写,否则认证不能通过)
Customer::AuthModule::LDAP::SearchUserPw: xxxxx(密码)

也可修改配置文件:

vim  /opt/otrs/Kernel/Config.pm

添加:$Self->{CustomerUser} = {

Name => 'LDAP Backend',         Module => 'Kernel::System::CustomerUser::LDAP',           Params => {               Host => '192.168.7.222',               BaseDN => 'dc=bmk,dc=local',              SSCOPE => 'sub',               UserDN => '[email protected]',               UserPw => '123.ljg',               SourceCharset => 'utf-8',               DestCharset => 'utf-8',           },           CustomerKey => 'sAMAccountName',           CustomerID => 'mail',          #SourceCharset => 'utf-8',           CustomerUserListFields => ['sAMAccountName', 'cn', 'mail'],           CustomerUserSearchFields => ['sAMAccountName', 'cn', 'mail'],           CustomerUserPostMasterSearchFields => ['mail'],           #CustomerUserSearchPrefix =>'*',           CustomerUserNameFields => ['sn', 'givenname'],CustomerUserSearchListLimit =>'250',           Map => [         [ 'UserFirstname', 'Firstname', 'sn', 1, 1, 'var' ],         [ 'UserLastname', 'Lastname', 'givenname', 1, 1, 'var' ],        [ 'UserLogin', 'Login', 'sAMAccountName', 1, 1, 'var' ],        [ 'UserEmail', 'Email', 'mail', 1, 1, 'var' ],          [ 'UserCustomerID', 'CustomerID', 'mail', 0, 1, 'var' ],

],      };

安装模块:

# cd /opt/otrs/bin

# wget ftp://ftp.otrs.org/pub/otrs/itsm/bundle4/ITSM-4.0.7.opm

#/opt/otrs/bin/otrs.PackageManager.pl -a install -p /opt/otrs/bin/ITSM-4.0.7.opm

#./otrs.RebuildConfig.pl

#./otrs.DeleteCache.pl

# ./otrs.CleanUp.pl

#./otrs.SetPermissions.pl --web-group=apache


你可能感兴趣的:(安装,OTRS)