This shows you the differences between two versions of the page.
Both sides previous revision Previous revision Next revision | Previous revision | ||
manual:installation:install_from_packages:debian_ubuntu [2017/11/28 07:45] natalja.cernohajeva Edited Zabbix frontend installation command |
manual:installation:install_from_packages:debian_ubuntu [2018/09/11 08:19] (current) dimir [Frontend configuration] added php value max_input_vars |
||
---|---|---|---|
Line 8: | Line 8: | ||
* Debian 8 (Jessie) | * Debian 8 (Jessie) | ||
* Debian 7 (Wheezy) | * Debian 7 (Wheezy) | ||
+ | * Ubuntu 18.04 (Bionic Beaver) LTS | ||
* Ubuntu 16.04 (Xenial Xerus) LTS | * Ubuntu 16.04 (Xenial Xerus) LTS | ||
* Ubuntu 14.04 (Trusty Tahr) LTS | * Ubuntu 14.04 (Trusty Tahr) LTS | ||
Line 15: | Line 16: | ||
Install the repository configuration package. This package contains apt (software package manager) configuration files. | Install the repository configuration package. This package contains apt (software package manager) configuration files. | ||
- | For Debian **9**, run: | + | For **Debian 9**, run the following commands: |
- | # wget http://repo.zabbix.com/zabbix/3.4/debian/pool/main/z/zabbix-release/zabbix-release_3.4-1+stretch_all.deb | + | **Note!** For Debian 8, substitute 'stretch' with 'jessie' in the commands. For Debian 7, substitute 'stretch' with 'wheezy' in the commands. |
- | # dpkg -i zabbix-release_3.4-1+stretch_all.deb | + | |
- | # apt-get update | + | |
- | For Debian 8, substitute 'stretch' with 'jessie'. For Debian 7, substitute 'stretch' with 'wheezy' in the commands. | + | # wget https://repo.zabbix.com/zabbix/3.4/debian/pool/main/z/zabbix-release/zabbix-release_3.4-1+stretch_all.deb |
+ | # dpkg -i zabbix-release_3.4-1+stretch_all.deb | ||
+ | # apt update | ||
- | For Ubuntu **16.04**, run: | + | For **Ubuntu 18.04 (bionic)**, run the following commands: |
- | # wget http://repo.zabbix.com/zabbix/3.4/ubuntu/pool/main/z/zabbix-release/zabbix-release_3.4-1+xenial_all.deb | + | # wget https://repo.zabbix.com/zabbix/3.4/ubuntu/pool/main/z/zabbix-release/zabbix-release_3.4-1+bionic_all.deb |
- | # dpkg -i zabbix-release_3.4-1+xenial_all.deb | + | # dpkg -i zabbix-release_3.4-1+bionic_all.deb |
- | # apt-get update | + | # apt update |
- | For Ubuntu 14.04, substitute 'xenial' with 'trusty' in the commands. | + | * For Ubuntu 16.04, substitute 'bionic' with 'xenial' in the commands. |
+ | * For Ubuntu 14.04, substitute 'bionic' with 'trusty' in the commands. | ||
=== Server/proxy/frontend installation === | === Server/proxy/frontend installation === | ||
Line 35: | Line 37: | ||
To install Zabbix server with MySQL support: | To install Zabbix server with MySQL support: | ||
- | # apt-get install zabbix-server-mysql | + | # apt install zabbix-server-mysql |
To install Zabbix proxy with MySQL support: | To install Zabbix proxy with MySQL support: | ||
- | # apt-get install zabbix-proxy-mysql | + | # apt install zabbix-proxy-mysql |
To install Zabbix frontend: | To install Zabbix frontend: | ||
- | # apt-get install zabbix-frontend-php | + | # apt install zabbix-frontend-php |
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]]. | ||
Line 53: | Line 55: | ||
<note warning>If Zabbix server and proxy are installed on the same host, their databases must be created with different names!</note> | <note warning>If Zabbix server and proxy 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 74: | Line 78: | ||
# 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 or zabbix_proxy.conf to use the created database. For example: | ||
Line 88: | Line 92: | ||
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. Refer to the [[:manual/installation/install_from_packages/rhel_centos#selinux_configuration|respective section]] for RHEL/CentOS 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. Refer to the [[:manual/installation/install_from_packages/rhel_centos#selinux_configuration|respective section]] for RHEL/CentOS for instructions. | ||
- | ** Starting Zabbix server process ** | + | === Starting Zabbix server process === |
It's time to start Zabbix server process and make it start at system boot: | It's time to start Zabbix server process and make it start at system boot: | ||
Line 97: | Line 101: | ||
Substitute 'zabbix-server' with 'zabbix-proxy' to start Zabbix proxy process. | Substitute 'zabbix-server' with 'zabbix-proxy' to start Zabbix proxy process. | ||
- | ** PHP configuration for Zabbix frontend ** | + | === SELinux configuration === |
+ | |||
+ | Refer to the [[:manual/installation/install_from_packages/rhel_centos#selinux_configuration|respective section]] for RHEL/CentOS. | ||
+ | |||
+ | As frontend and SELinux configuration is done, you need to restart Apache web server: | ||
+ | |||
+ | # service apache2 restart | ||
+ | |||
+ | === Frontend configuration === | ||
Apache configuration file for Zabbix frontend is located in /etc/apache2/conf-enabled/zabbix.conf. Some PHP settings are already configured. But it's necessary to uncomment the "date.timezone" setting and [[http://php.net/manual/en/timezones.php|set the right timezone]] for you. | Apache configuration file for Zabbix frontend is located in /etc/apache2/conf-enabled/zabbix.conf. Some PHP settings are already configured. But it's necessary to uncomment the "date.timezone" setting and [[http://php.net/manual/en/timezones.php|set the right timezone]] for you. | ||
Line 106: | Line 118: | ||
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 | ||
- | |||
- | === SELinux configuration === | ||
- | |||
- | Refer to the [[:manual/installation/install_from_packages/rhel_centos#selinux_configuration|respective section]] for RHEL/CentOS. | ||
- | |||
- | As frontend and SELinux configuration is done, you need to restart Apache web server: | ||
- | |||
- | # service apache2 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. | 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. | ||
Line 125: | Line 128: | ||
To install the agent, run | To install the agent, run | ||
- | # apt-get install zabbix-agent | + | # apt install zabbix-agent |
To start the agent, run: | To start the agent, run: |