Hello,
I'm practising and I have created 2 vSwitches (0 and 1)
vSwitch0 -> vmnic0
vSwitch1 -> vmnic1
The problem is that I don't know how to map virtual NICs (vmnics) with vmnets so they have the correct addressing, the default gateways and so on.
¿What am I missing?
Thanks!
A vSwitch itself doesn't have an IP address. It's just the VMkernel port groups (e.g. for ESXi Management), and the VM's (the guest operating systems) which require proper IP settings. What you need to make sure is that the vmnics are connected to physical switch ports with the required settings (VLAN, tagged, untagged, ...). The vmnics only act as interconnects/uplinks to the physical world.
André
A vSwitch itself doesn't have an IP address. It's just the VMkernel port groups (e.g. for ESXi Management), and the VM's (the guest operating systems) which require proper IP settings. What you need to make sure is that the vmnics are connected to physical switch ports with the required settings (VLAN, tagged, untagged, ...). The vmnics only act as interconnects/uplinks to the physical world.
I understand that but, ¿how can I configure a vmnic to have an specific IP configuration or within an IP range? I though that was made matching them to the proper vmnets.
Depending on your needs you may want to configure the physical switch ports as tagged, or untagged ports.
In case of tagged ports (Cisco calls them trunk ports), you will then create multiple virtual machine port groups, each of them with the appropriate VLAN-ID.
This will allow you to connect each VM to the port group that's has the required VLAN-ID.
It's basically not very different from configuring switches in a physical environment.
André
It's a basic issue, before VLAN tagging and all that.
I just want to configure different IP ranges for diferent LANs for different NICs.
In order to communicate between different subnets you need to have routing in place. This can be either a virtual or a physical router.
Anyway, in order to have VMs with IP addresses in different subnets without VLANs in place, you need to have a separate vmnic connected to a physical switch. Each of these vmnics should then be assigned to a separate vSwitch with a VM port group.
André