Добрый день, подскажите пожалуйста по настройкам Апача, имеется следующая конфигурация
1.
2.
3.
4.
5.
6.
7.
8.
9.
10.
11.
12.
13.
14.
15.
16.
17.
18.
19.
20.
21.
22.
23.
24.
25.
26.
27.
28.
29.
30.
31.
32.
33.
34.
35.
36.
37.
38.
39.
40.
41.
42.
43.
44.
45.
46.
47.
48.
49.
50.
51.
52.
53.
54.
55.
56.
57.
58.
59.
60.
61.
62.
63.
64.
65.
66.
67.
68.
69.
70.
71.
72.
73.
74.
75.
76.
77.
78.
79.
80.
81.
82.
83.
84.
85.
86.
87.
88.
89.
90.
91.
92.
93.
94.
95.
96.
97.
98.
99.
100.
101.
102.
103.
104.
105.
106.
107.
108.
109.
110.
111.
112.
113.
114.
115.
#
# ServerRoot: The top of the directory tree under which the server's
# configuration, error, and log files are kept.
#
# NOTE! If you intend to place this on an NFS (or otherwise network)
# mounted filesystem then please read the LockFile documentation (available
# at <URL:http://httpd.apache.org/docs/2.2/mod/mpm_common.html#lockfile>);
# you will save yourself a lot of trouble.
#
# Do NOT add a slash at the end of the directory path.
#
#ServerRoot "/etc/apache2"
#
# The accept serialization lock file MUST BE STORED ON A LOCAL DISK.
#
LockFile ${APACHE_LOCK_DIR}/accept.lock
#
# PidFile: The file in which the server should record its process
# identification number when it starts.
# This needs to be set in /etc/apache2/envvars
#
PidFile ${APACHE_PID_FILE}
#
# Timeout: The number of seconds before receives and sends time out.
#
Timeout 300
#
# KeepAlive: Whether or not to allow persistent connections (more than
# one request per connection). Set to "Off" to deactivate.
#
KeepAlive On
#
# MaxKeepAliveRequests: The maximum number of requests to allow
# during a persistent connection. Set to 0 to allow an unlimited amount.
# We recommend you leave this number high, for maximum performance.
#
MaxKeepAliveRequests 500
#
# KeepAliveTimeout: Number of seconds to wait for the next request from the
# same client on the same connection.
#
KeepAliveTimeout 15
##
## Server-Pool Size Regulation (MPM specific)
##
# prefork MPM
# StartServers: number of server processes to start
# MinSpareServers: minimum number of server processes which are kept spare
# MaxSpareServers: maximum number of server processes which are kept spare
# MaxClients: maximum number of server processes allowed to start
# MaxRequestsPerChild: maximum number of requests a server process serves
<IfModule mpm_prefork_module>
StartServers 5
MinSpareServers 5
MaxSpareServers 10
MaxClients 100
MaxRequestsPerChild 4096
</IfModule>
# worker MPM
# StartServers: initial number of server processes to start
# MaxClients: maximum number of simultaneous client connections
# MinSpareThreads: minimum number of worker threads which are kept spare
# MaxSpareThreads: maximum number of worker threads which are kept spare
# ThreadLimit: ThreadsPerChild can be changed to this maximum value during a
# graceful restart. ThreadLimit can only be changed by stopping
# and starting Apache.
# ThreadsPerChild: constant number of worker threads in each server process
# MaxRequestsPerChild: maximum number of requests a server process serves
<IfModule mpm_worker_module>
StartServers 2
MinSpareThreads 25
MaxSpareThreads 75
ThreadLimit 64
ThreadsPerChild 25
MaxClients 150
MaxRequestsPerChild 0
</IfModule>
# event MPM
# StartServers: initial number of server processes to start
# MaxClients: maximum number of simultaneous client connections
# MinSpareThreads: minimum number of worker threads which are kept spare
# MaxSpareThreads: maximum number of worker threads which are kept spare
# ThreadsPerChild: constant number of worker threads in each server process
# MaxRequestsPerChild: maximum number of requests a server process serves
<IfModule mpm_event_module>
StartServers 2
MaxClients 150
MinSpareThreads 25
MaxSpareThreads 75
ThreadLimit 64
ThreadsPerChild 25
MaxRequestsPerChild 0
</IfModule>
# These need to be set in /etc/apache2/envvars
User ${APACHE_RUN_USER}
Group ${APACHE_RUN_GROUP}
#
# AccessFileName: The name of the file to look for in each directory
# for additional configuration directives. See also the AllowOverride
# directive.
#
AccessFileName .htaccess
работает все это дело в префорк, на сервере порядка 200 сайтов, пугает меня процесс апача отдельно взятый который грузит память до 70-80мб
1.
2.
3.
4.
5.
6.
7.
8.
9.
10.
11.
12.
13.
14.
15.
16.
17.
18.
19.
20.
PID USER PR NI VIRT RES SHR S %CPU %MEM TIME+ COMMAND
2632 mysql 20 0 4951m 4.6g 12m S 457 14.9 14914:20 /usr/sbin/mysqld --basedir=/usr --da
3445 www-data 20 0 292m 79m 7272 R 94 0.3 0:57.85 /usr/sbin/apache2 -k start
4397 www-data 20 0 275m 63m 7348 S 30 0.2 0:19.49 /usr/sbin/apache2 -k start
3355 www-data 20 0 302m 90m 6304 S 24 0.3 0:27.98 /usr/sbin/apache2 -k start
4360 www-data 20 0 281m 65m 5556 S 15 0.2 0:11.47 /usr/sbin/apache2 -k start
3424 www-data 20 0 278m 65m 5924 S 14 0.2 0:15.08 /usr/sbin/apache2 -k start
4370 www-data 20 0 279m 64m 6076 S 14 0.2 0:20.91 /usr/sbin/apache2 -k start
4450 www-data 20 0 275m 61m 6072 S 14 0.2 0:09.92 /usr/sbin/apache2 -k start
4352 www-data 20 0 275m 61m 6164 S 12 0.2 0:14.31 /usr/sbin/apache2 -k start
4435 www-data 20 0 280m 64m 6044 S 12 0.2 0:17.28 /usr/sbin/apache2 -k start
4327 www-data 20 0 285m 71m 5636 S 10 0.2 0:09.72 /usr/sbin/apache2 -k start
3310 www-data 20 0 279m 64m 6776 S 9 0.2 0:31.19 /usr/sbin/apache2 -k start
3246 www-data 20 0 270m 58m 6816 R 5 0.2 0:24.91 /usr/sbin/apache2 -k start
4454 www-data 20 0 286m 72m 6044 S 2 0.2 1:12.21 /usr/sbin/apache2 -k start
2587 www-data 20 0 286m 74m 7508 S 1 0.2 0:47.20 /usr/sbin/apache2 -k start
1872 gitlab 20 0 859m 99m 1360 S 0 0.3 3:59.82 resque-1.20.0: Waiting for post_rece
3447 www-data 20 0 287m 74m 6612 S 0 0.2 0:14.11 /usr/sbin/apache2 -k start
4357 www-data 20 0 281m 66m 7004 S 0 0.2 0:12.11 /usr/sbin/apache2 -k start
4373 www-data 20 0 275m 63m 6324 S 0 0.2 1:02.64 /usr/sbin/apache2 -k start
подскажите пожалуйста что где можно оптимизировать или подкрутить в апаче? Заранее признателен за советы