美文网首页管理
Centos7下安装资产管理系统GLPI

Centos7下安装资产管理系统GLPI

作者: apple524 | 来源:发表于2020-09-04 15:46 被阅读0次

Centos7为最小安装,配置好相应的网络IP地址

一、关闭防火墙:

systemctl stop firewalld.service      #停止firewalld服务
systemctl disable firewalld.service    #设置开机默认不启动

#生产环境单独在防火墙上开启端口和策略
# firewall-cmd --permanent --zone=public --add-port=80/tcp
# firewall-cmd --reload

二、关闭selinux

getenforce    #查看状态
vi /etc/sysconfig/selinux    #开机不启动
     SELINUX=disabled

三、更新系统

 yum -y install epel-release
 yum update -y

四、安装Apache服务并启动

yum install -y httpd httpd-devel
service httpd start
systemctl enable httpd           #开机启动

五、安装PHP及其他依赖软件

1.配置epel yum源

rpm -Uvh http://mirror.centos.org/centos/7/extras/x86_64/Packages/epel-release-7-11.noarch.rpm
rpm -Uvh http://rpms.remirepo.net/enterprise/remi-release-7.rpm

2.安装php及依赖

yum -y install --enablerepo=remi --enablerepo=remi-php74 php php-opcache php-devel php-mbstring php-mcrypt php-mysqlnd php-pecl-xdebug php-pecl-xhprof php-imap php-gd php-ldap php-intl php-simplexml php-zip php-apcu php-xmlrpc php-pear-CAS php-zip
php -v                          #查看安装的php版本
image.png

3.安装其他依赖软件

yum -y install gcc gcc-c++ flex bison autoconf automake bzip2-devel zlib-devel ncurses-devel libjpeg-devel libpng-devel libtiff-devel freetype-devel pam-devel openssl-devel libxml2-devel gettext-devel pcre-devel

六、配置数据库

1.安装新版MariaDB

vim /etc/yum.repos.d/mariadb.repo

配置文件如下:

[mariadb]
name = MariaDB
baseurl = http://mirrors.aliyun.com/mariadb/yum/10.3/centos7-amd64/
gpgkey =  http://mirrors.aliyun.com/mariadb/yum/RPM-GPG-KEY-MariaDB
gpgcheck = 1
yum clean all  
yum makecache  
yum repolist
yum -y install MariaDB-server MariaDB-client   # yum安装MariaDB
systemctl start mariadb.service    #启动mariadb
systemctl enable mariadb.service   #设置开机启动
mysql_secure_installation   #创初始化数据库

2.创建初始数据库

 mysql -uroot -p
 password

mysql

mysql> use mysql;
mysql> CREATE USER 'glpi'@'%' IDENTIFIED BY 'glpi';   #用户名 密码
mysql> GRANT USAGE ON *.* TO 'glpi'@'%' IDENTIFIED BY 'glpi';
mysql> create database glpi;
mysql>grant select,insert,update,delete,create,drop on glpi.* to 'glpi'@'%';
mysql> quit

七、下载GLPI并赋权

进入https://glpi-project.org/downloads/ 网站,下载GLPI安装包
我下载的是 glpi-9.5.1.tgz
文件传到服务器 /var/www/html 目录下面

cd /var/www/html
tar zxvf glpi-9.5.1.tgz
chown -R apache.apache /var/www/html/
chmod 755 -R /var/www/html/glpi/config/
chmod 755 -R /var/www/html/glpi/files/

重启apache服务

service httpd restart

八进入系统安装

http://IP/glpi/

image.png image.png
image.png

数据库IP设置成本机,账户密码填入安装mysql时设置的


image.png
image.png
image.png

完成后就能登录GLPI系统了,用户名密码都是glpi

相关文章

网友评论

    本文标题:Centos7下安装资产管理系统GLPI

    本文链接:https://www.haomeiwen.com/subject/zzoasktx.html