Reading cPanel logs when a visitor is blocked

Procédure

When a visitor, a tool, or yourself receive an error or block page on your cPanel site, cPanel logs allow you to find the request: its time, IP address, requested page, and returned HTTP code. Open the Metrics › Logs section, then the Access Log and the LWS Protect log. This information lets you act yourself, or give support what it needs to go further.

Note what the visitor sees

Before opening the logs, note:

  • the exact page address;
  • the date and time, with the time zone;
  • the code and text displayed, or a screenshot;
  • the visitor's IP address if you know it;
  • for a page signed “Powered by LWS Protect”, the Request ID and IP Address lines at the bottom of the page (for a tool without a browser, the Edge-Request-Id response header).

Find the request in your logs

  1. Open the logs

    In cPanel, under Metrics, click Logs (the page is titled “Logs”). The site logs are in the Site log files section: Access Log, LWS Protect, ModSecurity, Fastest Cache, Error Log, and Database.

    cPanel Logs page and its log families
  2. Search for the request in the Access Log

    Click Access Log, then View on the line for your domain (today's log) or a file in the Archived log files list (previous days). Enter the page address or the visitor's IP address in the Search field, then click Filter.

    cPanel Access Log: today's log and archived files for each domain
  3. Read a line from the Access Log

    Each line corresponds to a request: you can see the visitor's IP address, the date and time (with time zone), the requested page, the returned HTTP code, and the browser or robot name (User-Agent). Find the line matching the time and page you noted; if many lines come from the same IP address or the same robot, see the help article Is your cPanel site targeted by an influx of robots or requests: what should you do?.

  4. Search for the block in the LWS Protect log

    Click LWS Protect. Fill in From, To, the IP Address or part of the page address in Request, then click Apply filters. Each line gives the date, requested page, IP address, and an English Description, to be noted as-is. The log keeps the last 30 days; if the page shows “Unable to fetch data. Please try again.”, try again a little later.

  5. Read the details of a site error in the Error Log

    Click Error Log, then View on the error.log file (current log) or on the archive covering the incident date: web server errors related to your sites are recorded there. See also How to view Apache and PHP log files on cPanel.

    cPanel Error Log: list of files to consult

Act on what you found

For errors on the site itself:

What to provide support

If you cannot find the cause, open a support request with:

  • the exact page address;
  • the date and time of the error, with your time zone;
  • the exact code and text of the message, or a screenshot of the page;
  • for an LWS Protect page, the “Request ID” and “IP Address” lines at the bottom of the page (for a tool without a browser, the “Edge-Request-Id” response header);
  • the log lines you found, without publishing them elsewhere.

Related articles

help.lws.net/a/8183
Was this article helpful?

Yes

No

Read 2 times

Thank you! Feel free to ask questions about our documentation if you would like more information, and help us improve it.

Similar articles

Need more help?

A question about this article?

Léo, our assistant, answers you straight away based on our articles.

A problem with your account?

Our technical support team handles your request by ticket, from your customer area.

Open a ticket