Today, I checked for a customer the problem that the home page of his website took too long to load. After the problem was solved, I shared the process and tools to help users with the same problem.
First of all, the customer's website data is about 5w+, and it takes more than 5 seconds to open the home page each time. As shown in the figure below, the TTFB time is 5.94 seconds.
First, check whether it is a server problem. If another website with the same program and data under the same server is opened, it does not have this problem. Eliminate the server problem.
Let's look at the problem again. Only the home page load time is slow, and the opening time of other pages is normal. The home page of this station is a cms layout, which calls quite a number of data modules, so the preliminary judgment is to read the SQL database.
After troubleshooting, the zblog application center searches for "debug" and installs the plug-in as shown in the following figure:
After the plug-in is installed and enabled, open the home page, click the green bug at the bottom left corner, and the following interface will appear:
Here is all the sql data information that needs to be queried when opening the current page. There is a query response time on the right side of each information. If you look at which data query time is too long, you can roughly know what the problem is.
PS: If you don't understand this information, our suggestion is to give your subject author a screenshot of the SQL data information that has been loaded for too long to check. Developers with specific information can easily and accurately locate the problem.
Text label: ZBLOG SQL Debug Mode Slow loading of website pages TTFB
A little Jack https://lkba.cn
The blogger focuses on Z-Blog website construction, website optimization, computer troubleshooting, reinstallation, optimization, maintenance system, etc., QQ/WX: 2126245521 (please specify the purpose)
Copyright © 2020-2023 Jack's works Reserved.
Powered By Z-Blog Sitemap | Shu ICP Bei No. 2023025269 - 1
Processed : 0.052 SQL : 15