1

I have installed Zimbra 8.6 on CentOS 7 and I have changed the

zmprov modifyConfig zimbraFileUploadMaxSize 5000000
zmprov mcf zimbraMtaMaxMessageSize 52428800

I have restarted the mailbox

the I can't access to my Zimbra webmail with the proxy address so i have checked the proxy server and I have restarted it.

Then I have this issue

Starting zmconfigd...Done.
Starting memcached...Done.
Starting proxy...Failed. Starting nginx...nginx: [emerg] could not build the server_names_hash, you should increase either server_names_hash_max_size: 512 or server_names_hash_bucket_size: 64 failed.

I have followed this article and I changed it and no way.

  • Have a look at this link, this might help you – Mongrel Mar 4 '16 at 15:08
  • I have seen it but no way. i can't reload or execute # nginx -t – mzpx Mar 4 '16 at 15:11
  • what changes have you made so far. show us the output of nginx -t – Mongrel Mar 4 '16 at 15:14
  • i have edited the /opt/zimbra/nginx/conf/nginx.conf and i added this two lines on http section : server_names_hash_max_size 512; server_names_hash_bucket_size 128; #nginx -t the output is -bash: nginx: command not found – mzpx Mar 4 '16 at 15:17
1

Hello guys i have solved the problem like this :

# su - zimbra

$ zmlocalconfig -e proxy_server_names_hash_max_size=4096
$ zmlocalconfig -e proxy_server_names_hash_bucket_size=512

$ zmproxyctl start
0

You just need to increase the size of the hash table as an when you increase the server

It depends on your setup, you can reduce the number of server from the table and reload the service instead of restart.

service nginx reload

server_names_hash_max_size

Its default value is 512. If you are hosting hundreds of sites on your server.

Nginx suggests, you can change either server_names_hash_max_size or server_names_hash_bucket_size to accomodate large number of sites, but I prefer keeping server_names_hash_bucket_size as it is and making server_names_hash_max_size big in multiple of 2’s till error disappears.

On a server, where we host 300+ sites, we needed to change it to 8192

Use a trick to find out correct size by using following command:

ls /etc/nginx/sites-available/ | wc -c

  • hi, there is not this directory (/etc/nginx/sites-available/) in zimbra i have /opt/zimbra/nginx/conf/nginx.com and /opt/zimbra/conf/nginx.conf – mzpx Mar 4 '16 at 18:29

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.