Answer the question
In order to leave comments, you need to log in
Zabbix and site on the same server?
I ran into a problem:
I raised my site on Apache (httpd) on a server running CentOS 7. Now I’m trying to raise Zabbix on it, I configured everything and everything is in order in the Zabbix logs, but when installing via the web I saw the message: "Minimum required limit on execution time of PHP scripts is 300 (configuration option "max_execution_time")". I started poking around and realized that for some reason Zabbix was taking my site's php-config, which is also in /etc/httpd/conf.d. I remove this config from the directory and restart httpd - there are no errors, the settings are taken from the required file. I return - takes again the settings from the config for the site. What is the reason and how to fix it?
Here is the config for the site (/etc/httpd/conf.d/site1.conf):
<VirtualHost *:80>
ServerName site1.ru
ServerAlias www.site1.ru
DocumentRoot /web/site1.ru/www
<Directory /web/site1.ru/www>
Options FollowSymLinks
AllowOverride none
Require all granted
</Directory>
ErrorLog /web/site1.ru/logs/error.log
CustomLog /web/site1.ru/logs/access.log common
php_admin_value date.timezone 'Europe/Moscow'
php_admin_value max_execution_time 60
php_admin_value upload_max_filesize 30M
</VirtualHost>
Alias /zabbix /usr/share/zabbix
<Directory "/usr/share/zabbix">
Options FollowSymLinks
AllowOverride None
Require all granted
<IfModule mod_php5.c>
php_value memory_limit 256M
php_value post_max_size 16M
php_value upload_max_filesize 30M
php_value max_execution_time 300
php_value max_input_time 300
php_value always_populate_raw_post_data -1
php_value date.timezone Europe/Moscow
</IfModule>
</Directory>
<Directory "/usr/share/zabbix/conf">
Require all denied
</Directory>
<Directory "/usr/share/zabbix/app">
Require all denied
</Directory>
<Directory "/usr/share/zabbix/include">
Require all denied
</Directory>
<Directory "/usr/share/zabbix/local">
Require all denied
</Directory>
IncludeOptional conf.d/*.conf
, if that matters. Answer the question
In order to leave comments, you need to log in
Installing the zabbix-web package puts the zabbix.conf file in /etc/httpd/conf.d. This file is loaded when the httpd service is started, and overrides some Apache options for scripts run from /usr/share/zabbix/ (web interface), as recommended by Zabbix:
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 Europe/Riga
php_admin_value
moving it from site1.conf to a block <Directory /web/site1.ru/www>
, similar to the second config. Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question