• If you are still using CentOS 7.9, it's time to convert to Alma 8 with the free centos2alma tool by Plesk or Plesk Migrator. Please let us know your experiences or concerns in this thread:
    CentOS2Alma discussion

Question Server error 500 while Flood.io testing

Matt Pad

New Pleskian
Hi,

I am testing my website in these days with Flood.io, in order to be ready for Black Friday and Christmas Days where the traffic will increase for sure.
I tested 1000 users at the same time to check how much my server can take. I have to say that, while 500 users were not a problem, 1000 users created a "500 Internal Server Error" in my website.
I run a Worpress Woocommerce that works quite well, it's fast, using Cloudflare and WProcket for caching, but after running the test these were the errors repeating over and over in the log file:

[alert] 84925#0: *2110791 socket() failed (24: Too many open files) while connecting to upstream - Errore nginx
[crit] 84925#0: accept4() failed (24: Too many open files)
84925#0: *2109332 upstream timed out (110: Connection timed out) while reading response header from upstream
socket() failed (24: Too many open files) while connecting to upstream

Now, I am not an expert in web servers and I have some questions:
- I understand that I have some limit in the server for simultaneous file opens, is it normal or should I edit some settings?
- during the test Apache memory increased to 40% and became Red, while Nginx memory was still quite empty, why is that? Is it possible to use Nginx memory too?
- I have a lot of active services in Apache (screenshot attached), but I am not confident in disabling them as I don't want the website to go down, are there services that can safely disabled?
- now, one day has passed and Apache memory is still high and red (28%), what should I do to flush it? Should I restart the server? Will this produce some down time in my website?

Sorry if I made too many questions, but I'm not a server expert and the website is already selling online, I cannot risk going offline.
Thank you very much,
Matteo
 

Attachments

  • Schermata 2019-10-16 alle 10.38.51.png
    Schermata 2019-10-16 alle 10.38.51.png
    187.8 KB · Views: 8
Looks like your post has more to do with system administration in general, and not so much with Plesk as such. But in any case, to answer some of your questions and concerns:

- I understand that I have some limit in the server for simultaneous file opens, is it normal or should I edit some settings?
Your server's setup seems OK, but if you need to cater to more concurrent visitors, you'll have to tweak it.

- during the test Apache memory increased to 40% and became Red, while Nginx memory was still quite empty, why is that? Is it possible to use Nginx memory too?
There is only one common memory and your server's OS will use it for either Apache, Nginx or any other program, according to the current needs.

The test only showed that in this case Apache needed more memory than Nginx, but to be fair, it was also doing most of the job. This is completely normal for a server setup such as yours.

- I have a lot of active services in Apache (screenshot attached), but I am not confident in disabling them as I don't want the website to go down, are there services that can safely disabled?
Those are Apache modules. Some of them could be disabled but I don't have enough information about your server to safely advise which ones.

- now, one day has passed and Apache memory is still high and red (28%), what should I do to flush it? Should I restart the server? Will this produce some down time in my website?
You should do nothing. Managing memory is the job of your server's OS. Do not try to manually flush memory.

Forget about "red" and similar designations. Observing your server memory through Plesk is only meant to be superficially informative. I suggest reading up about observing server resource statistics on linux, and go from there.

Note, server RAM is supposed to be used up. Memory usage should be close to 100% and at the same time, there should be enough of it so that some of it can be used for buffers and cache. I won't go into too much detail here, you should read up on the topic.

Sorry if I made too many questions, but I'm not a server expert and the website is already selling online, I cannot risk going offline.
That's fine, everyone has to start somewhere. But from the sound of things, I'm inclined to advise you to hire a system administrator or consider using a fully managed server/VPS.
 
Last edited:
Thank you very much, you made everything a little bit more clear, I'll search for some course to learn something more :)
 
Back
Top