Welcome! Log In Create A New Profile

Advanced

high memory usage

Anoop Alias
October 25, 2018 10:36AM
Hi,

On a shared server with a large number of accounts

################
sites-enabled]# grep "server {" *|wc -l
11877
################

The memory usage of nginx is very high
--------------------------------------------------------------------------

Private + Shared = RAM used Program
1.6 GiB + 4.9 GiB = 6.5 GiB nginx (3)
-----------------------------------------------------------------------------

# cat /proc/2068600/maps
00400000-006d6000 r-xp 00000000 09:7d 105657122
/usr/sbin/nginx
008d5000-008d6000 r--p 002d5000 09:7d 105657122
/usr/sbin/nginx
008d6000-008fe000 rw-p 002d6000 09:7d 105657122
/usr/sbin/nginx
008fe000-00921000 rw-p 00000000 00:00 0
0218b000-a2217000 rw-p 00000000 00:00 0
[heap]
a2217000-13fbc7000 rw-p 00000000 00:00 0
[heap]


------------------------------------------------------------------------------------
pmap 2068600

2068600: nginx: master process /usr/sbin/nginx -c /etc/nginx/nginx.conf
0000000000400000 2904K r-x-- nginx
00000000008d5000 4K r---- nginx
00000000008d6000 160K rw--- nginx
00000000008fe000 140K rw--- [ anon ]
000000000218b000 2622000K rw--- [ anon ]
00000000a2217000 2582208K rw--- [ anon ]
---------------------------------------------------------------------------------------

It looks like the heap is 2.6GB in size.

Is there a way to reduce this?

The configuration is not the problem ( which is why I am not attaching it)
as systems will a smaller number of vhosts using the same config consume
less ram




--
*Anoop P Alias*
_______________________________________________
nginx mailing list
nginx@nginx.org
http://mailman.nginx.org/mailman/listinfo/nginx
Subject Author Posted

high memory usage

Anoop Alias October 25, 2018 10:36AM

Re: High memory usage

J.R. October 23, 2019 12:38PM

Re: High memory usage

bvek1 October 24, 2019 05:30AM

Re: High memory usage

J.R. October 27, 2019 01:42PM



Sorry, only registered users may post in this forum.

Click here to login

Online Users

Guests: 233
Record Number of Users: 8 on April 13, 2023
Record Number of Guests: 421 on December 02, 2018
Powered by nginx      Powered by FreeBSD      PHP Powered      Powered by MariaDB      ipv6 ready