Logs Available for the Site
Logs are an important part of our service, since if your website starts acting out, slowing down or breaks down completely, you can find out what is wrong by checking the logs on the server. Our customer service is happy to help, but our customers can also view their website's logs by themselves. You can find PHP and HTTP access and error logs in your site's log folder /data/log.
All important log files of the WordPress environment are created in the /data/log/ folder. You can find the error and access log files for both PHP and HTTP performances in the log folder.
If something on your site is not working, it is often worth checking the php error log first:
$ tail -f /data/log/php-error.log
You can also conveniently track all the server log files with one command:
These are the most common and useful log files you can see in the log folder.
Information about the emails sent by the website. Confirmation emails from the contact forms etc.
WWW-server access log. Logs all traffic on the website.
WWW-server error log.
WordPress functionality is built with PHP, which means that if something is not working correctly, you should check this log file first to see which theme, plugin or script is not working correctly.
Information about the emails sent via WordPress.
We use a database caching software called Redis to speed up database queries. Here you can see information about its functionality.
Results from the security scans.
Information about automatic WordPress core, plugin and theme updates.
WordPress admin logins are listed here. This log is especially useful if you suspect a password for an account has been compromised.
How to read the logs.
You can view the logs either in WordPress admin panel or by accessing the server via SSH.
In WordPress admin panel
When you have logged into WordPress admin, you can browse the logs in Tools > Logs. These are the same logs you can see on the server (see below).
On the server
After you access your server via SSH, you can find all logs in /data/log folder. The command 'ls' shows you the contents of the log folder. You can view a log file by entering:
cd /data/log<br>more php-error.log
You can also follow the most useful logs with command:
Then when you browse your website, you can see new entries appearing in the logs.
Solving problems using log files
Especially when developing a website, something may go wrong and you are presented with a white screen instead of your website. In this case the problem is most likely visible in php-error.log file. You may not be able to use the WordPress admin panel because the site is not working, but you can always view the logs on the server. On the server you can also make changes to the problematic scripts that broke the site. Entries in php-error.log are in format:
[timestamp] error message php file and line number where the problem is>
So it is relatively easy for the developer to see where the problem is and to fix it, or identify the exact moment when the error occurred which helps in choosing the correct backup to revert to if that is needed.
How long are the logs available?
Logs are rotated and compressed weekly to save disk space and we store them for one year. This makes it possible to investigate even older issues, for example security breaches, that there might have been on the site.