Author Topic: Virtual Zen Warrior, Reflections of a noob  (Read 1264 times)

N. Balauro

  • Zen Monk
  • **
  • Posts: 63
  • Karma: +15/-0
    • View Profile
Virtual Zen Warrior, Reflections of a noob
« on: May 12, 2014, 06:03:11 pm »
This weekend was my first experiences with Xen 4.1 and my god man, what a fun use of 14hours... not to mention i destroyed a production zentyal box for its hardware! Scary stuff getting it back up before office hours monday!

Could not get zentyal to install from the iso, only base ubuntu. I credit this mostly to my complete non understanding of debootsrap.

Xen documentation is all over the dam place!!! Xen 4.1+ doesnt run the network scripts like most of the documentation talks about. All config is done via iptables and /etc/network/interfaces.

Bridging is not the end all solution for networking like the docs make u believe. Spent so long trying to track down connectivity issues, when I was bridging a dhcp address from the bridged cable modem..

Nat the external interfaces. Give the bridge a private IP. Port forward all packets on external nic. Masquerade the internal ip adresses on external nic via iptables. Add default route to domUs pointing to the bridge. - why couldnt someone point out the networking intricacies in the documentation and that bridging is basically only a good solution for internal virtualization, not on the perimeter - or for someone that has plenty of public IPs available to them.

Overall, I have learned quite alot from jumping into XenProject with no knowledge of virtualization and only very basic noob knowledge of linux/networking. I turned a xeon v3 box running zentyal only @1% sys utilization (complete waste of resources) into 3 virtual machines that still runs @1%, but get to enjoy all the benefits of a para virtualized environment!

In my opinion, virtualization of Zentyal is the way to go for any type of deployment outside of a home network perimeter box. One can separate the PDC from the rest of the services, and not to mention the benefits of all domUs being stored via LVM.
« Last Edit: May 12, 2014, 07:56:19 pm by N. Balauro »
Zentyal 3.3.10 -- Xen 4.1 Hypervisor -- Intel Xeon 1245V3

royceb

  • Guest
Re: Virtual Zen Warrior, Reflections of a noob
« Reply #1 on: May 13, 2014, 04:46:30 pm »
I do the same thing using http://www.xenserver.org/ but I've always been able to install from the ISO.  It got to the point however where I made one install from the Iso right before the Zentyal config and exported the VM as an OVA file.  Anytime I want to deploy a new setup I just load up the VM template and I am good to go.  Saves around 15 - 20 min of my time and makes for nice and easy test case uses.

aleclunsford

  • Zen Apprentice
  • *
  • Posts: 3
  • Karma: +0/-0
    • View Profile
Re: Virtual Zen Warrior, Reflections of a noob
« Reply #2 on: May 14, 2014, 04:38:39 pm »
So I have been trying to get my Proxmox network config setup correctly for a while now. Could you please share your config file?

N. Balauro

  • Zen Monk
  • **
  • Posts: 63
  • Karma: +15/-0
    • View Profile
Re: Virtual Zen Warrior, Reflections of a noob
« Reply #3 on: May 14, 2014, 06:22:46 pm »
EDIT: Proxmox is KVM based virtualization. Im using xen paravirtualization here.

I havent yet taken a look into the xen api stuff. But here is my setup in base 4.1:

In dom0: edit /etc/network/interfaces. Set eth0 to manual. Define a bridge (eg. xenbr0). Set the bridge to static. Define its ip, netmask, etc. Edit /etc/sysctl.conf so port forwarding is True; net.ipv4.ip_forward = 1. Enable forwarding and nat in iptables:

     iptables -A FORWARD --in-interface xenbr0 -j ACCEPT
     iptables --table nat -A POSTROUTING --out-interface eth0 -j MASQUERADE

Im not sure how proxmox handles domU config, but in XenProject you can define the settings in /etc/xen/nameofdomain.cfg.

Also, you can just start the domU and edit the /interfaces. Define a static ip and a gateway pointing to the xenbr0 address.
« Last Edit: May 14, 2014, 09:24:21 pm by N. Balauro »
Zentyal 3.3.10 -- Xen 4.1 Hypervisor -- Intel Xeon 1245V3

half_life

  • Bug Hunter
  • Zen Hero
  • *****
  • Posts: 867
  • Karma: +59/-0
    • View Profile
Re: Virtual Zen Warrior, Reflections of a noob
« Reply #4 on: May 17, 2014, 04:46:03 pm »
So I have been trying to get my Proxmox network config setup correctly for a while now. Could you please share your config file?

Sorry I missed this earlier. (I have been busy house shopping)   take a look at this : https://forum.zentyal.org/index.php/topic,18938.msg82302.html#msg82302