bird系列---初学nginx

       1    i always want to write something about the technology i have learned. but cause  i am a bird in the programming world basically,so i am so shame to write the progress of learning coding. but recently ,i read an article about how to be a good programmer, it said someone must learn to write something. so i try it ,

       2   i learn about install,deploy,and the use from the this webside.   http://www.cnblogs.com/chuncn/archive/2011/10/14/2212291.html .

        and down the version of  nginx/Windows-1.9.15  .

       3  i follow the step to unpack the installation package, when i click the exeuce file nginx.exe,  it appears the error  in the error.log. the content like this:  2016/04/26 11:27:29 [emerg] 1664#7776: bind() to 0.0.0.0:80 failed (10013: An attempt was made to access a socket in a way forbidden by its access permissions).       

        4   through my effort,i know the reason of error is that apache  has already occupied the port 80 ,  so when i shut down the apache, the problem is fixed.  i change the listen 80 to 81 in the nginx.conf at last. so i get my welcome page as my wish finally.  

  

        5  some basic order about open or shutdown the nginx from the net:http://blog.csdn.net/ppby2002/article/details/38681345  

        start nginx.exe   and  nginx.exe  -s stop 

             5.1  and   an error like this:   OpenEvent("Global\ngx_stop_15664") failed (2: The system cannot find the file specified) 

             the reason of the error is that  i didn't use the order "start nginx", it can initialize all kinds of file. 

        5.2 and an error like this:  *1 directory index of "D:\nginx-1.9.15\nginx-1.9.15/html/" is forbidden, client: 127.0.0.1, server: localhost, request: "GET / HTTP/1.1", host: "localhost" 

         the reason of that is because there is no file in the directory.

         6  a perfect article about the connection between nginx and tomcat : http://cxshun.iteye.com/blog/1535188

         7 when you edit the file  nginx.conf like this, you gonna get the result like this :


         8 it has been interpreted so perfect,  8.1 proxy_pass http://web_app;  

8.2  upstream web_app {   

  server 127.0.0.1:8080;
   server 127.0.0.1:8081;


      


  • 0
    点赞
  • 0
    收藏
    觉得还不错? 一键收藏
  • 0
    评论
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值