503 Service Unavailable. The server is temporarily unable to process requests for technical reasons (maintenance, overload, etc.). In the Retry-After field of the title, the server can specify the time after which the client is recommended to repeat the request. While it may seem obvious to drop the connection immediately during an overload, it may be more effective to set a large Retry-After value to reduce the frequency of redundant requests. Appeared in HTTP/1.0. How to solve a problem? 1. Scripts freeze up - Transferring large static files via PHP - Large static files are best transferred directly without using scripts. There are two reasons for this: firstly, the running time of the scripts is limited, when it expires, the file transfer is interrupted; secondly, a separate worker process is used to transfer the file through PHP, which means that it ceases to participate in the mechanism for processing requests from users. - To transfer files directly, on the contrary, a special multi-threaded process is involved, which can process many streams at the same time, without affecting the website loading speed. - The functionality of many file storage scripts can be implemented through the mod_rewrite rules in the .htaccess file (for example, an anti-leech system). - Connecting to a remote server – It is better to avoid this. If you cannot do without this, then you need to set a small timeout for waiting for a response and make sure that the connection with the remote server is good enough. - If PHP scripts use Include-functions that load parts of the engine located on the same account, make sure that they use a local path and not a URL like <a href="http://…">http://…</a>. The presence of the URL forces the server to make an additional HTTP request - this takes an extra worker process and greatly slows down the website loading. - A large number of "heavy" or damaged CMS components - Check all the components and plugins of your CMS, disabling them one by one, and find the most difficult or corrupted, which slows down the loading of the website. If possible, discard such components, or look for a faster analogue. Also uninstall any unnecessary components that you do not use or that are optional. - Long running cron tasks. 2. A lot of slow queries to MySQL. If you have slow queries, a mysql-slow.log file is created in the logs folder of your account. The information in this file is updated once a day and contains only the most problematic SQL queries. - Install caching components in the engine that could reduce the number of SQL queries. - Optimize SQL queries. - Index the database tables by the columns that are used in the selection - If all else fails, it may be worth changing the engine to a more optimal one. 3. A large number of requests to the web server - The loaded resource is broken/contains links to too many files (images, JS scripts) that are loaded through separate requests. Try to combine resources into a single file where possible. - The website has an element that periodically sends AJAX requests to the server (for example, chat). The number of requests depends not only on the number of visitors, but also on their habit of opening multiple tabs in the browser. - Indexing bots that scan website resources (search engines). - Using resource elements or scripts on other people's websites (links to pictures, informer scripts). Use anti-leech modules / settings. - DDoS attacks. 4. Mailing list - It is best to launch the mailing list script in the system cron, which is controlled in the control panel. And schedule it to start at the time of the least load on the server (night Moscow time). At the same time, you should take into account the restrictions imposed by the terms of the offer agreement regarding the number of letters per hour/day and the time of the PHP script.