Welcome! Log In Create A New Profile

Advanced

Re: shared memory zone "media" conflicts with already declared size 0

February 08, 2013 10:01AM
I am using nginx version: nginx/1.2.6 and facing a similar error:

Starting nginx: nginx: the configuration file /etc/nginx/nginx.conf syntax is ok
nginx: [emerg] zero size shared memory zone "limit_per_ip"
nginx: configuration file /etc/nginx/nginx.conf test failed
invoke-rc.d: initscript nginx, action "start" failed.

Here's my nginx.conf file:

user www-data;
worker_processes 2;
pid /var/run/nginx.pid;

events {
worker_connections 768;
# multi_accept on;
}

http {

# Cloudflare
set_real_ip_from 204.93.240.0/24;
set_real_ip_from 204.93.177.0/24;
set_real_ip_from 199.27.128.0/21;
set_real_ip_from 173.245.48.0/20;
set_real_ip_from 103.22.200.0/22;
set_real_ip_from 141.101.64.0/18;
set_real_ip_from 108.162.192.0/18;
set_real_ip_from 190.93.240.0/20;
real_ip_header CF-Connecting-IP;

sendfile on;
tcp_nopush on;
tcp_nodelay on;
types_hash_max_size 2048;

client_body_timeout 10;
client_header_timeout 10;
keepalive_timeout 10;
send_timeout 10;
#limit_zone limit_per_ip $binary_remote_addr 16m;

server_tokens off;
#charset utf-8;

expires -1; #A negative time sets the Cache-Control header to no-cache

client_max_body_size 10m;
client_body_buffer_size 128k;

# server_name_in_redirect off;

include /etc/nginx/mime.types;
default_type application/octet-stream;

access_log /var/log/nginx/access.log;
error_log /var/log/nginx/error.log;

gzip on;
gzip_disable "msie6";
gzip_vary on; #you instruct proxies to store both a compressed and uncompressed version of the content
# gzip_proxied any;
gzip_comp_level 6;
# gzip_buffers 16 8k;
gzip_http_version 1.1;
gzip_types text/plain text/css application/json application/x-javascript text/xml application/xml application/xml+rss text/javascript;

include /etc/nginx/conf.d/*.conf;
include /etc/nginx/sites-enabled/*;
}

Thanks for any help.
SubjectAuthorPosted

shared memory zone "media" conflicts with already declared size 0

Tomasz PajorSeptember 28, 2009 12:20PM

Re: shared memory zone "media" conflicts with already declared size 0

Igor SysoevSeptember 28, 2009 03:06PM

Re: shared memory zone "media" conflicts with already declared size 0

Tomasz PajorSeptember 29, 2009 05:06AM

Re: shared memory zone "media" conflicts with already declared size 0

Igor SysoevSeptember 29, 2009 05:16AM

Re: shared memory zone "media" conflicts with already declared size 0

Tomasz PajorSeptember 29, 2009 05:48AM

Re: shared memory zone "media" conflicts with already declared size 0

Igor SysoevSeptember 29, 2009 05:56AM

Re: shared memory zone "media" conflicts with already declared size 0

Maxim DouninSeptember 29, 2009 06:36AM

Re: shared memory zone "media" conflicts with already declared size 0

Tomasz PajorSeptember 29, 2009 06:52AM

Re: shared memory zone "media" conflicts with already declared size 0

Gena MakhomedSeptember 29, 2009 09:12AM

Re: shared memory zone "media" conflicts with already declared size 0

Maxim DouninSeptember 29, 2009 09:52AM

Re: shared memory zone "media" conflicts with already declared size 0

longntFebruary 06, 2013 01:57AM

Re: shared memory zone "media" conflicts with already declared size 0

Maxim DouninSeptember 29, 2009 07:22AM

Re: shared memory zone "media" conflicts with already declared size 0

Igor SysoevSeptember 29, 2009 09:18AM

Re: shared memory zone "media" conflicts with already declared size 0

atipicoFebruary 08, 2013 10:01AM

Re: shared memory zone "media" conflicts with already declared size 0

Ruslan ErmilovFebruary 08, 2013 01:46PM



Sorry, only registered users may post in this forum.

Click here to login

Online Users

Guests: 101
Record Number of Users: 7 on March 06, 2014
Record Number of Guests: 165 on April 21, 2014
Powered by nginx    Powered by FreeBSD    PHP Powered    Powered by Percona     ipv6 ready