18.17. Configurações de Laptop
The task of configuring your RHEL 5.1 loaded laptop for use on a network environment, presents a number of potential challenges. Most WiFi and wired connections switch constantly during any given day, and Red Hat Virtualization assumes it has access to the same interface consistently. This results in the system performing ifup/ifdown calls to the network interface in use by Red Hat Virtualization. WiFi cards are not the ideal network connection method since Red Hat Virtualization uses the default network interface.
The idea here is to create a 'dummy' network interface for Red Hat Virtualization to use.
This technique allows you to use a hidden IP address space for your guests and Virtual Machines. To do this operation successfully, you must use static IP addresses as DHCP does not listen for IP addresses on the dummy network. You also must configure NAT/IP masquerading to enable network access for your guests and Virtual Machines. You should attach a static IP when you create the 'dummy' network interface.
Para este exemplo, a interface é chamada de fictícia0 e o IP usado é 10.1.1. O script é chamado de
ifcfg-dummy0
e se encontra no diretório /etc/sysconfig/network-scripts/
:
Você deve vincular o
xenbr0
ao dummy0
para habilitar a conexão de rede até quando estiver disconectado da rede física.
You will need to make additional modifications to the
xend-config.sxp
file. You must locate the ( network-script 'network-bridge' bridge=xenbr0
) section and add include this in the end of the line:
netdev=dummy0
netdev=dummy0
You must also make some modifications to your guest's domU networking configuration to enable the default gateway to point to dummy0. You must edit the DomU 'network' file that resides in the
/etc/sysconfig/
directory to reflect the example below:
É recomendável que se habilite o NAT no domínio0, assim o domU pode acessar a rede pública. Dessa forma, até mesmo os usuários wireless podem solucionar as limitações wireless da Tecnologia de Virtualização Red Hat. Para fazer isso, você deve modificar o arquivo
S99XenLaptopNAT
que se encontra no diretório /etc/rc3.d
para refletir o exemplo abaixo:
Se você quiser automatizar a configuração de rede em tempo de inicialização, você deve criar um softlink para
/etc/rc3.d/S99XenLaptopNAT
Ao modificar o arquivo
modprobe.conf
, você deve incluir estas linhas:
alias dummy0 dummy options dummy numdummies=1
alias dummy0 dummy
options dummy numdummies=1