If your website has availability issues, the starting point to troubleshoot them is to look at the web server logs. However, detecting, analyzing, and resolving the issues is a complex task. You need to know how the web server works, where the logs are located, how to analyze the logs, and more. The new Plesk feature 「Website Log Check」 can save you time and effort. Website Log Check scans the web server logs for common issues, shows how often a specific issue occurs, and suggests ways to resolve the issue.

備註: The feature is available to Plesk administrators only.

Website Log Check resolves the following difficulties Plesk administrators face when analyzing logs:

Difficulty Website Log Check Value
The operating system has a large number of log files that contain meaningful information. Their location differs depending on the operating system. Website Log Check scans all relevant log files, finds patterns of known issues, and shows how to find the detected issues in logs and the location of the logs themselves.
To examine log files, you need to access the Plesk server via SSH. Website Log Check detects issues and shows their solutions in the Plesk interface. It is often possible to apply the solutions without connecting to the Plesk server via SSH.
Website issues are often related to the server and the website load. Website Log Check shows the graph with the distribution of the detected issues over time. You will know when exactly the issue occurred and how it is related to the number of requests to the website.
One issue can affect multiple websites. Website Log Check shows all websites affected by the issue.
It is a daunting task to search for solutions in the Internet on the basis of logged errors. Website Log Check shows solutions approved by Plesk users and Plesk Support.

Usage

Website Log Check can scan the web server logs automatically and manually.

The automatic check scans the logs of websites every day at a specific time and informs about the detected issues on the cards of the affected websites. The automatic check can scan all websites or only those you have selected. You can turn off the automatic check at any time.

With the manual check, you can scan the logs of the desired websites at any time and select the time period you want to check (for example, the last 5, 10, or 30 minutes).

To enable and access Website Log Check:

  1. Open the panel.ini file for editing, which is located in /usr/local/psa/admin/conf/panel.ini.

    您還可以使用`Panel.ini Editor <https://www.plesk.com/extensions/panel-ini-editor/>`__ 擴展在Plesk介面中編輯該檔。

  2. 添加以下各行到``panel.ini``檔並將其保存:

    [websitesDiagnostic]
    enabled = true
    
  3. Go to Tools & Settings > Website Log Check (under 「Assistance and Troubleshooting」) or to the website card (Websites & Domains > domain > Logs).

Usage Recommendations

To get the most out of the Website Log Check feature, we recommend that you use the automatic and manual checks in tandem. Learn how to do so and see other useful recommendations in the section below.

  1. Go to Tools & Settings > Website Log Check (under 「Assistance and Troubleshooting」). Here you can see results of all checks (both manual and automatic ones). Have a look at check results of hosted domains.
  2. Keep the automatic check turned on. This will help you to catch website issues before your customers will notice them.
  3. Checking logs of high traffic websites can take up a significant amount of the server resources. If it is your case, go to the automatic check settings and select the websites with the highest priority. The automatic check will scan only them.
  4. If Website Log Check detects an issue, it also shows one or more ways to resolve it. Follow the suggested solutions to troubleshoot the issue.
  5. Once you tried troubleshooting the issue, open the affected website in the browser and visit various pages of the website. Note the time you spent on this activity (for example, five minutes). You will later need it to run the manual check.
  6. Return to Website Log Check and run the manual check of the affected website selecting the time period you want to check. In our example, the last five minutes. Manual check will show if you have fixed the issue or it still occurred during your last website visit.

At the moment, Website Log Check can detect the following issues:

  • PHP-FPM 「server reached max_children setting」
  • ModSecurity 「Access denied with code 403」
  • PHP 「Internal Server error 500: Allowed memory size of XXX exhausted」
  • PHP 「open_basedir restriction in effect」
  • Apache .htaccess 「403 Forbidden AH01797: client denied by server configuration」
  • Apache 「Cannot access a website directory in Plesk: 403 Forbidden」
  • Nginx 「Cannot access a website directory in Plesk: 403 Forbidden」
  • Apache .htaccess 「403 Forbidden: pcfg_openfile: unable to check htaccess file, ensure it is readable」
  • Nginx 「Too many open files」

In the future, Website Log Check will be able to detect the following issues:

  • Nginx 「502 Bad Gateway: upstream sent too big header while reading response header」
  • Apache 「500 Internal Server Error: Option FollowSymLinks not allowed here」
  • ModSecurity 「Response body too large」
  • Apache 「server reached MaxRequestWorkers setting」
  • PHP request body limit 「client intended to send too large body」
  • PHP request body limit 「client intended to send too large body」
  • PHP sessions 「503 Internal Server Error」 or 「Failed to read session data」
  • Apache .htaccess 「403 Forbidden: pcfg_openfile: unable to check htaccess file, ensure it is readable」

備註: Website log check is a beta feature and we are constantly improving it. If you have feedback about the feature, please send it to beta-extensions@plesk.com.