Author Topic: Zentyal: NO NETWORK TO KVM VIRTUAL MACHNES POSSIBLE AT all  (Read 10591 times)

thorsten

  • Guest
Zentyal: NO NETWORK TO KVM VIRTUAL MACHNES POSSIBLE AT all
« on: December 11, 2011, 03:22:28 pm »
Hi everybody,

I am very sorry to write this, but:

I tried everything that is possible to a non LINUX Provessional with limited command line knowledge:

On Zentyal it is not possible to create a Virtual Machine with KVM using a bridged or routed Network. I made NAT work, but this is volotile (I need to configure after every reboot / saving of modules in Zentayl). I tried EVERY possible decision on the following tree:

Using Zentyal internal virtual machine module or manual installation of libvirt-bin, virt-manager and qemu-kvm independend and in conjunction n=3
Using Bridged from Zentyal network, edition of /etc/network/interfaces or using brctl, m=3
Trying each combination for NAT, Routed and Bridged, typically I added three network adapters to an existion virtual machine (each one enabled independently) o=3
Trying of course several network adapters for the virtual machines, typically NE2K_pci, RT8139, Hypervisor default, p=3

I tried off course several DHCP options on an internal and an external DHCP server, q=2.

I tried it systematically, each tree step was combined with every other from a paper matrix and each trail got a clean installation: I made more than 15 clean installations of Zentyal during working on this issue. Many due to the DCHP was killed an a module start was not possible anymore.

So, I do not know what to do.

here is my config:
Intel S5000PSL server board, 64 bit clean installation of Zentyal with two NICs

Can someone who is using Zentyal with KVM and Virt-Manager describe, what he / she has done to make it run .... I am tied to Routed or Bridged network as I do need to connect at least one VM from outside.

Thank you in advnace

robb

  • Guest
Re: Zentyal: NO NETWORK TO KVM VIRTUAL MACHNES POSSIBLE AT all
« Reply #1 on: December 11, 2011, 05:06:03 pm »
I don't know how zentyal virtual environment is implemented, but can you check if bridge-utils is installed? According to ubuntu help on KVM networking this is a requirement.
https://help.ubuntu.com/community/KVM/Networking#Creating_a_network_bridge_on_the_host

maybe a dev can shed some light on this?
« Last Edit: December 11, 2011, 05:07:39 pm by robb »

thorsten

  • Guest
Re: Zentyal: NO NETWORK TO KVM VIRTUAL MACHNES POSSIBLE AT all
« Reply #2 on: December 11, 2011, 08:15:18 pm »
Hi Robb,

of course the bridge utils are installed. By the way, from the troubleshooting section lower on the link I found how to make NAT temporay work:

Virsh net-destroy xyz and Virsh net-start xyz - but this does work only just until the next "saving process" from zentyal and / or system reboot: The required IP table roules seem to be volotile and are overwriten by Zentyal. Additionally (Just on the same howto), It is necessary to delete the default usermode login from Virt-Manager and to create a new one. This is required in order to make shure that the Zentyal Admin Account user is member of the group "KVM" and "Libvirtd" - this was not the case when the Zentyal VM Machine Module was installed.

Best regards
Thorsten


zephyrnet

  • Zen Apprentice
  • *
  • Posts: 21
  • Karma: +1/-2
    • View Profile
Re: Zentyal: NO NETWORK TO KVM VIRTUAL MACHNES POSSIBLE AT all
« Reply #3 on: January 10, 2012, 04:24:00 pm »
Hi Thorsten,

Did you get anywhere with this ?

I had exactly the same problem.

tfenasse

  • Zen Apprentice
  • *
  • Posts: 5
  • Karma: +0/-0
    • View Profile
Re: Zentyal: NO NETWORK TO KVM VIRTUAL MACHNES POSSIBLE AT all
« Reply #4 on: February 08, 2012, 09:31:57 am »

Hello,

I've a Zentyal 2.2.5 freshly installed with the Virtual Manager module and I cannot use network on the virtual machines.
The NAT, Bridged or Internal are "Bridged to no interface".  I see this in the web admin tool of zentyal.  The column "Bridged to" is always filed with the value "none".

For instance if I chose "Bridge Type" the "Bridge To" drop down list is empty.  There is only "none" in the list and if I apply this selection I have this error in the zentyal.log.

Quote
Exit value: 1
2012/02/08 09:21:37 ERROR> GlobalImpl.pm:612 EBox::GlobalImpl::__ANON__ - Failed to save changes in module virt: root command /var/lib/zentyal/machines/Bonjour/manage.sh start failed.
Error output: error: Failed to create domain from /var/lib/zentyal/machines/Bonjour/domain.xml
 error: Failed to add tap interface to bridge 'none': No such device

If I chose "NAT", I do not have the error message but my virtual machine have no network interface.

What can I do to "add an interface into the drop down list of the virtual manager"? Sorry but I'm quite a noob.
The network is working on the zentyal host and there are 2 Ethernet controller: Broadcom Corporation NetXtreme BCM5714 Gigabit Ethernet (rev a3).  I use only one.

Thanks for any advises, clues, or whateveri

AlpineSkate

  • Zen Apprentice
  • *
  • Posts: 3
  • Karma: +0/-0
    • View Profile
Re: Zentyal: NO NETWORK TO KVM VIRTUAL MACHNES POSSIBLE AT all
« Reply #5 on: February 09, 2012, 06:34:33 pm »
Aaaaaaagggh! Just wrote an explanation, hit preview and was told I've been timed out. I'll write my explanation all over again and post it here later. I have bridging working and am running 2 guest systems Debian and Centos but reckon I have found a bug.

AlpineSkate

  • Zen Apprentice
  • *
  • Posts: 3
  • Karma: +0/-0
    • View Profile
Re: Zentyal: NO NETWORK TO KVM VIRTUAL MACHNES POSSIBLE AT all
« Reply #6 on: February 09, 2012, 07:22:00 pm »
I think the missing network is a bug and I think it's because of multiple NICs.

The Problem:

When I create a guest VM using my bridge br1 I see in /var/lib/zentyal/machines/GuestOS-name/domain.xml

<interface type='bridge'>
   <source bridge='br1'/>
</interface>

and not a br1 interface with a mac address

<interface type='bridge'>
   <source bridge='br1'/>
   <mac address='52:54:00:05:47:c0'/>
</interface>

This mean that the guest OS starts up everytime with a different MAC address after a KVM restart, physical machine reboot, or guest OS config changes and this plays havoc with /etc/udev/rules.d/70-persistent-net.rules on my guest Linux OS's (Debian and Centos).

The quick fix (which does not survive a KVM restart, physical machine reboot, or guest OS config change)

1. Put the virtual mac address (my example is fine) into your /var/lib/zentyal/machines/GuestOS-name/domain.xml
2. Edit /etc/udev/rules.d/70-persistent-net.rules on the Guest OS as follows - delete all lines below the comments and then add:

SUBSYSTEM=="net", ACTION=="add", DRIVERS=="?*", ATTR{address}=="52:54:00:05:47:c0", ATTR{dev_id}=="0x0", ATTR{type}=="1", KERNEL=="eth*", NAME="eth0"

Ensure that the mac address that you entered in "/var/lib/zentyal/machines/GuestOS-name/domain.xml" matches the "ATTR{address}=="

If your /etc/network/interfaces (Debian/Ubuntu) or /etc/sysconfig/network-scripts/ifcfg-eth0 are set up correctly then after a reboot of the Guest OS (NOTE: the Guest OS and not the physical Zentyal machine) you should have a working network

Because your changes will be lost after a physical machine reboot, a KVM restart, or a Guest OS config change I keep a copy of /var/lib/zentyal/machines/GuestOS-name/domain.xml. After each physical machine reboot, KVM restart, I can always restore the original /var/lib/zentyal/machines/GuestOS-name/domain.xml. Make sure you don't have "Autostart" set otherwise after a reboot/KVM restart you'll have a messed up /etc/udev/rules.d/70-persistent-net.rules on your Guest OS (On the other hand, try it and take a look at what happens. You can always correct and restart the Guest OS).

Another tip: Use "ifconfig -a" on your Guest OS to see the presence of your virtual ethx and not just "ifconfig"

It's not an ideal solution but I've proved bridging works. Hopefully I'm right that it is a Zentyal bug that will be fixed in the near future.

I spent many hours getting things to work

AlpineSkate

  • Zen Apprentice
  • *
  • Posts: 3
  • Karma: +0/-0
    • View Profile
Re: Zentyal: NO NETWORK TO KVM VIRTUAL MACHNES POSSIBLE AT all
« Reply #7 on: February 09, 2012, 07:31:46 pm »
tfenasse - you have a different problem to what I just explained. You are just struggling to set up a bridge which I must admit threw me for a while.

If I remember correctly you have to choose the ethernet card and select new bridge and then change. What I wasn't noticing was that on the tabs at the top suddenly a new tab called br1 appeared.

I'm not 100% sure that my explanation is correct and I don't want to mess up my current configuration checking this out. Anyhow, I can assure you it works once you figure it out :-)

Unfortunately, probably like you, I had problems with the documentation. Nevertheless Zentyal strikes me as a great product.

Zetto

  • Zen Apprentice
  • *
  • Posts: 7
  • Karma: +1/-0
    • View Profile
Re: Zentyal: NO NETWORK TO KVM VIRTUAL MACHNES POSSIBLE AT all
« Reply #8 on: April 04, 2013, 05:27:32 pm »
Anyone have any further progress or ideas on this subject? Having the exact same issues.

Zetto

  • Zen Apprentice
  • *
  • Posts: 7
  • Karma: +1/-0
    • View Profile
Re: Zentyal: NO NETWORK TO KVM VIRTUAL MACHNES POSSIBLE AT all
« Reply #9 on: April 04, 2013, 05:59:20 pm »
An update to my earlier question I figured out something that worked for me. I ended up being forced to use a static on my bridged network adapter. DHCP would not work regardless of having the right IP or not. If anyone else has this issue try to assign your primary adapter to a bridged connection and set your bridge to static. Then apply the bridged connection to your VM.