1

I have a kvm/qemu/libvirt host with several VMs running happily on br0 with IP addresses that are in the same network as the host they run inside, 192.168.10.0/24.

So I'm playing with CoreOS and following their cluster guide Running CoreOS on libvirt as closely as possible. When I attempt to user their deploy_coreos_libvirt.sh script, it can't find the virtual network "default." Indeed there is no virtual network defined according to virsh net-list. My Ubuntu 14.04.4 host has no example network/default.xml file but my CentOS 7 kvm host does. Again, both machines have no virtual networks defined. Below is the example network/default.xml from CentOS 7.

<network>
  <name>default</name>
  <bridge name="virbr0"/>
  <forward/>
  <ip address="192.168.122.1" netmask="255.255.255.0">
    <dhcp>
      <range start="192.168.122.2" end="192.168.122.254"/>
    </dhcp>
  </ip>
</network>

So if my physical lab network is 192.168.10.0/24, what network should I use for my virtual network? The user_data example on the CoreOS page has "Network": "10.1.0.0/16". Should I use that in the virtual network config?

0

I defined a new virtual network from this xml

<network>
  <name>default</name>
  <bridge name="br1"/>
  <forward/>
  <ip address="192.168.11.1" netmask="255.255.255.0">
    <dhcp>
      <range start="192.168.11.2" end="192.168.11.254"/>
    </dhcp>
  </ip>
</network>

Once I defined br1 (net-define) and activated it (net-start), deploy_coreos_libvirt.sh had no problem building me three new CoreOS VMs. Had to use arp -a to figure out their IP addresses, but that was no biggie. Would be nice if there was a virsh command that would do that.

I can get in and out of these new VMs as easily as if they were on my LAN's native network. Nice.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.