首页 > 错误异常 > 服务器 > web服务器 > nginx
在nginx中新添加了个网站配置,重启nginx的时候就报错:nginx: [emerg] could not build server_names_hash, you should increase server_names_hash_bucket_size: 32
最佳解决方案
根据提示提升server_names_hash_bucket_size配置值就行了。server_names_hash_bucket_size一般在nginx.conf的http节点里面,配置值需要时32的整数倍64、128都可以。具体如下图: