Quantcast
Channel: Nginx Forum - Nginx Mailing List - English
Viewing all articles
Browse latest Browse all 7229

nginx 1.11.5 'duplicate' map_hash_bucket_size error when geoip_country block used? (2 replies)

$
0
0
I have a working nginx/1.11.5 instance, with this in config

...
http(
...
134 map_hash_bucket_size 4096;

...
)
...

when I add geoip blocking

...
http (
+ geoip_country /var/lib/GeoIP/GeoIP.dat;
+ map $geoip_country_code $allowed_country {
+ default yes;
+ XX no; # some country
...
134 map_hash_bucket_size 4096;

...
)
...

config check now reports

nginx: [emerg] "map_hash_bucket_size" directive is duplicate in /etc/nginx/nginx.conf:134

simply commenting out

- map_hash_bucket_size 4096;
+ #map_hash_bucket_size 4096;

fixes the config error.

Why can't 'map_hash_bucket_size' be set in the presence of the geoip_country snippet?

Config error? Bug? other?

_______________________________________________
nginx mailing list
nginx@nginx.org
http://mailman.nginx.org/mailman/listinfo/nginx

Viewing all articles
Browse latest Browse all 7229

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>