Latest revision |
Your text |
Line 24: |
Line 24: |
|
| |
|
| * A fully updated Fedora 12 Rawhide machine. See instructions on the [[Test_Day:2009-09-17_Virtualization|main test day page]]. | | * A fully updated Fedora 12 Rawhide machine. See instructions on the [[Test_Day:2009-09-17_Virtualization|main test day page]]. |
| * For some end-to-end tests, you might want at least one guest image installed before the test day (suggested reading - [[Virtualization_Quick_Start]]), though all functionality can be fully accessed from the host running libvirtd | | * At least one guest image installed before the test day (suggested reading - [[Virtualization_Quick_Start]]) |
| * Make sure you have netcf-0.1.1; if the rawhide mirrors don't update in time, you can get a build from [http://koji.fedoraproject.org/koji/buildinfo?buildID=132324 koji]
| |
|
| |
|
| === Test Cases === | | === Test Cases === |
|
| |
|
| libvirt provides network configuration functionality through the <code>virInterface</code> API functions, and through the <code>iface-*</code> commands in <code>virsh</code>. The heavy lifting for these is actually done by a separate library, [https://fedorahosted.org/netcf/ netcf], which comes with its own command line tool <code>ncftool</code>. Basic usage of that is described [http://linux-kvm.com/content/netcf-silver-bullet-network-configuration here]
| | Things to test, roughly in dependency order: |
|
| |
|
| {{admon/note|Missing features|Currently, netcf does not support interface aliases or IPv6. Keep that in mind in the tests below}} | | {{admon/note|FIXME|List test cases for the feature.}} |
| | |
| {{admon/important|Turn off NetworkManager|Run <code>service NetworkManager stop</code> and <code>chkconfig NetworkManager off</code> prior to doing any tests}}
| |
| | |
| ==== Before you start ====
| |
| | |
| If you like your current network config, back it up:
| |
| | |
| <pre>
| |
| # nsb=/tmp/network-scripts-backup
| |
| # mkdir $nsb
| |
| # cp -p /etc/sysconfig/network-scripts/ifcfg-* $nsb
| |
| </pre>
| |
| | |
| ==== Reading manual configurations ====
| |
| | |
| If you have a machine that has been manually configured, especially when the configuration is 'interesting', try the following:
| |
| | |
| <pre>
| |
| # for iface in $(virsh iface-list --all); do
| |
| # virsh iface-dumpxml $iface > /tmp/iface-$iface.xml
| |
| # done
| |
| </pre>
| |
| | |
| or with <code>ncftool</code>
| |
| | |
| <pre>
| |
| # ncftool
| |
| ncftool> list --all
| |
| ...
| |
| ncftool> dumpxml eth0
| |
| (repeat for each listed interface)
| |
| </pre>
| |
| | |
| Inspect the XML and make sure it properly reflects the ifcfg-* files for that interface.
| |
| | |
| ===== Remove an interface =====
| |
| | |
| Remove an existing interface by issuing <code>iface-destroy</code> (if the interface is up) and then <code>iface-undefine</code> in <code>virsh</code>.
| |
| | |
| Verify that all the ifcfg-* files for that interface and all its slaves/components have been removed.
| |
| | |
| ==== Create a new interface ====
| |
| | |
| Create or redefine an interface by issuing <code>iface-define</code> in <code>virsh</code>. Verify that all the ifcfg-* files for it are written and contain what's expected. For examples of interface XML files, you can either use the ones created by <code>iface-dumpxml</code> above, or look at [http://git.fedorahosted.org/git/netcf.git?p=netcf.git;a=tree;f=tests/interface;hb=HEAD these files] for inspiration.
| |
| | |
| Bring the interface up with <code>iface-start</code> in <code>virsh</code>, and check that you have the expected network connectivity.
| |
|
| |
|
| === Issues that were identified === | | === Issues that were identified === |
|
| |
| When you file a bug report, please attach the interface XML file and all your ifcfg-* files (and, of course, anything else that seems relevant).
| |
|
| |
| It will be very valuable to know if any problem you encounter in <code>virsh</code> also happens with <code>ncftool</code>.
| |
|
| |
|
| {| border="1" | | {| border="1" |
Line 92: |
Line 41: |
| |} | | |} |
|
| |
|
| [[Category:Fedora_12_Test_Days]] | | [[Category:Test Days]] |
| [[Category:Virtualization]] | | [[Category:Virtualization]] |