Uploaded image for project: 'ZABBIX BUGS AND ISSUES'
  1. ZABBIX BUGS AND ISSUES
  2. ZBX-9897

Frontend package config assumes usage of mod_php5

    Details

      Description

      File /etc/zabbix/apache.conf from ubuntu package zabbix-frontend-php from repo.zabbix.com contains php_value directives, which assumes that libapache2-mod-php5 is used.
      In case user has different PHP configuration (eg. mod_fastcgi + PHP-FPM in my case), such directives cannot be parsed and configuration fails with

      Setting up zabbix-frontend-php (1:2.4.6-1+trusty) ...
      Enabling conf zabbix.
      To activate the new configuration, you need to run:
        service apache2 reload
       * Restarting web server apache2                                                                      [fail]
       * The apache2 configtest failed.
      Output of config test was:
      AH00526: Syntax error on line 12 of /etc/apache2/conf-enabled/zabbix.conf:
      Invalid command 'php_value', perhaps misspelled or defined by a module not included in the server configuration
      Action 'configtest' failed.
      The Apache error log may have more information.
      invoke-rc.d: initscript apache2, action "restart" failed.
      dpkg: error processing package zabbix-frontend-php (--configure):
       subprocess installed post-installation script returned error exit status 1

      The remediation from user-side is trivial, but it should not happen in the first place. Long story short, I suggest wrapping the php_value directives to <IfModule mod_php5.c>. See attached patch.

        Attachments

          Activity

            People

            • Assignee:
              Unassigned
              Reporter:
              Disassembler Disassembler
            • Votes:
              0 Vote for this issue
              Watchers:
              2 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved: