i setup a Ubuntu server 16.04 and installed KVM/QEMU on it. I set static ip 192.168.1.10 for host machine and i want to have a static ip set on the virtual quest machine aswell (192.168.1.20), i know i need to setup a bridged network device, but all the guides i found use DHCP for host machine and static/dhcp for host.
i tried setting it up like this on host machine:
auto lo
iface lo inet loopback
# The primary network interface
auto eno1
iface eth0 inet static
address 192.168.1.10
netmask 255.255.255.0
network 192.168.1.0
broadcast 192.168.1.1
gateway 192.168.1.255
dns-nameservers 8.8.8.8 8.8.4.4
auto br0
iface br0 inet static
address 192.168.1.20
network 192.168.1.0
netmask 255.255.255.0
broadcast 192.168.1.255
gateway 192.168.1.1
dns-nameservers 8.8.8.8 8.8.4.4
bridge_ports eno1
bridge_fd 9
bridge_hello 0
bridge_maxage 0
bridge_stp off
And on guest machine:
auto br0
iface br0 inet static
address 192.168.1.20
network 192.168.1.0
netmask 255.255.255.0
broadcast 192.168.1.255
gateway 192.168.1.1
dns-nameservers 8.8.8.8 8.8.4.4
But this setup does not work. infact i lost all connectivity to both machines with this. What could be the problem?
Connection worked fine on host machine, till i added the bridge adapter.