简体   繁体   English

虚拟机是否可以由 Azure 上的 2 个或更多虚拟网络“共享”?

[英]Is it possible to a VM be "shared" by 2 or more virtual networks on Azure?

On Azure, I set up the following virtual network:在 Azure 上,我设置了以下虚拟网络:

      | gateway    VPN |
Vnet1 |---------  -----| LocalNet1
      |                |

resources

Name | IP address
VM1  | 192.168.0.5

I would like to "share" the VM1 to another virtual network.我想将 VM1“共享”到另一个虚拟网络。 I thought about - and tried - setting another IP on VM1 and creating Vnet2 with a network corresponding to that new IP.我想过 - 并尝试过 - 在 VM1 上设置另一个 IP 并使用与该新 IP 对应的网络创建 Vnet2。 But it seems it is not working at all.但它似乎根本不起作用。

These two articles are close, but not exactly what I really need,这两篇文章很接近,但不是我真正需要的,

Any help or hint is appreciated.任何帮助或提示表示赞赏。

You can't have a VM with multiple NICs in different virtual networks.您不能在不同的虚拟网络中拥有具有多个 NIC 的 VM。 You can, however, have multiple NICs with each one assigned to different subnets in the same VNet.但是,您可以拥有多个 NIC,每个 NIC 分配给同一 VNet 中的不同子网。

Said that, to connect multiple VNets, you need VPN.也就是说,要连接多个 VNet,您需要 VPN。 Once the VPN is connected you will be able to communicate between networks like if they were in the same one.连接 VPN 后,您将能够在网络之间进行通信,就像它们在同一个网络中一样。

Configure a VNet to VNet Connection配置 VNet 到 VNet 连接

https://azure.microsoft.com/en-us/documentation/articles/virtual-networks-configure-vnet-to-vnet-connection/ https://azure.microsoft.com/en-us/documentation/articles/virtual-networks-configure-vnet-to-vnet-connection/

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

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM