From Fedora Project Wiki

Warning: You are not logged in. Your IP address will be publicly visible if you make any edits. If you log in or create an account, your edits will be attributed to your username, along with other benefits.

The edit can be undone. Please check the comparison below to verify that this is what you want to do, and then publish the changes below to finish undoing the edit.

Latest revision Your text
Line 15: Line 15:
=== Who's available ===
=== Who's available ===


[[User:Lutter|David Lutterkort]] is your host for today. IRC nick 'lutter'; I am on the West Coast in the US (UTC-7 right now)
[[User:Lutter|David Lutterkort]] is your host for today.


The following people have also agreed to be available for testing, workarounds, bug fixes, and general discussion:
The following people have also agreed to be available for testing, workarounds, bug fixes, and general discussion:


* [[User:laine|Laine Stump]] will try to be around on IRC (as 'laino')
* ''add your name here''


=== What's needed to test ===
=== What's needed to test ===


* 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]]
Please note that all contributions to Fedora Project Wiki are considered to be released under the Attribution-Share Alike 4.0 International (see Fedora Project Wiki:Copyrights for details). If you do not want your writing to be edited mercilessly and redistributed at will, then do not submit it here.
You are also promising us that you wrote this yourself, or copied it from a public domain or similar free resource. Do not submit copyrighted work without permission!

To edit this page, please solve the following task below and enter the answer in the box (more info):

Cancel Editing help (opens in new window)