VMware Cloud Community
aniros
Contributor
Contributor

VM with 2 switchs with to IP adress

Hi everyone,

I just created a VM host on a server with physical NICs.

The server is connected to two switchs with to IP adressing rang: 192.168.2.1 (Main adressing) and 192.168.4.1.

I have no problem with the main adresseing (I can ping, connect ...)

My problem now is how to "pass" the second adressing to the VM.

I main now, I can remotely connect to my VM trought 192.168.2.105, but can't connect with 192.168.4.10.

Main VM can ping the 192.168.4.1

Can you help me to make this working?

Thank you.

Reply
0 Kudos
9 Replies
NathanosBlightc
Commander
Commander

I think you mean you a have a host (maybe ESXi) with 2 physical adapter that each of them is connected to a separate network, is it correct?! (please draw your network diagram if it's possible) and you want to connect an existing VM on that host to these networks?!

Please mark my comment as the Correct Answer if this solution resolved your problem
Reply
0 Kudos
scott28tt
VMware Employee
VMware Employee

These screenshots will help others to help you:

VM network adapter settings (not the Windows configuration, but the VM hardware)

Virtual switches for the VM Port Groups that the VM network adapters are connected to, including the physical "vmnic" ports

Plus information about the physical network that the physical "vmnic" ports are connected to.


-------------------------------------------------------------------------------------------------------------------------------------------------------------

Although I am a VMware employee I contribute to VMware Communities voluntarily (ie. not in any official capacity)
VMware Training & Certification blog
Reply
0 Kudos
a_p_
Leadership
Leadership

From how I understand this, you may have a routing issue!? Are you able to reach/ping both physical switches from your PC?

André

Reply
0 Kudos
aniros
Contributor
Contributor

Hi Amine,

Yes, it's exactly what I'm trying to do.

Attached a schema to explain my case.

Thank you in advance.

Schema.png

Reply
0 Kudos
aniros
Contributor
Contributor

Hi scott28tt,

I can't sceescreen shots.

Thank you.

Reply
0 Kudos
aniros
Contributor
Contributor

From a PC connected to my LAN,

I can ping all IP (1962.168.4.x and 192.168.2.x) except the the second adress of my VM (192.168.4.10).

Thank you.

Reply
0 Kudos
scott28tt
VMware Employee
VMware Employee

No, I meant that YOU should post screenshots so that others here can help you.


-------------------------------------------------------------------------------------------------------------------------------------------------------------

Although I am a VMware employee I contribute to VMware Communities voluntarily (ie. not in any official capacity)
VMware Training & Certification blog
Reply
0 Kudos
a_p_
Leadership
Leadership

Ok, then you may want to take a look at the virtual network configuration on the ESXi host itself.

What's required in a setup like this are two vSwitches, where the second vSwitch has the uplink to the 192.168.4.1 physical switch, and a VM port group to which the VM is connected with an additional virtual network adapter.


André

Reply
0 Kudos
NathanosBlightc
Commander
Commander

So you need to setup that VM like a router. First add two vNICs for your VM and inside the guest OS, you need to setup a related IP address for each of them. There is no one-2-one relation between the ESXi IP addresses (VMKernel ports) and your VM's IP address! please read more about the vSphere Networking to know how they are working ...

Please mark my comment as the Correct Answer if this solution resolved your problem
Reply
0 Kudos