1、官网下载Nginx
http://nginx.org/en/download.html
网络不好的时候下载容易中断,要是中断了可能会出一些问题,需要重新下载。
2、配置文件的调整
/**
*负载均衡
*weight:权重
*/
upstream aaa{
server localhost:8812 weight=1;
server localhost:8813 weight=2;
}
server {
listen 80;
server_name localhost;
#charset koi8-r;
#access_log logs/host.access.log main;
location / {
# root html;
# index hm.html;
proxy_pass http://127.0.0.1:8080;
}
}