• Zabbix3.2安装


    一、环境

    OS:          CentOS7.0.1406
    Zabbix版本:   Zabbix-3.2
    下载地址:      http://repo.zabbix.com/zabbix/3.2/rhel/7/x86_64/zabbix-release-3.2-1.el7.noarch.rpm
    MySQL版本:    5.6.37
    MySQL:        http://repo.mysql.com/mysql-community-release-el7-5.noarch.rpm

     二、安装

    1. [root@zabbix ~]# rpm -ivh zabbix-release-3.2-1.el7.noarch.rpm
    warning: zabbix-release-3.2-1.el7.noarch.rpm: Header V4 RSA/SHA512 Signature, key ID a14fe591: NOKEY
    Preparing...                          ################################# [100%]
    Updating / installing...
       1:zabbix-release-3.2-1.el7         ################################# [100%]
    
    2. [root@zabbix ~]#  yum install zabbix-server-mysql zabbix-web-mysql zabbix-agent
    
    3. 安装MySQL(Centos7默认数据库是mariadb)
    [root@zabbix ~]# wget http://repo.mysql.com/mysql-community-release-el7-5.noarch.rpm
    [root@zabbix ~]# rpm -ivh mysql-community-release-el7-5.noarch.rpm
    Preparing...                          ################################# [100%]
    Updating / installing...
       1:mysql-community-release-el7-5    ################################# [100%]
    [root@zabbix ~]# yum install mysql-community-server
    [root@zabbix ~]# systemctl enable mysqld
    [root@zabbix ~]# systemctl start mysqld
    4. 设置密码
    [root@zabbix ~]# mysqladmin -uroot password "newpasswd"
    
    5. 创建数据库
    mysql> create database zabbix character set utf8 collate utf8_bin;
    Query OK, 1 row affected (0.00 sec)
    
    mysql> grant all privileges on zabbix.* to zabbix@localhost identified by 'zabbix';
    Query OK, 0 rows affected (0.00 sec)
    
    6. 导入数据
    [root@zabbix ~]# cd /usr/share/doc/zabbix-server-mysql-3.2.7
    [root@zabbix zabbix-server-mysql-3.2.7]# zcat create.sql.gz | mysql -uroot -p zabbix
    * Zabbix是数据库名,不是密码
    
    7.配置zabbix-server
    [root@zabbix zabbix-server-mysql-3.2.7]# vim /etc/zabbix/zabbix_server.conf
    DBHost=localhost
    DBName=zabbix
    DBUser=zabbix
    DBPassword=zabbix
    [root@zabbix zabbix-server-mysql-3.2.7]# systemctl enable zabbix-server.service
    Created symlink from /etc/systemd/system/multi-user.target.wants/zabbix-server.service to /usr/lib/systemd/system/zabbix-server.service.
    [root@zabbix zabbix-server-mysql-3.2.7]# systemctl start zabbix-server.service
    
    8. 修改时区
      vim /etc/httpd/conf.d/zabbix.conf
    php_value date.timezone Asia/Shanghai
    
    9. 启动httpd
    [root@zabbix ~]# systemctl start httpd
    [root@zabbix ~]# systemctl enable httpd

     三、web界面配置

    1. 访问: http://ip/zabbix

     

    2. 登录

    默认用户名密码: Admin/zabbix

    3. 问题: 中文乱码

    解决方法:
    Win+R打开运行,输入fonts,回车进入Windows字体目录,找到微软雅黑-常规字体,复制出来将文件名修改为msyh.ttf,然后上传到/usr/share/zabbix/fonts
    上传到/usr/share/zabbix/fonts/,将graphfont.ttf备份
    mv msyh.ttf graphfont.ttf
    chmod 777 graphfont.ttf

    4. 刷新页面

  • 相关阅读:
    【leetcode】1442. Count Triplets That Can Form Two Arrays of Equal XOR
    【leetcode】1441. Build an Array With Stack Operations
    【leetcode】1437. Check If All 1's Are at Least Length K Places Away
    cxCheckCombobox
    修改现有字段默认值
    2018.01.02 exprottoexcel
    Statusbar OwnerDraw
    dxComponentPrinter记录
    单据暂存操作思路整理
    设置模式9(装饰者,责任链,桥接,访问者)
  • 原文地址:https://www.cnblogs.com/Z-style/p/7268809.html
Copyright © 2020-2023  润新知