Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

What does the "shared memory zone" mean in nginx?

According to the nginx documentation, the proxy_cache_path directive has a parameter called keys_zone. The documentation also refers a concept of "shared memory zone".

In addition, all active keys and information about data are stored in a shared memory zone, whose name and size are configured by the keys_zone parameter. One megabyte zone can store about 8 thousand keys.

Is the "shared memory zone" a general term? or a specific term used by nginx? What does the "shared" exactly mean?

like image 752
yaquawa Avatar asked Jul 10 '16 18:07

yaquawa


1 Answers

A shared memory zone is a general term. Within the context of Nginx, a shared memory zone is defined so that worker processes can share stuff, for example, counters when you want to apply access limits.

In case you're not familiar with worker processes, check this image. enter image description here

like image 190
Amri Avatar answered Oct 01 '22 13:10

Amri