Plesk

Web reconfiguration in Plesk fails: unknown option ‘InheritBefore’

Symptoms

Cause

This is the WP Toolkit bug with the ID #EXTWPTOOLK-8572, which will be fixed in the next release versions.

The InheritBefore directive is supported only in Apache starting from the 2.3.10 version and above.

Resolution

Migrate to a server with the OS that supports Apache of the 2.3.10 version.

In case migration is not an option, apply one of the workarounds below:

Workaround 1: Replace apache.php from WP Toolkit 5.7

  1. Log into the server via SSH.
  2. Download attached apache.php file with the command:

    # wget https://plesk.zendesk.com/hc/article_attachments/12387453080983/apache.php

  3. Rename /usr/local/psa/admin/plib/modules/wp-toolkit/resources/webconfigs/apache.php file:

    # mv /usr/local/psa/admin/plib/modules/wp-toolkit/resources/webconfigs/apache.php /usr/local/psa/admin/plib/modules/wp-toolkit/resources/webconfigs/apache.php_orig_58

  4. Copy downloaded apache.php to /usr/local/psa/admin/plib/modules/wp-toolkit/resources/webconfigs/ directory:

    # cp apache.php /usr/local/psa/admin/plib/modules/wp-toolkit/resources/webconfigs/apache.php

  5. Reconfigure affected example.com domain with the command:

    # plesk repair web example.com -y

    In case it is required to reconfigure all domains on the server, execute the following:

    # plesk repair web -y

    Note: during the execution of this command the websites will be temporarily unavailable, it is recommended to execute in on the maintenance window.

Workaround 2: Disable Security measurements 

  1. Log into Plesk.

  2. Go to WordPress > Security.

  3. Select example.com instance and press the Revert button:
  4. Select the following options and press the Revert button:

    • Forbid execution of PHP scripts in the wp-includes directory
    • Block author scan
    • Enable bot protection

Note: to revert these settings for multiple WP instances, in WordPress > Security page select all required instances, press the Revert button, then perform the same actions that are described in step №4.