一键安装LAMP,搭建 osTicket

LAMP 一键安装包 网址:https://lamp.sh/install.html
LAMP安装时间过长请不要用xshell安装容易断线,在虚拟机本机安装。

安装 wget、screen、unzip,创建 screen 会话
yum -y install wget screen git

git clone 并赋予脚本执行权限
git clone https://github.com/teddysun/lamp.git

cd lamp

chmod 755 *.sh 给权限

开始安装

screen -S lamp

./lamp.sh

安装选项
一键安装LAMP,搭建 osTicket
一键安装LAMP,搭建 osTicket
一键安装LAMP,搭建 osTicket
一键安装LAMP,搭建 osTicket
一键安装LAMP,搭建 osTicket
一键安装LAMP,搭建 osTicket
一键安装LAMP,搭建 osTicket
一键安装LAMP,搭建 osTicket
一键安装LAMP,搭建 osTicket
最后这里回车确认,有信息动了就等待安装,时间较长可以去睡一觉。

安装完毕后启动 httpd 服务
systemctl start httpd

查看是否启动 ,如有绿色表示启动成功
systemctl status httpd

查看firewall服务状态
systemctl status firewalld

关闭防火墙
service firewalld stop

网页测试输入你的ip:192.168.0.102
一键安装LAMP,搭建 osTicket
完成LAMP安装

添加配置 Mysql 用户,记住在mysql里面命令结束必须加上( ;)这个符号才能执行命令

安装模块
yum install php-mysql php-gd php-ldap php-odbc php-pear php-xml php-xmlrpc php-mbstring php-snmp php-mcrypt

osTicket 官网下载,解压到win10系统下
一键安装LAMP,搭建 osTicket
把以下文件导入centos系统 /data/www/default 目录里
scripts
upload
一键安装LAMP,搭建 osTicket
scripts,upload 给权限
chown apache -R /data/www/default/upload
chown apache -R /data/www/default/scripts

到以下目录cp拷贝文件以下命令
cd /data/www/default/upload
cp include/ost-sampleconfig.php include/ost-config.php

启动mysql
systemctl start mysqld.service

登入数据库需要更改mysql密码,以下提示错误信息
mysql -u root -p
一键安装LAMP,搭建 osTicket
编辑etc/my.cnf文件添加 skip-grant-tables 免密码登入mysql
一键安装LAMP,搭建 osTicket
systemctl restart mysqld 重启

再登入 mysql -u root -p 以下是更改Mysql密码,以下红色筐是成功信息

update mysql.user set password=password('123') where user='root' and host='localhost';
flush privileges;
exit;
一键安装LAMP,搭建 osTicket
再编辑etc/my.cnf文件删除或注释这条命令 skip-grant-tables

以下添加用户
create database osticketdb;
create user "osuser"@"localhost" identified by "password";
grant all on osticketdb.* to "osuser"@"localhost";
flush privileges;
exit;
一键安装LAMP,搭建 osTicket

配置 文件default.conf重命名为www.a.com.comf
cd /usr/local/apache/conf/vhost/default.conf
把原文件的内容删除,添加以下内容进去保存退出!
<VirtualHost *:80>
DocumentRoot "/data/www/default/"
ServerName www.a.com
ServerAlias www.a.com
ErrorLog "/var/log/httpd/yourdomain.com-error_log"
CustomLog "/var/log/httpd/yourdomain.com-access_log" combined

<Directory "/data/www/default/">
DirectoryIndex index.html index.php
Options FollowSymLinks
AllowOverride All
Require all granted
</Directory>
</VirtualHost>

systemctl restart httpd.service 重启服务

访问 :192.169.0.117/upload
一键安装LAMP,搭建 osTicket

下一步进行安装
一键安装LAMP,搭建 osTicket
文件没有权限不能进行安装

chown apache -R /data/www/default/upload

重启httpd服务
systemctl restart httpd.service

访问 :192.169.0.117/upload

一键安装LAMP,搭建 osTicket

管理原用户的账号密码自己设置记住!
查询Mysql数据库名
show databases;
一键安装LAMP,搭建 osTicket
一键安装LAMP,搭建 osTicket
已经安装完成准备进入工单系统
访问 :192.169.0.117/upload
一键安装LAMP,搭建 osTicket

一键安装LAMP,搭建 osTicket一键安装LAMP,搭建 osTicket
一键安装LAMP,搭建 osTicket
登入管理用户需要更改配置文件,不然没有东西(注意语法符号位置都要一模一样)

到以下路径找到配置文件添加内容
/data/www/default/upload/include

配置class.ostsession.php文件添加

$this->data->session_data = "";
一键安装LAMP,搭建 osTicket
保存退出,重启服务
systemctl restart httpd.service
一键安装LAMP,搭建 osTicket
完成!

转载于:https://blog.51cto.com/13938402/2347045

  • 0
    点赞
  • 1
    收藏
    觉得还不错? 一键收藏
  • 0
    评论
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值