Dear Gene,
Thank you for your response.
I want to assign a static IP address to my container, I wonder if I can achieve this by
editing the container's /etc/sysconfig/network-scripts/ifcfg-eth0. I tried this, but
failed, and eth0 is always not assigned an IP address automatically (my host and guest are
fedora19).
Am I missing something? I don't know much about the booting procedure of a container,
and how the network NIC is configured during the booting.
The content of container's /etc/sysconfig/network-scripts/ifcfg-eth0 is as follows:
BOOTPROTO="static"
DEVICE="eth0"
TYPE="Ethernet"
ONBOOT="yes"
IPADDR=192.168.128.15
PREFIX=24
GATEWAY=192.168.128.254
With my warmest regards,
Cheng
Dear all,
I want to run a TCP/IP application automatically after I start the
container using "virsh -c lxc:/// start mycontainer". Does
anybody
know how to configure the NIC automatically with an assigned IP
address? I couldn't find useful information from domain XML
format
spec and it only talks how to set the mac address
Your response will be highly appreciated.
Cheng
Take a look at:
http://sandbox.libvirt.org/networking/
Note: Specifying dhcp does not currently work. I have created a patch to fix that. See:
https://bugzilla.redhat.com/show_bug.cgi?id=1133686