1 打开yum安装rpm包,自动存放下载的rpm包

下次安装时,如果没有网可以自己制作yum源

打开文件

[root@localhost etc]# vim /etc/yum.conf

keepcache=0  改为keepcache=1

rpm包存放的路径:这个路径可以自己修改成自己存放的路径

cachedir=/var/cache/yum/ 

2 .关闭selinux和firewall

2.1检测selinux是否关闭

[root@localhost etc]# getenforce
Enforcing                        #Enforcing 为打开状态

2.1.1临时关闭
[root@localhost ~]# setenforce 0  #设置SELinux 成为enforcing模式

2.1.2永久关闭

[root@localhost ~]# vi /etc/selinux/config:   
将SELINUX=enforcing改为SELINUX=disabled 
设置后需要重启才能生效

2.2查看默认防火墙状态

[root@localhost ~]# firewall-cmd --state 
not running           #关闭后显示not running,开启后显示running

1.2.1停止firewall

[root@localhost ~]# systemctl stop firewalld.service

1.2.2禁止firewall开机启动
[root@localhost ~]# systemctl disable firewalld.service

3.Zabbix3.4程序安装

3.1配置zabbix的yum源

[root@localhost ~]# rpm -ivh http://repo.zabbix.com/zabbix/3.4/rhel/7/x86_64/zabbix-release-3.4-2.el7.noarch.rpm

3.2安装zabbix程序包,安装mysql、zabbxi-agent

[root@localhost ~]# yum install -y zabbix-server-mysql zabbix-web-mysql zabbix-agent

3.3启动mysql并设置开机启动,创建数据库实例,授权

[root@localhost ~]# mysql -uroot -p                            #登入数据库,密码123
MariaDB [(none)]> create database zabbix character set utf8 collate utf8_bin;   #创建数据库实例
Query OK, 1 row affected (0.00 sec)
MariaDB [(none)]> grant all privileges on zabbix.* to zabbix@'%' identified by 'zabbix';   #授权所有主机访问数据库实例zabbix,用户名/密码:zabbix/zabbix

Query OK, 0 rows affected (0.00 sec)
MariaDB [(none)]> grant all privileges on zabbix.* to zabbix@localhost identified by 'zabbix';   #授权localhost主机名访问数据库实例zabbix,用户名/密码:zabbix/zabbix

Query OK, 0 rows affected (0.00 sec)
MariaDB [(none)]> grant all privileges on zabbix.* to zabbix@localhost.localdomain identified by 'zabbix';  #授权localhost.localdomain主机访问数据库实例zabbix,用户名/密码:zabbix/zabbix

Query OK, 0 rows affected (0.00 sec)

导入初始模式和数据

[root@localhost ~]#cd /usr/share/doc/zabbix-server-mysql-3.4.15/              #进入create.sql.gz所在目录

[root@localhost zabbix-server-mysql-3.4.4]# zcat create.sql.gz |mysql -uroot   -p123 zabbix    #导入出事模式

进入mysql的zabbix库中,会有140张表,说明数据导入成功

3.4启动zabbix-server服务

3.4.1配置zabbix-server的配置文件zabbix_server.conf

[root@localhost zabbix-server-mysql-3.4.4]# vi /etc/zabbix/zabbix_server.conf
DBHost=localhost          # 数据主机名
DBName=zabbix            # 数据库实例
DBUser=zabbix              # 用户名
DBPassword=zabbix      # 密码

3.4.2启动zabbix-server服务

[root@localhost zabbix-server-mysql-3.4.4]# systemctl start zabbix-server           #启动zabbix-server服务
[root@localhost zabbix-server-mysql-3.4.4]# systemctl enable zabbix-server       #设置zabbix-server服务开机自启动

3.5编辑Apache的配置文件,消注释设置正确的时区

[root@localhost zabbix-server-mysql-3.4.4]# vi /etc/httpd/conf.d/zabbix.conf
php_value max_execution_time 300
php_value memory_limit 128M
php_value post_max_size 16M
php_value upload_max_filesize 2M
php_value max_input_time 300
php_value always_populate_raw_post_data -1
php_value date.timezone Asia/Shanghai
启动httpd服务 ,设置开机启动httpd服务

[root@localhost ~]# systemctl start httpd        #启动httpd服务 
[root@localhost ~]# systemctl enable httpd    #设置开机启动httpd服务

3.启动zabbix-agent并设置开机自启动
[root@localhost ~]# systemctl start zabbix-agent          # 启动zabbix-agent服务
[root@localhost ~]# systemctl enable zabbix-agent       # 设置zabbix-agent服务开机自启动

4.Zabbix Web网页安装

4.1.在浏览器输入地址http://服务器ip/zabbix/setup.php,出现欢迎界面,点击下一步;

centos7 安装zabbix3.4的更多相关文章

  1. centos7安装zabbix3.0超详细步骤解析

    centos7安装zabbix3.0超详细步骤解析 很详细,感谢作者 以下是我操作的history 622 java -version 623 javac -version 624 grep SELI ...

  2. 转:Centos7安装zabbix3.4超详细步骤解析

    安装前准备: 1.1 安装依赖包: yum -y install wget net-snmp-devel OpenIPMI-devel httpd openssl-devel java lrzsz f ...

  3. centos7 安装zabbix3.0 安装zabbix4.0 yum安装zabbix 国内源安装zabbix 阿里云服务器安装zabbix

    首先,此篇文章是有原因的. 刚开始也和大家一样来学习安装zabbix 奈何网上的教程和现实出现不一样的情况 在安装zabbix过程中,因为zabbix下载源是在国外,下载途中会出现终止下载的情况 tr ...

  4. centos7安装zabbix3.2.4

    系统:CentOS Linux release 7.2.1511 (Core) zabbix:3.2.4 一.yum -y install httpd mysql mysql-server mysql ...

  5. Centos7 安装 zabbix3.2

    简介: Zabbix的一个很优秀的分布式监控服务器, 它有两部分组成: 1. “zabbix-server”用来收集并且在web端展示数据 2. “zabbix-agent”用来采集数据,发送给ser ...

  6. centos7安装zabbix3.4

    一.系统环境 关闭防火墙及selinux systemctl stop firewalld.service systemctl disable firewalld.service sed -i 's/ ...

  7. centos7安装zabbix3.5

    安装centos7 自带MariaDB数据库(或者安装mysql) yum -y install mariadb-server mariadb-devel systemctlstartmariadb. ...

  8. centos7 安装Zabbix3.0

    1 安装Mariadb数据库(代替MySQL)yum -y install mariadb*systemctl start mariadbsystemctl enable mariadb #自启动 2 ...

  9. Centos7安装zabbix3.4.0以及配置和使用

    一.安装ZABBIX 1.环境和软件版本 注:此次是采用的rpm包方式安装,所以服务器必须要能连接互联网通过yum方式解决依赖关系 ①系统: [root@zabbix ~]# cat /etc/red ...

随机推荐

  1. CSS filter 模拟黑洞照片效果

    今天被世界上第一张黑洞照片刷屏. 一整天,哪里都是这张照片.看的多了.我就想用css做一个吧. 建议在chrome上查看. 访问地址:http://suohb.com/work/blankHole.h ...

  2. Centos7: 设置UTC时区

    timedatectl set-timezone UTC

  3. sql 分组取每组的前n条或每组的n%(百分之n)的数据

    sql 分组取每组的前n条或每组的n%(百分之n)的数据 sql keyword: SELECT * ,ROW_NUMBER() OVER(partition by b.UserID order by ...

  4. GDIPlus绘制桌面歌词

    功能介绍 採用GDIPlus绘制桌面歌词,相似酷狗.QQ音乐等软件.歌词支持纯色.两色渐变.三色渐变:支持高亮歌词. 实现方法 窗体部分:桌面歌词是个独立的背景透明窗体.能够移动位置,能够鼠标穿透.透 ...

  5. Pell Sequence

    /* * PellSequence.cpp * * Created on: 2013-09-08 16:46 * Author: lg * Description: a1 = 1, a2 = 2, . ...

  6. mysql20170407代码实现

    今天用了一会儿sqlyog,感觉还是会让人懒惰,所以选择了ms-dos环境,感觉不错,原生态,敲着很爽; | test01 | | tree | | world | +---------------- ...

  7. [Python] partial改变方法默认參数

    Python 标准库中 functools库中有非常多对方法非常有有操作的封装,partial Objects就是当中之中的一个,他是对方法參数默认值的改动. 以下就看下简单的应用測试. #!/usr ...

  8. poj3254Corn Fields

    Corn Fields Time Limit: 2000MS   Memory Limit: 65536K Total Submissions: 13765   Accepted: 7232 Desc ...

  9. E20170626-gg

    occupy   vt. 占领; 使用,住在…; 使从事,使忙碌; 任职; stack   n. 垛,干草堆; (一排) 烟囱; 层积; 整个的藏书架排列;

  10. C. Searching for Graph(cf)

    C. Searching for Graph time limit per test 1 second memory limit per test 256 megabytes input standa ...