I've created a VLAN containing 3 ports, 1 for each VM host connection and 1 for the modem. The switch sees the MAC addresses in the VLAN for the VM and the modem. However, I cannot get the network interface on the VM to receive the IP address from my ISP.
The ultimate goal is to be able to VMotion the router VM for maintenance and failover.
Can anyone provide any insight? I search, but I apparently don't know the correct things to search for. i would think this would be a fairly common question.
Is there a router between the modem and the switch? Is the modem and the VM hosts on the same VLAN?
The router *is* the VM, so there's no router between the modem and the switch. And the port for the modem and the port carrying the VM's virtual WAN interface are both on the same VLAN. Both MACs show up in the Dynamic Address Table as being in the same VLAN I created.
For some reason, the DHCP from the VM's WAN interface isn't getting out to pick up my public IP.
If you bypass the switch does it get a DHCP address? If you set a static IP on the VM can it ping the modem? Which hypervisor are you using?
I haven't actually tried running the host's NIC to the modem. I'll go try that now and get back to you.
As for pinging the modem, I have no idea what the modem's IP address would be. To me, it's essentially just a transparent media converter from ethernet to coax. I realize there's more going on under the covers, but I have no idea.
Edit: XenServer 7.X
On most home modems the default IP is 192.168.1.100, but yours could be different.
I guess its back to the hypervisor, because it can't get an IP even putting the modem directly into that NIC.
I appreciate the second pair of eyes. Learning is what a homelab is for.
Okay, I'm back.
The modem is now connected directly to the host NIC, allowing the VM to get an IP from the ISP. However, trying to run it through the switch gets it a 169.254.X.X and notice that the WAN interface is offline.
Is it the only device on the switch? Is it on a separate vlan? How does the modem know which device to assign the ip address to?
While not the only device on the switch, the modem and the virtual NIC are the only devices in the VLAN, as planned. And nothing else is sharing this particular physical NIC on the virtualization host.
Hypervisor has four NICs:
#1 - LAN connections for all VMs on the host, including the "internal" connection for the router - switch ports in default VLAN 1
#2,#3 - for future use, perhaps as a bonded VLAN connection for storage - not even physically connected right now
#4 - Only for WAN connection for router VM - going to separate "WAN" VLAN 100 with three member switch ports. Two switch ports for hypervisor hosts and one for the modem, to allow router VM to vmotion between hypervisors and still talk to the outside world.
Oh, and then there's the iLO, of course.
Hopefully that explanation makes sense. But as I said, right now the only way the router VM gets an IP is with the modem patched directly into NIC #4.