S
S
sarkisssik2022-02-02 21:00:23
Apache HTTP Server
sarkisssik, 2022-02-02 21:00:23

How to speed up Apache + FastCGI?

Hello.
VDS Intel(R) Xeon(R) Silver 4214 CPU @ 2.20GHz (16 cores) RAM 16Gb
Recently, Yandex has started to run around the site a lot, which is why the site has started to think for a very long time (about 20 requests per second).

at the moment I have not yet collected 100% of information, but according to many criteria, everything indicates that there are some problems with the FastCGI (apache) configuration. I got into the config /etc/httpd/conf.d/fcgid.conf , adjusted it a little, but due to a misunderstanding of some parameters, maybe I’m doing something wrong, because it doesn’t bring noticeable results.

Perhaps someone will tell you what parameters you need to work with or give you a ready-made config for my hardware. I would be grateful for any hints.

# This is the Apache server configuration file for providing FastCGI support
# through mod_fcgid
#
# Documentation is available at
# http://httpd.apache.org/mod_fcgid/mod/mod_fcgid.html


LoadModule fcgid_module modules/mod_fcgid.so

# Use FastCGI to process .fcg .fcgi & .fpl scripts
AddHandler fcgid-script fcg fcgi fpl

# Sane place to put sockets and shared memory file
FcgidIPCDir /run/mod_fcgid
FcgidProcessTableFile /run/mod_fcgid/fcgid_shm


FcgidMaxRequestLen 1073741824
FcgidBusyTimeout 10000
FcgidBusyScanInterval 10000
FcgidConnectTimeout 10000
FcgidIdleTimeout 10000
FcgidIOTimeout 10000

FcgidMaxRequestsPerProcess 500
FcgidMaxProcesses 1000

MaxClients 512
ServerLimit 512

MaxRequestsPerChild 0


61fac64dc45e4359921454.png
61fac65670ef1319861693.png

Answer the question

In order to leave comments, you need to log in

2 answer(s)
N
Nikolai Turnaviotov, 2022-02-02
@foxmuldercp

If the site is corporate and it is one (not hosting), throw out Apache and install Nginx instead. Profit will be good even at the start

V
Vitsliputsli, 2022-02-02
@Vitsliputsli

If I were you, I would look at MySQL, because it is he who is overloaded, hence the brakes.

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question