Last update at :2024-06-28,Edit by888u
When Snail was browsing the comments on the public account today, I saw netizens mentioning that when they were using the cloud server they purchased during the mid-year promotion a few days ago to build a website, they often encountered the 504 Gateway time-out problem. Of course, the main problem was They will definitely blame the hosting provider for the problem. So Snail helped to find out what the problem was.
First, the status of the website program
Snail saw that this classmate was using Dreamweaver CMS, which we often call DEDECMS. It is a relatively old free PHP CMS program that is no longer updated. Snail also likes this program. Except for the poor security of its interactive functions, it is still quite simple to use when configuring templates. I used to use this CMS program when making websites in my company.
The DEDECMS program is particularly suitable for content-based websites. I saw that this student also used it to collect content. I saw that there were tens of thousands of data in his background. He collected all the data, and then generated the HTML page without any problems for a while. However, after a while, the 504 Gateway time-out problem appeared.
Second, server configuration issues
When we see the above problem, many friends must have guessed where the problem lies. Too much data is caused by insufficient server configuration. So I looked at his server configuration and it was a 1G1M Hong Kong server. Although Snail mentioned in the previous article that 1G1M server can build a personal website and write a personal blog without any problem, but if you are collecting data, even tens of thousands or hundreds of thousands of data, it may be slowly collected and stored in the database There is no problem yet. If it is a one-time production of HTML, it will definitely not work.
Third, solution attempt
Here Snail proposes several solutions. First, when we generate static files, we should not generate them all at once. We can generate them slowly by column. If you generate tens of thousands at a time, it will definitely not work.
Secondly, we need to tune the NGINX configuration and slightly increase the parameters.
The configuration parameters are slightly adjusted, but this is not a complete solution. All we need to do is upgrade the server configuration. You need a configuration of about 4G3M.
Finally, this student solved the problem by upgrading the server configuration and upgrading by column. The 504 Gateway time-out problem has not yet occurred.
Recommended site search: domain name, broadband IP address query, free virtual host application, website registration time, space service provider, mainland China registration-free CDN, proxy IP, vps US server, 6 yuan a year cloud server, host discount code,
发表评论