In addition to Weibo, there is also WeChat
Please pay attention
WeChat public account
Shulou
2025-01-16 Update From: SLTechnology News&Howtos shulou NAV: SLTechnology News&Howtos > Servers >
Share
Shulou(Shulou.com)06/01 Report--
How to understand the role of routing mesh, I believe that many inexperienced people do not know what to do. Therefore, this paper summarizes the causes and solutions of the problem. Through this article, I hope you can solve this problem.
When we access port 8080 of any node, the load balancer inside the swarm forwards the request to one of the copies of the web_server.
That's what routing mesh does.
So no matter which node you visit, even if there is no copy of service running on that node, you will eventually be able to access service.
Alternatively, we can configure an external load balancer to route the request to the swarm service. For example, configure HAProxy to distribute requests to port 8080 of each node.
Ingress network
When we apply-- publish-add 8080 service 80, swarm reconfigures service, and we see what important changes have taken place in the container.
Are you surprised? All previous copies are Shutdown, and then start a new copy. Let's look at the container network configuration for the new copy.
The network of the container is very different from that of publish-add. Now there are two network cards, each of which is connected to a different Docker network.
In fact:
Eth0 connects to an overlay-type network called ingress, which allows containers running on different hosts to communicate with each other.
Eth2 connects to a bridge-type network called docker_gwbridge, and its purpose is to enable the container to access the public network.
The ingress network is created by Docker for us automatically when swarm is created, and every node in swarm can use ingress.
If you are interested in the principle and implementation of Docker overlay network, you can review the previous chapter on Docker container network.
Through the overlay network, hosts and containers, containers and containers can access each other; at the same time, routing mesh routes external requests to the containers of different hosts, thus realizing the external network access to service.
After reading the above, have you mastered how to understand the role of routing mesh? If you want to learn more skills or want to know more about it, you are welcome to follow the industry information channel, thank you for reading!
Welcome to subscribe "Shulou Technology Information " to get latest news, interesting things and hot topics in the IT industry, and controls the hottest and latest Internet news, technology news and IT industry trends.
Views: 0
*The comments in the above article only represent the author's personal views and do not represent the views and positions of this website. If you have more insights, please feel free to contribute and share.
Continue with the installation of the previous hadoop.First, install zookooper1. Decompress zookoope
"Every 5-10 years, there's a rare product, a really special, very unusual product that's the most un
© 2024 shulou.com SLNews company. All rights reserved.