Mirantis have recently published a fuel plugin for XenServer, so you can easily use provided the hypervisor of the world's largest with OpenStack cloud. Integration with Mirantis OpenStack makes the entire insert straight forward -., As soon as the physical crosslinking is defined
The networking topology is often cited as one of the most complicated things to set in OpenStack, especially if you do not have the control of the switch or a lengthy approval process have with IT - ironically one of the things to facilitate the IaaS solutions! This is where the power of Software-Defined Networking (SDN) comes into play.
When OpenStack cloud with XenServer for networking is completely abstracted from the Compute VMs and the instances. That is, you can use XenServer to manipulate the network mapping between physical devices and what OpenStack expects the network to be. In fact, XenCenter, Windows GUI of XenServer, makes it possible to create networks, based on VLAN tags and give them descriptive names and other metadata -. But there are a lot more power under the hood available
If you combine this flexible device with Mirantis OpenStack is easy to use interface and powerful network test steps, you can easily define almost any setup your OpenStack environment with XenServer.
The following describes how to set up everything. It has been tested with Mirantis OpenStack 6.1 to XenServer 6.5 SP1 and the corresponding XenServer fuel Plugin.
initial
The XenServer Integration with OpenStack has some optimizations, which means that only EXT3 memory is supported. Make sure you select optimized for XenDesktop when prompted during installation of XenServer. Use XenCenter to examine whether the SR-type EXT3 as required to create the VMs fixing delete the VMs and start again.
The XenServer fuel plugin for Mirantis OpenStack 6.1 currently supports only nova network, so we'll use the FlatDHCPManager Setup. In the Mirantis OpenStack interface you can define strong separation between networks by using separate physical networks or the definition of VLANs. While using these VLANs, means the flexibility of abstracted network with XenServer, you do not - simply add another private network and the VMs the OpenStack services are performed simply as a real physical interface see
for this single server deployment, define three private networks in XenCenter:
- 'pxe': Mirantis OpenStack used bare-metal operating system deployment to install, and then loads the OpenStack packages for you. As such, we need this to run in an isolated network
- 'private'. All flow from the OpenStack management traffic on this network ( "Management" and "Storage" will be separated from VLANs), and the network again to use it also in the public network of OpenStack service node and the floating IP used address space hosts
- 'BR100'. This specially named bridge is hardcoded by Mirantis OpenStack as a bridge that will be added to virtual machines when they launch. It will therefore be the way where the traffic flows into and out of the VM.
To Mirantis OpenStack Web UI we use from the outside world access to the need, so we assume there is a network in conjunction with eth0 on the XenServer host that we "external".
Virtual Machine Setup
callThis single-host deployment of VMs to create the infrastructure used. Make sure when you set up the VMs that it all with the 'Other installation media' are original and that they. At least 4 GB of RAM and 50 GB of storage You do not, although a start of VMs! Create three VMs:
- Fuel: Used to host Mirantis OpenStack. Add two networks 'pxe' (must eth0) and "external"
- Compute. Used to host the Nova compute and Cinder services. In three networks 'pxe', 'private', 'BR100'. Make sure that this VM to boot from the network
- Controller :. All other in OpenStack services host (for views, KEYSTONE). In three networks 'pxe', 'private', 'BR100'. Make sure that this VM to boot from the network.
Once the Compute VM is set up, we need to add another network. The XenServer Integration with OpenStack requires that the Compute VMs on the XenServer host stated that they are providing instances. You also need access to XAPI that (unless you are in the control domain Dom0) can only be accessed via a network connection. We add provided a XenCenter Plugin easy to make a separate management network. Source code and compilation instructions for this are available on Github. Simply install the plugin, restart XenCenter, right-click the VM Compute and add the internal management network. This network is a link-local network, the Compute VM XAPI and providing our VMs.
first external access
can speak As already mentioned, Mirantis OpenStack includes a very useful network validation tool. One thing it is verified that the OpenStack service VMs must have access to the outside world (especially the Ubuntu repositories). We have the "private" network created these service VMs at home, and clearly do not have access! Fortunately, as XenServer is based on a standard Linux distribution in order to modify the network to the XenServer host act as a gateway is straightforward.
The cross-Pool private network setup in one of my other blog posts showing how to create a private network and use udev a temporary GRE tunnel between two private networks to set up on different hosts, and explains why we must use udev trigger the network device. Some of the same principles are needed in this blog, but for Mirantis OpenStack we need access from the private network to the outside world to provide
The following code snippet is.
- create a script is executed by udev when XAPI created a new network
- Add an IP address to this bridge, which will be the gateway IP address
- a route Add as Dom0 know where to send determines packets for the IP address on the "private" network
- Add network address translation services to create a iptables MASQUERADE rule to any traffic at Sending the gateway
- share on the host IP forwarding.
echo SUBSYSTEM == "net" ACTION == "* xapi" + RUN KERNEL == "add" = "/ etc / udev / scripts / new gateway. sh ''> /etc/udev/rules.d/0-gateway.rules
bridge = $ (xe network-list name-label = private params = bridge minimal = true)
cat> / etc / udev / scripts / recreate-gateway.sh << RECREATE_GATEWAY
#! / bin / bash
sleep 5s
if / sbin / ip link show $ bridge> / dev / null 2> & 1 !; then
if (/ sbin / ip addr show $ bridge | / bin / grep -q 172.16.1.1!); then
/ sbin / ip addr add dev $ bridge 172.16.1.1
fi
if (/ sbin / route -n | / bin / grep -q 172.16.1.0!); then
/ sbin / route add -net 172.16.1.0 netmask 255.255.255.0 dev $ bridge
fi
if (/ sbin / iptables -t nat -S |! / bin / grep -q 172.16.1.0 / 24); then
/ sbin / iptables -t nat -A POSTROUTING -s 172.16.1.0/24! -d 172.16.1.0/24 -j MASQUERADE
fi
fi
RECREATE_GATEWAY
chmod + x /etc/udev/scripts/recreate-gateway.sh
sed -i -e 's /net.ipv4.ip_forward.*/net.ipv4.ip_forward = 1 / '/etc/sysctl.conf
Start the XenServer hosts, and then the udev rules and sysctl config enabled. If we define the networks in Mirantis OpenStack we will use this area for the "public" network.
Fuel providing
The Fuel Installation is simple. Download the ISO of Mirantis (although, as this guide for Mirantis OpenStack posted 6.1 make sure you click "Download Previous Versions" as was 7.0 launched recently), insert it into XenServer virtual CD-ROM for fuel VM and boat. If the fuel setup menu appears, we always allow eth1 (the "external" to the network) using DHCP, so you can access the fuel Web interface directly.
Once fuel is installed, you must install the XenServer plugin. Download this from the fuel plugins catalog Fuel VM and install with
Fuel plugins --install fuel plugin XenServer 1.0-1.0.1-1.noarch.rpm
Finally, start the Compute and controller VMs on. These have the 'pxe' network as the first Ethernet device, and are configured to boot from the network, so Mirantis OpenStack will discover the VMs and register it, be ready to be used.
Now everything is set up, it is really easy to create your XenServer-based OpenStack environment.
to create the environment
Environment creation wizard 'Mirantis select the "Juno + Citrix XenServer on Ubuntu 14.04.1" OpenStack release, then click through the wizard break up.
on the Settings page, make sure that the XenServer plugin is enabled, and set the password for the host XenServer, then let us say Mirantis OpenStack as the networks are established.
the Nodes tab to go back, add them to the controller and compute nodes (check they reported the MAC addresses with the MAC addresses of the VM from XenCenter and rename the node in the user interface to it easier to do) and then configure a selection at a time, and interfaces. It can not be configured together as they (has the Compute VM additional host internal management network) for the two different networks visible, but the network layout will have to be identical: eth0 is the Admin (PXE) interface, eth2 is the (fixed) VM and eth1 is anything (Public, storage and management).
on the Networks tab set the settings Public IP 172.16.1.1 to use as a gateway, an IP range of 172.16.1.2-172.16.1.100 and a floating IP range of 172.16.1.101-172.16.1.0. Storage and management networks should have (each VLAN, as they are on the isolated "private" network) set a VLAN and the fixed network should not on a VLAN (because it 'used BR100' the isolated network).
Check the network settings and should Mirantis OpenStack report that the review succeeded and that the network is configured correctly.
Click access to the magic "Deploying Changes' button, a cup of coffee, and watch as your XenServer + OpenStack environment is created before your eyes.
Behind the scenes pretty much is going on. Mirantis OpenStack is installing Ubuntu on the service VMs, then install OpenStack. the XenServer plugin is configured to work with XenServer and installation of critical OpenStack XAPI plugins on the XenServer host. Finally, the images used for VMs to implement (a testvm called Cirros and a larger Fedora image for heat tests used) are installed.
As we have to be Fuel "public" IP address, on the 'private' network, will have access to them need in a tunnel or port forwarding I tend to use an SSH tunnel.
ssh root @ xenserver -L 80: 172.16.1.2: 80
Then is your OpenStack Horizon can be accessed with a web browser pointed to http: // localhost :. 80
Alternatively the XenServer host as a gateway to recreate gateway script to set up a route to go through the XenServer host to the "private" network and establish expand and use the same NAT technology access to the 172.16.1 area to allow your computer.
Final Thoughts
to define the networks for OpenStack the use of XenServer, actually gives you a lot more flexibility than this. Even in private networks, you can define links between them, the VLAN tag, and the ability to VLANs. If you wanted to be on a VLAN as BR100, then it would not need to be added to the compute or controller node as a separate network. A patch port can be added to connect with a VLAN tag, a local BR100 for "private" network and add one day traffic from a VM that touches the net.
and as a final thought, why this approach does not combine with the cross-pool private network setup to isolated to test a multi-host OpenStack setup without you for the central IT department for the provision need to maintain the networks today need!
0 Komentar