日韩性视频-久久久蜜桃-www中文字幕-在线中文字幕av-亚洲欧美一区二区三区四区-撸久久-香蕉视频一区-久久无码精品丰满人妻-国产高潮av-激情福利社-日韩av网址大全-国产精品久久999-日本五十路在线-性欧美在线-久久99精品波多结衣一区-男女午夜免费视频-黑人极品ⅴideos精品欧美棵-人人妻人人澡人人爽精品欧美一区-日韩一区在线看-欧美a级在线免费观看

歡迎訪問 生活随笔!

生活随笔

當前位置: 首頁 > 运维知识 > Nginx >内容正文

Nginx

Nginx的server为0.0.0.0/0.0.0.1的作用?

發布時間:2024/4/17 Nginx 76 豆豆
生活随笔 收集整理的這篇文章主要介紹了 Nginx的server为0.0.0.0/0.0.0.1的作用? 小編覺得挺不錯的,現在分享給大家,幫大家做個參考.

看到kong默認的代理和后臺server 都是0.0.0.0,代理到上游的服務器proxy_pass $upstream_scheme://kong_upstream;配置如下,

upstream kong_upstream {server 0.0.0.1;balancer_by_lua_block {kong.balancer()}keepalive 60; }

監聽的IP地址設置了 0.0.0.0 就表示你的nginx服務器監聽本機的所有IP地址上,通過任何一個IP地址都可以訪問到.
當發送數據的一方還不知道接收方的IP地址時,會在目的IP地址字段中使用0.0.0.0,表示未知IP地址(有時還用于表示無效IP地址)。

  • In the Internet Protocol Version 4, the address 0.0.0.0 is a non-routable meta-address used to designate an invalid, unknown or non-applicable target. To give a special meaning to an otherwise invalid piece of data is an application of in-band signaling.

  • In the context of servers, 0.0.0.0 means "all IPv4 addresses on the local machine". If a host has two IP addresses, 192.168.1.1 and 10.1.2.1, and a server running on the host listens on 0.0.0.0, it will be reachable at both of those IPs.

  • In the context of routing, 0.0.0.0 usually means the default route, i.e. the route which leads to "the rest of" the internet instead of somewhere on the local network.
    wiki地址

轉載于:https://www.cnblogs.com/mentalidade/p/6834755.html

總結

以上是生活随笔為你收集整理的Nginx的server为0.0.0.0/0.0.0.1的作用?的全部內容,希望文章能夠幫你解決所遇到的問題。

如果覺得生活随笔網站內容還不錯,歡迎將生活随笔推薦給好友。