The guest domains we create need to connect with each other and the outside world. Xen provides a couple of different networking options as follows:
- Bridged networking
- Routed networking
- Virtual Local Area Network (VLAN) with Network Address Translation (NAT)
It is possible to do more advanced networking configurations with Xen
Bridged Networking
Bridging is a technique used for connecting different network segments. It is the default option for Xen networking as it simply connects all the virtual machines to the outside world through virtual network interfaces connected to the bridges created by Xen. Bridges connect two LANs (local area networks) together and forward frames using their MAC (media access control) address. They thus operate at the lowest level of the network layer and are completely unaware of something like an IP. The following diagram depicts a simple network bridge.
A network bridge is primarily utilized to connect multiple network segments by using the MAC addresses for addressing. It uses broadcasting to locate devices that are not known to it. Once the devices have been located, their MAC addresses are stored in a bridge table, which is the first place checked when a new packet frame comes in.
The above diagram shows the network configuration with the various interfaces created and the connections to the bridge when xend is started and only dom0
is running.
Routed Networking
Routing is a technique that uses IP forwarding to relay network traffic from one segment to another. In this case, dom0 in Xen acts as a conduit for the guest domains to communicate with the outside world. All network traffic sent to and received by the guest domains goes through and is forwarded by dom0. Routing uses the IP addresses to figure out where to send the network packets.
Routing acts at a higher level than the bridging technique, which only looked at the MAC address to find out the destination. Routing and bridging accomplish the same task, but use different methods to move information from source to destination. IP forwarding relays packets from one network segment to another if the proper routing entries exist in the routing table. In this case we are using unicast, which relays a packet from one link to another along a chain that connects the packet from source to destination.
Virtual Local Area Network (VLAN) with Network Address Translation (NAT)
In this section we are going to set up a Xen networking configuration that has a dom0 with a public IP address that acts as a router to a VLAN by using NAT. The VLAN can have any number of virtual machines, all of which will use a new network interface that is connected to the bridge. In the previous chapter each of our virtual machines had a separate public IP address assigned to it that made things easier. However in this section, we will use a single IP address and still provide
the ability to connect to any port on a virtual machine on our VLAN by using address translation.



No comments:
Post a Comment
Note: Only a member of this blog may post a comment.