Edit nginx.h
$ vi src/core/nginx.h
find lines:
#define NGINX_VERSION "0.7.64" #define NGINX_VER "nginx/" NGINX_VERSION
Change them as follows:
#define NGINX_VERSION "0.7.64" #define NGINX_VER "kutukupret/" NGINX_VERSION
Save and close the file. Now, you can compile the server. Add the following in nginx.conf to turn off nginx version number displayed on all auto generated error pages:
server_tokens off
Above hack doesn’t work here’s the good one:
edit src/http/ngx_http_header_filter_module.c
around line 48, changing the following line to something like:
static char ngx_http_server_string[] = "Server: yourserver" CRLF; static char ngx_http_server_full_string[] = "Server: yourserver" CRLF;
Usualy i installed Nginx via yum but to follow this tutorial, i installed it manualy. The problem now is nginx wouldn’t start automaticaly after rebooting. Please help..
if you’re on redhat based like init script, just run this command from shell:
make sure nginx is autostart:
start nginx manually
stop nginx manually
Ok thanks bro, udah bisa Server saya centos.
Makasih banget