Chapter 10. Pre-Red Hat Enterprise Linux 5.4 Xen networking
Below is the commented out line and the new line, containing the network-xen-multi-
bridge parameter to enable multiple network bridges.
#network-script network-bridge
network-script network-xen-multi-bridge
4.
Create a script to create multiple network bridges. This example creates a script called network-
xen-multi-bridge.sh in the /etc/xen/scripts/ directory. A sample scripts is below, this
example script will create two Xen network bridges (xenbr0 and xenbr1) one will be attached to
eth1 and the other one to eth0. If you want to create additional bridges just follow the example in
the script and copy nad paste the lines as required:
#!/bin/sh
# network-xen-multi-bridge
# Exit if anything goes wrong.
set --e
# First arg is the operation.
OP=$1
shift
script=/etc/xen/scripts/network-bridge.xen
case ${OP} in
start)
$script start vifnum=1 bridge=xenbr1 netdev=eth1
$script start vifnum=0 bridge=xenbr0 netdev=eth0
;;
stop)
$script stop vifnum=1 bridge=xenbr1 netdev=eth1
$script stop vifnum=0 bridge=xenbr0 netdev=eth0
;;
status)
$script status vifnum=1 bridge=xenbr1 netdev=eth1
$script status vifnum=0 bridge=xenbr0 netdev=eth0
;;
*)
echo -'Unknown command: -' ${OP}
echo -'Valid commands are: start, stop, status'
exit 1
esac
5.
Make the script executable.
# chmod +x -/etc/xen/scripts/network-xen-multi-bridge.sh
6.
Restart networking or restart the system to activate the bridges.
# service network restart
Multiple bridges should now be configured for guests on the Xen hypervisor.
148
Need help?
Do you have a question about the ENTERPRISE LINUX 5 - VIRTUALIZATION GUIDE and is the answer not in the manual?
Questions and answers