Hello all,
I started a blog post about experimenting with netcf and configuring a guest to share the same subnet as the host. It turned into something a bit longer and more rambling of course.
* http://tofu.org/drupal/node/86
At any rate I ran into a few issues while using: virt-manager-0.8.0-7.fc12.noarch netcf-0.1.4-1.fc12.x86_64 libvirt-0.7.1-15.fc12.x86_64
= Virt-manager = I mentioned this one on the virt-tools list already. Virt-manager describes a routed network as a NAT network.
= Bridge = Another issue was an error while using virsh iface-define.
Given br0.xml: <interface type='bridge' name='br0'> <start mode='onboot'/> <protocol family='ipv4'> <ip address='10.10.10.158' prefix='24'/> <route gateway='10.10.10.254'/> </protocol> <bridge> <interface type='ethernet' name='eth0'> <mac address='00:24:E8:30:20:E7'/> </interface> </bridge> </interface>
[root@tofu2 network-scripts]# virsh iface-define br0.xml error: Failed to define interface from br0.xml error: invalid argument in virGetInterface
It did work however.
[root@tofu2 network-scripts]# cat ifcfg-eth0 DEVICE=eth0 HWADDR=00:24:E8:30:20:E7 ONBOOT=yes BRIDGE=br0 TYPE=Ethernet BOOTPROTO=dhcp PEERDNS=yes PEERROUTES=yes NAME="System eth0" UUID=5fb06bd0-0bb0-7ffb-45f1-d6edd65f3e03
[root@tofu2 network-scripts]# cat ifcfg-br0 DEVICE=br0 ONBOOT=yes TYPE=Bridge BOOTPROTO=none IPADDR=10.10.10.158 NETMASK=255.255.255.0 GATEWAY=10.10.10.254
But now eth0 is missing from iface-list
[root@tofu2 network-scripts]# virsh iface-list Name State MAC Address -------------------------------------------- lo active 00:00:00:00:00:00
Presumably, that's because from the libvirt / netcf perspective (which is just looking at the ifcfg files) I have replaced it with the br0 interface. However, br0 is not started, so presumably that's why it isn't listed either. After a 'service network restart' things look sane again.
[root@tofu2 network-scripts]# virsh iface-list Name State MAC Address -------------------------------------------- br0 active 00:24:e8:30:20:e7 lo active 00:00:00:00:00:00
= Network = And finally, after creating this bridge, it would be nice to create a network which utilizes it as follows. That fails the way I attempted to do it.
[root@tofu2 ~]# cat net-bridged.xml <network> <name>bridged</name> <forward mode='route'/> <bridge name='br0' /> </network>
[root@tofu2 ~]# virsh net-define net-bridged.xml error: Failed to define network from net-bridged.xml error: internal error Forwarding requested, but no IPv4 address/netmask provided
Presumably that's the goal of http://fedoraproject.org/wiki/Features/Shared_Network_Interface in F13.
Thanks for any comments.