United States United States

What can I do if my website is slow?

There may be quite different causes for your application to react slowly. Additionally installed content such as themes or plugins can cause difficulties. There may be too many simultaneous accesses to your webhost, which could slow down the various processes. You may also receive an error 503 instead of your site. This article is intended to help you find the reason and fix any errors.

You can enable the php_slow.log for your webspace to locate slow scripts or components. This option can be found in your easyname control panel via [My hosting] >> [PHP Settings] via the "Settings" link next to the respective PHP version. Have scripts logged if their runtime is longer than 3 or more seconds by selecting the appropriate time period under the caption slowlog.

Some things have to be considered before you do this:

1) This option is available only for PHP 5.4 or newer versions.
2) It's activation can negatively affect the speed of all applications running with that PHP version.
3) If your application uses Zend Guard or IonCube Loader, activating this option is not recommended.
4) It can take up to 5 minutes until the setting becomes effective.

If this mode is enabled, another logfile called php_slow.log is created and stored in your /log/ directory (same level as /html/). This log records the processes which take longer than the set time. If a process can not be executed within 3 minutes, you will see a "+++ dump failed" message at the end of the respective log entry. Usually the script at the top is the cause of the problem. The functions leading to the error and where they occur in the respective script are listed below.

Here is an example of such a log entry:

[09-Nov-2016 12:34:56] [pool e12345] pid 12345
script_filename = /data/web/e12345/html/apps/example/public/index.php
[0x00007f77775ba138] curl_exec() /data/web/e12345/html/apps/example/request/api.php:12
[0x00007f77775b9f10] curl() /data/web/e12345/html/apps/example/request/rest.php:34
[0x00007f77775b9d48] request() /data/web/e12345/html/apps/example/do/something.php:56
[0x00007f77775b9540] call_user_func_array() /data/web/e12345/html/apps/example/wp-includes/plugin.php:78
[0x00007f77775b9428] do_action() /data/web/e12345/html/apps/example/wp-includes/general-template.php:90
[0x00007f77775b9358] wp_footer() /data/web/e12345/html/apps/example/wp-content/themes/theme/footer.php:12
[0x00007f77775b9358] +++ dump failed

Some processes, such as updates or cronjobs, can be ignored. Especially if they have nothing to do with viewing the page, but instead perform operations that take longer than, for example, 3 or more seconds.