Tutorial diagram for installing zabbix2.4 under centos6.5

The fixed IP address of the centos-DVD1 version system is 192.168.159.128, and the centos-mininal version system address is 192.168.1.* or 192.168.2.* network segment

zabbix2.4 installation (centos6.5)

Zabbix has its own yum source, LNMP can go to https://lnmp.org/ to download and install it yourself

The first step is to install the official zabbix source of zabbix, the address is as follows:

rpm -ivh http://repo.zabbix.com/zabbix/2.4/rhel/6/x86_64/zabbix-release-2.4-1.el6.noarch.rpm

The second step uses the yum installation method to automatically install zabbix server and agent related RPM packages

yum install -y mysql mysql-server zabbix-server-mysql zabbix-web-mysql zabbix-agent

zabbix-get: This command is mainly used to obtain monitoring data. After the installation is successful, you need to create a zabbix database and user in mysql.

Failed to enter the database, check that the mysqld service is not started, just start it!

Start the mysql database service: /etc/init.d/mysqld start

Enter the database: mysql -uroot

Format: grant authority on database name. table name to user@ login host identified by "user password";

GRANT ALL PRIVILEGES ON *.* TO zabbixuser@"%" IDENTIFIED BY "xxx";
FLUSH PRIVILEGES;

Create database and user:

mysql> createdatabase zabbix character set utf8 collate utf8_bin;
mysql> grant all privileges on zabbix.* to zabbix@localhostidentified by 'zabbix';
flush privileges;
show databases;

mysql> quit; or \q

Zabbix monitoring system data is stored in the database, and some tables need to be created.

View the table creation statement and import;

[ root@localhost~]# cd /usr/share/doc/zabbix-server-mysql-2.4.8/create
[ root@localhost create]#ll

Import the database:

[ root@localhost create]# mysql -uroot zabbix< schema.sql
[ root@localhostcreate]# mysql -uroot zabbix < images.sql
[ root@localhostcreate]# mysql -uroot zabbix < data.sql

Modify the zabbix server configuration file: (the # number should be removed if the # number is removed)

[ root@localhost ~]#vi /etc/zabbix/zabbix_server.conf
DBHost=localhost
DBName=zabbix
DBUser=zabbix
DBPassword=zabbix
vim installation
# yum search vim //View vim related software information
# yum install -y vim*//Install vim online

Modify the time zone;

[ root@localhost~]# vim /etc/php.ini//In php.Add the following content at the end of the ini configuration file [shift+g jump to the end of the file]
php_valuemax_execution_time 300
php_valuememory_limit 128M
php_valuepost_max_size 16M
php_valueupload_max_filesize 2M
php_valuemax_input_time 300

Remove the semicolon in front of ";date.timezone =", then write in the top box, and give the equal sign: Asia/Shanghai

After the modification is completed, it will take effect after restarting the system!

View the current time:

[ root@localhost~]# date

When viewing the current time, the time is not synchronized and needs to be synchronized

Install time synchronization command

[ root@localhost~]#yum install ntpdate

Perform synchronization of US time

[ root@localhost~]# ntpdate us.pool.ntp.org

Modify time zone: (ln sf abb points to a) Synchronize time

[ root@localhost~]# ln -sf /usr/share/zoneinfo/Asia/Shanghai /usr/localtime
[ root@localhost~]#date

Start the necessary services (restart): (start at boot, if you do not start the system, the service will not start, you can start the service manually)

Manually start the necessary services (without restarting)

When the firewall is enabled, chkconfig httpd on starts the httpd service, the zabbix configuration page cannot be opened

Apache started, but unable to open zabbix through the browser, the solution, turn off the firewall, turn off SELinux

Turn off selinux: sed -i "s/SELINUX=enforcing/SELINUX=disabled/g"/etc/selinux/config

Confirm whether the modification is successful: #grepSELINUX /etc/selinux/config

Stop the firewall: /etc/init.d/iptables stop

I accidentally discovered a phenomenon. When I close iptables and stop the iptables service, there will always be some strange things happening. When I start the system again and check the iptables status, iptables is automatically turned on again, so helpless! After researching that libvirt (the C library of virtualization tools) will drive the startup of iptables when booting, the way to permanently close iptables is through the chkconfig tool, we only need chkconfig iptables off.

[ System environment]

CentOS release 6.7 (Final)

Close iptables

Start httpd: chkconfig httpd on

/etc/init.d/iptables stop# Close iptables

chkconfig iptables off #Permanently close iptables

chkconfig --list iptables # check iptables

chkconfig --list httpd //View httpd startup

iptables -L or /etc/init.d/iptables status #View the running status of iptables

cat /etc/redhat-release //View the system version

Modify time zone:

Modify vim /etc/php.ini; date.timezone =Asia/Shanghai and remove the semicolon in front. You can also add it when you modify the time zone before

/etc/init.d/httpd restart //After the modification is completed, restart

Restart httpd will report an error, edit the httpd.conf file, vi /etc/httpd/conf/httpd.conf, and cancel ServerName www.example.com:80前#!

After restarting the system, another error was reported that the database was not started because the database was not started. Perform boot-up, no error will be reported next time you boot

[ root@localhost ~]# chkconfig mysqld on

After all the installation is complete, you need to perform all booting!

to sum up

The above is the tutorial diagram for installing zabbix2.4 under centos6.5 introduced by the editor. I hope it will be helpful to you. If you have any questions, please leave me a message, and the editor will reply to you in time. Thank you very much for your support to the ZaLou.Cn website!

Recommended Posts

Tutorial diagram for installing zabbix2.4 under centos6.5
Graphical tutorial for installing JDK1.8 under CentOS7.4
Tutorial for deploying nginx+uwsgi in django project under Centos8
Install Mesos tutorial under CentOS7
Tutorial diagram of installing CentOS 8 (1905) system on VMware virtual machine
Centos8 installation diagram (super detailed tutorial)
Detailed tutorial on installing python3.7 for ubuntu18
Zabbix installation and deployment and localization under CentOS
Detailed tutorial for installing CUDA9.0 on Ubuntu 16.04
CentOS7 installation zabbix 4.0 tutorial (graphics and text)
Jenkins installation and deployment tutorial under CentOS 7
The fourth installment of Zabbix under CentOs7
Detailed tutorial for installing phpMyAdmin on Ubuntu 18.04
Complete deployment record for LDAP under Centos7.2
Detailed tutorial on installing MySQL 8 in CentOS 7
Construction of Zabbix monitoring platform under CentOS7
Graphical tutorial for installing Pycharm 2020.1 in Ubuntu 20.04
Install MySQL 5.7 under CentOS 7 for middle class children!
CentOS 7.4 install Zabbix 3.4
CentOS8 detailed tutorial for configuring local yum source
Errors and solutions for installing remix-ide on CentOS
CentOS 7.3 install Zabbix3
Notes on installing pptp server under CentOS 7 ok
Build LEMP (Linux+Nginx+MySQL+PHP) environment under CentOS 8.1 (detailed tutorial)
centos 6.5 install zabbix 4.4
Installing CentOS 6 and SSH configuration under Windows 8 Hyper-V
Detailed tutorial of installing nginx on centos8 (graphic)
The tutorial for upgrading from Centos7 to Centos8 (detailed graphic)
Build a basic environment for Java development under Centos7
Detailed tutorial on installing JDK8 on Linux system (CentOS7 installation)
CentOS7.3 64 bit, build Zabbix3.4
Deploy GitBook under CentOS7
CentOS 8 install ZABBIX4.4 guide
Compile Hadoop-2.7.6 under CentOS7.4
Zabbix 2.2.20 installation details (Centos6.9)
Centos install MYSQL8.X tutorial
Install mysql5.7 under CentOS7
Centos install elasticsearch tutorial
Install ActiveMQ under Centos7
Install PostgreSQL12 under CentOS7
Explore Zabbix 5.0 LTS - CentOS 8 (1)
Install CentOS under VMware
Centos7 install kubernetes tutorial
Centos7 install Mysql8 tutorial
Deploy JDK+Tomcat8 under CentOS
Install mysql under Centos 7
Configure lamp under centos6.8
Install Jenkins under Centos 7
Redis3 installation under Centos7
Install MariaDB under MariaDB Centos7
Install mysql5.1 under CentOS6.5
Linux CentOS 7 installation tutorial
Centos 7 install Zabbix 3.4 original
Detailed explanation of Spark installation and configuration tutorial under centOS7
Detailed steps for installing Django under Python 3.6 in Ubuntu 16.04 environment
Method steps for installing and configuring SSH service under Ubuntu 18.04