美文网首页计算机技术
【Linux】【CMDB】【GLPI】安装与配置

【Linux】【CMDB】【GLPI】安装与配置

作者: 炼狱腾蛇Eric | 来源:发表于2018-12-29 16:31 被阅读0次

    1. 简介

    • GLPI只是一个Web界面,用来展示数据,他的数据来源可以是Ocsinventory/fustioninventory或者

    2. 架构图

    image.png

    3. 链接

    官方网站:https://glpi-project.org/
    下载地址:https://github.com/glpi-project/glpi/releases
    git:https://github.com/glpi-project
    安装文档:https://glpi-install.readthedocs.io/en/latest/index.html#
    插件地址:https://plugins.glpi-project.org/#/

    4. 环境

    • centos 7.6
    • apache 2.4
    • glpi 9.3
    • php 7.3
    • mariadb 10.3(官方推荐MySQL 5.6或者MaridDB 10以上)

    5. 安装与配置

    • epel和php7的yum源
    rpm -ivh https://dl.fedoraproject.org/pub/epel/epel-release-latest-7.noarch.rpm
    rpm -ivh http://rpms.remirepo.net/enterprise/remi-release-7.rpm
    
    • mariadb10.3的yum源,/etc/yum.repos.d/mariadb.repo
    # MariaDB 10.3 CentOS repository list - created 2018-05-26 07:55 UTC
    # http://downloads.mariadb.org/mariadb/repositories/
    [mariadb]
    name = MariaDB
    baseurl = http://yum.mariadb.org/10.3/centos7-amd64
    gpgkey=https://yum.mariadb.org/RPM-GPG-KEY-MariaDB
    gpgcheck=1
    

    建一个空的库

    MariaDB [(none)]> create database glpi;
    Query OK, 1 row affected (0.000 sec)
    
    MariaDB [(none)]> GRANT ALL PRIVILEGES ON glpi.* to glpi@localhost IDENTIFIED BY 'glpi';
    Query OK, 0 rows affected (0.000 sec)
    
    MariaDB [(none)]> GRANT ALL PRIVILEGES ON glpi.* to glpi@'%' IDENTIFIED BY 'glpi';
    Query OK, 0 rows affected (0.000 sec)
    
    MariaDB [(none)]> flush privileges;
    Query OK, 0 rows affected (0.000 sec)
    
    • 安装httpd
    yum -y install httpd httpd-devel
    
    • 安装PHP及其依赖,php73-php.x86_64是用来提供httpd支持的包
    yum -y install mariadb php73 php73-php.x86_64 php73-php-ldap php73-php-imap \
    php73-php-opcache php73-php-pecl-apcu php73-php-xmlrpc php73-php-mysqlnd \
    php73-php-mbstring php73-php-gd php73-php-xml php-pear-CAS
    
    • 下载二进制包并解压
    wget https://github.com/glpi-project/glpi/releases/download/9.3.3/glpi-9.3.3.tgz -O /tmp/glpi-9.3.3.tgz
    tar xf /tmp/glpi-9.3.3.tgz -C /var/www/html/glpi
    
    • 改权限
    chown -R apache:apache /var/www/html/
    chmod 755 -R /var/www/html/glpi/config/
    chmod 755 -R /var/www/html/glpi/files/
    
    • 重启httpd
    systemctl restart httpd && systemctl enable httpd
    
    • 访问地址 http://你的IP/glpi,会跳进安装界面

    6. 安装插件

    7. 常用的功能

    相关文章

      网友评论

        本文标题:【Linux】【CMDB】【GLPI】安装与配置

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