From: Thierry Parmentelat Date: Fri, 18 Jan 2008 16:16:52 +0000 (+0000) Subject: script to configure the tun/tap network device used by qemu X-Git-Tag: 2008-02-11-last-vmware-support~148 X-Git-Url: http://git.onelab.eu/?a=commitdiff_plain;h=ad9a26586f6321fdb28fca5d5ca0b0490c13bb9f;p=tests.git script to configure the tun/tap network device used by qemu --- diff --git a/system/qemu-ifup b/system/qemu-ifup new file mode 100755 index 0000000..b14f2f3 --- /dev/null +++ b/system/qemu-ifup @@ -0,0 +1,19 @@ +#!/bin/bash + +# Mise en place d'un environnement d'exécution d'une machine +# virtuelle sous QEMU pour partage de la connexion réseau +# avec une une machine hôte sous FC6. + +INTERFACE_LAN=eth0 +INTERFACE_BRIDGE=br0 + +echo "Configure $1 interface..." +echo "Activating link for $1..." +/sbin/ip link set $1 up +sleep 1 +echo "Configure $INTERFACE_BRIDGE bridge..." +/usr/sbin/brctl addif $INTERFACE_BRIDGE $1 +echo "Activating promiscuous mode on $1 ..." +/sbin/ifconfig $1 0.0.0.0 promisc up +sleep 1 +echo "Done."