简体   繁体   English

我们可以将多个域名指向同一个 IP 地址吗?

[英]Can we point multiple domain names to the same IP address?

I have two GKE cluster (GKE-OLD and GKE-NEW) running behind two separate load balancers.我有两个 GKE 集群(GKE-OLD 和 GKE-NEW)在两个单独的负载均衡器后面运行。

The GKE-OLD cluster runs behind a L4 global load balancer where as the GKE-NEW cluster runs behind a L7 load balancer. GKE-OLD 集群在 L4 全局负载均衡器之后运行,而 GKE-NEW 集群在 L7 负载均衡器之后运行。

The services of the clusters are accessible through two separate domain names.集群的服务可以通过两个单独的域名访问。

www.service.company.com points to the L4 load balancer behind which the GKE-OLD cluster is running. www.service.company.com指向运行 GKE-OLD 集群的 L4 负载均衡器。

www.service-1.company.com points to the L7 load balancer behind which the GKE-NEW cluster is running. www.service-1.company.com指向运行 GKE-NEW 集群的 L7 负载均衡器。

在此处输入图像描述

I want to eventually get rid of the old cluster and LB associated with it.我想最终摆脱旧的集群和与之相关的 LB。 However, I want to keep the domain name (www.service.company.com) from the old cluster and eventually retire the www.service-1.company.com domain name that is associated with the new cluster.但是,我想保留旧集群中的域名(www.service.company.com)并最终停用与新集群关联的www.service-1.company.com域名。

Before I decommission the old cluster, the current setup I want to have should look something like this:在我停用旧集群之前,我想要的当前设置应该如下所示: 在此处输入图像描述

My questions are:我的问题是:

Can we have multiple domains pointing at same IP address (LB) and same domain pointing at multiple IP addresses (LBs) at the same time?我们是否可以有多个域同时指向同一个 IP 地址 (LB) 和同一个域指向多个 IP 地址 (LB)? www.service.company.com and www.service-1.company.com pointing at the same load balancer. www.service.company.comwww.service-1.company.com指向同一个负载均衡器。 And www.service.company.com pointing at both L4 and L7 LBs.并且www.service.company.com指向 L4 和 L7 LB。

Can we have multiple domains pointing at same IP address (LB) and same domain pointing at multiple IP addresses (LBs)我们能否有多个域指向同一个 IP 地址 (LB) 和同一个域指向多个 IP 地址 (LB)

Yes you can have multiple names resolve to the same IP address (either directly with A and AAAA or through CNAME records), and yes you can have a name resolving to multiple IP addresses (again through direct A + AAAA records or through CNAME records), but in which case, except if there is some specific tooling on the client side (the application consuming those records), things will work in a load balancing fashion among all addresses, not in failover fashion.是的,您可以将多个名称解析为相同的 IP 地址(直接使用AAAAA或通过CNAME记录),是的,您可以将名称解析为多个 IP 地址(再次通过直接A + AAAA记录或通过CNAME记录) ,但在这种情况下,除非客户端有一些特定的工具(使用这些记录的应用程序),否则事情将在所有地址之间以负载平衡方式工作,而不是以故障转移方式。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

相关问题 通过不同的端口将不同的域名分配给同一IP地址 - Different domain names assigned to the same IP address with different ports 我们可以用实际的域名替换IP地址吗? - Can we replace IP address with actual domain name? 反向ip,在ip地址上查找域名 - Reverse ip, find domain names on ip address 如何将多个域名指向同一个 GitHub Pages 站点? - How can I point multiple domain names to the same GitHub Pages site? 我可以让多个域名指向同一服务器上的不同子目录吗? - Can I have multiple domain names point to different subdirectories on the same server 将多个域名解析到同一WAN IP上的不同虚拟机 - Resolving multiple domain names to different virtual machines on the same WAN IP 我们给客户端什么 IP 地址以指向我们在路由 53 上的域? - What IP address do we give to clients to point to our domain on route 53? 将域名指向带有端口号的 IP 地址 - To point domain name to IP address with port number 如何配置域名的DNS记录以使其指向同一IP地址? - How to configure the DNS record for a domain name to point both at the same IP address? 解析与多个域名对应的IP地址 - Resolving IP addresses that correspond to multiple domain names
 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM