VM won't show up on router
Posted: 21. Jun 2011, 00:47
I'm running a Ubuntu 10.10 guest on a Windows 7 host with a bridged network adapter (WiFi). The router I'm using is a 2Wire 2701HG-G with DHCP enabled.
At first, I used to let the VM get its IP address from the router using DHCP. The problem with this was that after a while, the VM started using the host's IP address instead of the one it was originally assigned, thereby disconnecting the host from the network. I fixed this by modifying the guest's /etc/network/interfaces file and forcing it to use a static IP instead.
Although it's working just fine at the moment, it still isn't perfect. The problem now is that when I start the VM, it shows up on the router's list of active devices for an instant, after which it disappears even though it's still up. When the router sees it as inactive for more than a couple of hours, it reassigns the VM's IP back to the pool, even though the VM is still connected and accessible. As a result, it'll run just fine until another device connects to the network and is assigned the VM's IP address, which the router thinks is no longer in use.
Why does the VM only appear on the list for a brief moment after startup? Also, I'm guessing there's no way I can allow the guest to use DHCP without running into the same problem of it snatching the host's IP after a while.
At first, I used to let the VM get its IP address from the router using DHCP. The problem with this was that after a while, the VM started using the host's IP address instead of the one it was originally assigned, thereby disconnecting the host from the network. I fixed this by modifying the guest's /etc/network/interfaces file and forcing it to use a static IP instead.
Although it's working just fine at the moment, it still isn't perfect. The problem now is that when I start the VM, it shows up on the router's list of active devices for an instant, after which it disappears even though it's still up. When the router sees it as inactive for more than a couple of hours, it reassigns the VM's IP back to the pool, even though the VM is still connected and accessible. As a result, it'll run just fine until another device connects to the network and is assigned the VM's IP address, which the router thinks is no longer in use.
Why does the VM only appear on the list for a brief moment after startup? Also, I'm guessing there's no way I can allow the guest to use DHCP without running into the same problem of it snatching the host's IP after a while.