Zabbix Documentation 4.0

2.23.04.0 (current)In development:4.2 (devel)Unsupported:1.82.02.43.23.4

User Tools

Site Tools


manual:installation:install_from_packages:rhel_centos

Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Both sides previous revision Previous revision
Next revision
Previous revision
manual:installation:install_from_packages:rhel_centos [2017/11/21 15:51]
dimir copy from 3.4
manual:installation:install_from_packages:rhel_centos [2018/12/10 11:38] (current)
martins-v better note regarding separate db for server and proxy; some rewording
Line 1: Line 1:
 ==== 1 Red Hat Enterprise Linux/​CentOS ==== ==== 1 Red Hat Enterprise Linux/​CentOS ====
  
-=== Overview ===+==== Overview ​====
  
 Official Zabbix packages are available for RHEL 7, CentOS 7 and Oracle Linux 7. In this documentation we will refer to all 3 using the term ''​RHEL''​. Official Zabbix packages are available for RHEL 7, CentOS 7 and Oracle Linux 7. In this documentation we will refer to all 3 using the term ''​RHEL''​.
  
-Some agent and proxy packages are available for [[http://​repo.zabbix.com/​zabbix/​4.0/​rhel/​6/​x86_64/​|RHEL 6]] and [[http://​repo.zabbix.com/​zabbix/​4.0/​rhel/​5/​x86_64|RHEL 5]] as well.+Some agent and proxy packages are available for [[https://​repo.zabbix.com/​zabbix/​4.0/​rhel/​6/​x86_64/​|RHEL 6]] and [[https://​repo.zabbix.com/​zabbix/​4.0/​rhel/​5/​x86_64|RHEL 5]] as well.
  
-=== Adding Zabbix repository ===+==== Adding Zabbix repository ​====
  
 Install the repository configuration package. This package contains yum (software package manager) configuration files. Install the repository configuration package. This package contains yum (software package manager) configuration files.
Line 13: Line 13:
 RHEL 7: RHEL 7:
  
-  # rpm -ivh http://​repo.zabbix.com/​zabbix/​4.0/​rhel/​7/​x86_64/​zabbix-release-4.0-1.el7.noarch.rpm+  # rpm -ivh https://​repo.zabbix.com/​zabbix/​4.0/​rhel/​7/​x86_64/​zabbix-release-4.0-1.el7.noarch.rpm
  
 RHEL 6: RHEL 6:
  
-  # rpm -ivh http://​repo.zabbix.com/​zabbix/​4.0/​rhel/​6/​x86_64/​zabbix-release-4.0-1.el6.noarch.rpm+  # rpm -ivh https://​repo.zabbix.com/​zabbix/​4.0/​rhel/​6/​x86_64/​zabbix-release-4.0-1.el6.noarch.rpm
  
 RHEL 5: RHEL 5:
  
-  # rpm -ivh http://​repo.zabbix.com/​zabbix/​4.0/​rhel/​5/​x86_64/​zabbix-release-4.0-1.noarch.rpm+  # rpm -ivh https://​repo.zabbix.com/​zabbix/​4.0/​rhel/​5/​x86_64/​zabbix-release-4.0-1.noarch.rpm
  
-=== Server/​proxy/​frontend installation ===+=== Frontend installation prerequisites === 
 + 
 +Zabbix frontend requires additional packages not available in basic installation. You need to enable repository of optional rpms in the system you will run Zabbix frontend on: 
 + 
 +RHEL 7: 
 + 
 +  # yum-config-manager --enable rhel-7-server-optional-rpms 
 + 
 +==== Server/​proxy/​frontend installation ​====
  
 To install Zabbix server (available for RHEL 7, [[manual/​installation/​install_from_packages/​rhel_centos#​zabbix_frontend_and_server_on_rhel_6|deprecated on RHEL 6]]) with MySQL support: To install Zabbix server (available for RHEL 7, [[manual/​installation/​install_from_packages/​rhel_centos#​zabbix_frontend_and_server_on_rhel_6|deprecated on RHEL 6]]) with MySQL support:
Line 39: Line 47:
 Substitute '​mysql'​ in the commands with '​pgsql'​ to use PostgreSQL, or with '​sqlite3'​ to use SQLite3 (proxy only). Substitute '​mysql'​ in the commands with '​pgsql'​ to use PostgreSQL, or with '​sqlite3'​ to use SQLite3 (proxy only).
  
-** Creating database ​**+=== Creating database ​===
  
 For Zabbix [[manual:​concepts:​server|server]] and [[manual:​concepts:​proxy|proxy]] daemons a database is required. It is not needed to run Zabbix [[manual:​concepts:​agent|agent]]. ​ For Zabbix [[manual:​concepts:​server|server]] and [[manual:​concepts:​proxy|proxy]] daemons a database is required. It is not needed to run Zabbix [[manual:​concepts:​agent|agent]]. ​
  
-<note warning>If Zabbix server and proxy are installed on the same host, their databases must be created with different names!</​note>​+<note warning>Separate databases are needed for Zabbix server and Zabbix ​proxy; they cannot use the same database. Therefore, if they are installed on the same host, their databases must be created with different names!</​note>​
  
-Create the database using the provided [[:manual:​appendix:​install:​db_scripts|database creation scripts]] for MySQL/PostgreSQL.+Create the database using the provided ​instructions for [[manual:​appendix:​install:​db_scripts#mysql|MySQL]] or [[manual:​appendix:​install:​db_scripts#​postgresql|PostgreSQL]]. 
 + 
 +=== Importing data ===
  
 Now import initial schema and data for the server with MySQL: Now import initial schema and data for the server with MySQL:
Line 66: Line 76:
   # zcat /​usr/​share/​doc/​zabbix-proxy-sqlite3*/​schema.sql.gz | sqlite3 zabbix.db   # zcat /​usr/​share/​doc/​zabbix-proxy-sqlite3*/​schema.sql.gz | sqlite3 zabbix.db
  
-** Configure database for Zabbix server/​proxy ​**+=== Configure database for Zabbix server/​proxy ​===
  
-Edit zabbix_server.conf ​or zabbix_proxy.conf to use the created database. For example:+Edit zabbix_server.conf ​(and zabbix_proxy.confto use their respective databases. For example:
  
   # vi /​etc/​zabbix/​zabbix_server.conf   # vi /​etc/​zabbix/​zabbix_server.conf
Line 80: Line 90:
 Use ''​DBHost=''​ with PostgreSQL. You might want to keep the default setting ''​DBHost=localhost''​ (or an IP address), but this would make PostgreSQL use a network socket for connecting to Zabbix. See **SELinux configuration** below for instructions. Use ''​DBHost=''​ with PostgreSQL. You might want to keep the default setting ''​DBHost=localhost''​ (or an IP address), but this would make PostgreSQL use a network socket for connecting to Zabbix. See **SELinux configuration** below for instructions.
  
-** Starting Zabbix server process ​**+=== Starting Zabbix server process ​===
  
 It's time to start Zabbix server process: It's time to start Zabbix server process:
Line 96: Line 106:
 Substitute '​zabbix-server'​ with '​zabbix-proxy'​ if you are installing Zabbix proxy. Substitute '​zabbix-server'​ with '​zabbix-proxy'​ if you are installing Zabbix proxy.
  
-** Zabbix frontend configuration ​**+=== Zabbix frontend configuration ​===
  
 For RHEL 7 and later the Apache configuration file for Zabbix frontend is located in /​etc/​httpd/​conf.d/​zabbix.conf. For RHEL 7 and later the Apache configuration file for Zabbix frontend is located in /​etc/​httpd/​conf.d/​zabbix.conf.
Line 109: Line 119:
   php_value upload_max_filesize 2M   php_value upload_max_filesize 2M
   php_value max_input_time 300   php_value max_input_time 300
 +  php_value max_input_vars 10000
   php_value always_populate_raw_post_data -1   php_value always_populate_raw_post_data -1
   # php_value date.timezone Europe/Riga   # php_value date.timezone Europe/Riga
 +
 +Now you are ready to proceed with [[manual/​installation/​install#​installing_frontend|frontend installation steps]] which will allow you to access your newly installed Zabbix.
 +
 +Note that a Zabbix proxy does not have a frontend; it communicates with Zabbix server only.
 +
 +<​note>​Zabbix official repository provides fping, iksemel, libssh2 packages as well. These packages are located in the //​[[https://​repo.zabbix.com/​non-supported/​|non-supported]]//​ directory.</​note>​
  
 === SELinux configuration === === SELinux configuration ===
Line 128: Line 145:
  
   # service httpd restart   # service httpd restart
- 
-=== Frontend configuration === 
- 
-Now you are ready to proceed with [[manual/​installation/​install#​installing_frontend|frontend installation steps]] which will allow you to access your newly installed Zabbix. 
- 
-<​note>​Zabbix official repository provides fping, iksemel, libssh2 packages as well. These packages are located in the //​[[http://​repo.zabbix.com/​non-supported/​|non-supported]]//​ directory.</​note>​ 
- 
-=== Agent installation === 
- 
-To install the agent, run 
- 
-  # yum install zabbix-agent 
- 
-To start the agent, run: 
- 
-  # service zabbix-agent start 
  
 === Zabbix frontend and server on RHEL 6 === === Zabbix frontend and server on RHEL 6 ===
Line 167: Line 168:
   $ rpm -ql zabbix-web | grep example.conf   $ rpm -ql zabbix-web | grep example.conf
  
 +==== Agent installation ====
 +
 +To install the agent, run
 +
 +  # yum install zabbix-agent
 +
 +To start the agent, run:
 +
 +  # service zabbix-agent start
 +
 +==== Java gateway installation ====
 +
 +It is required to install [[:​manual/​concepts/​java|Java gateway]] only if you want to monitor JMX applications. Java gateway is lightweight and does not require a database.
 +
 +Once the required [[#​adding_zabbix_repository|repository]] is added, you can install Zabbix Java gateway by running:
 +
 +  # yum install zabbix-java-gateway
 +
 +Proceed to [[:​manual/​concepts/​java/​from_rhel_centos|setup]] for more details on configuring and running Java gateway.