浮动多个虚拟机的本地IP
在Google Cloud平台上,我需要创建两台将充当主服务器和复制服务器(作为数据库)的虚拟机。
碰巧我将有几个应用程序连接到主服务器,这要求我在这些应用程序中定义此主机的本地网络IP(VPC)。
当主机甚至紧急/维护重新启动时发生故障时,我的问题就会发生。这种类型的操作将要求我紧急更改所有应用程序,以使用复制机的VPC IP而不是主要的IP。
有什么办法可以让一个可以致力于连接到主机的IP,但是在必要时,将其目的地更改为复制机?
On Google Cloud Platform I need to create two virtual machines that will act as the main server and replication server (as a database).
It happens that I will have several applications that will connect to the main server, which requires me to define in these applications the local network IP (VPC) of this main machine.
My problem occurs when there is some failure on the main machine or even an emergency/maintenance reboot. This type of operation will require me to urgently change all applications to use the replication machine's VPC IP instead of the main one.
Is there any way I can have one IP that can be dedicated to connect to the main machine, but when necessary, change its destination to be the replication machine?
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(1)
取而代之的是使用内部L7 load Balancer 。请参阅比较以确定是否合适。此 pdf =“ https://www.envoyproxy.io/docs/envoy/v1.22.0/” rel =“ nofollow noreferrer”> EnvoyProxy.io 是负载平衡器。
仙女座甚至实现了循环的罗宾,但对于NIC而不是IP。
另请参见:“ nofollow noreferrer>”计算引擎
Instead use an internal L7 load balancer. See the comparision in order to decide if this is suitable. This PDF explains the stack - and envoyproxy.io is the load balancer.
Andromeda even implements round robin, but for NIC instead of IP.
Also see: Patterns for using floating IP addresses in Compute Engine