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

Disabling requested database PHP extention results in unfriendly fatal error

    XMLWordPrintable

Details

    Description

      As of ZBX-6020 in ZABBIX 2.2 all mysql functions will be replaced with mysqli. By default mysqli functions in PHP configuration are disabled. Since we're suppressing connection errors with @ to produce friendly user errors in setup, due a disabled database extention, user will get a white page. Removing @ from mysqli_connect, page would show a fatal error, that PHP can't find such function. Same thing happens in not only for index.php but for setup.php as well. Setup tries to initialize database before we even see the installation steps.

      There are few options:

      • Extend function checkPhpDatabases to support requesting a specific database type and in case one of required functions does not exist, throw an error;
      • or use extention_loaded() before calling database functions;
      • some other and/or better solution.

      Small discussion about this fix is required.

      Attachments

        Issue Links

          Activity

            People

              Unassigned Unassigned
              iivs Ivo Kurzemnieks
              Votes:
              0 Vote for this issue
              Watchers:
              1 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved: