Deepti B Kalakeri wrote:
Kaitlin Rupert wrote:
> # HG changeset patch
> # User Kaitlin Rupert <karupert(a)us.ibm.com>
> # Date 1251842877 25200
> # Node ID 03e78e8b7a06296eba99e1329840ae6ee521f357
> # Parent a0185245b9894f195227c12af621151623972573
> [TEST] Fix VSMS to do a proper check of ref config, also remove
> test_xml import
>
> This test was originally designed to do the following:
>
> 1) Create a guest with a MAC interface
> 2) Create a second guest based on the first guest - second guest has an
> additional MAC defined. Pass a reference to the first guest during
> the
> DefineSystem()
> 3) Verify the second guest was created with two MACs - one that is
> identical to
> the first guest and one that is different
>
> The providers no longer allow a guest to have the same MAC as an
> existing guest.
> Each MAC needs to be unique. Therefore, this test needs to use a
> different
> setting - disk source works for this.
>
> Also, remove the dependency on test_xml.py - that module is not obsolete.
>
The test case seems to be adding 2 MAC's as well to the second domain.
See the xml below obtained from the debug message:
<interface type="network">
<mac address="00:16:3e:e1:17:be"/>
<source network="cimtest-networkpool"/>
</interface>
<interface type="network">
<mac address="00:16:3e:a6:d5:cd"/>
<source network="cimtest-networkpool"/>
</interface>
The MAC in the above XML shows that its generated by the libvirt-CIM
provider as it has prefix "00:16:3e".
I think we get two MAC's as the referenced domain was passed to
DefineSystem() would also have a interface information ?
The debug messages do not directly imply how this might be getting added.
Probably we can include more debug statements going further in the
libvirt-cim provider.
I think we should not be adding 2 net interface when we are not asking
for it.
Right, that's correct. This is the intended behavior. If you pass a a
value for the ReferencedConfiguration parameter, DefineSystem() will use
that guest as a basis for the new guest. If you look at the RASDs we
pass in the test case, you'll see that the test case specifies a NetRASD
(see the array of RASDs we pass below).
Since the guest we specified for the ReferencedConfiguration already had
a network interface, the NetRASD we specified adds an additional network
interface to the guest. So the test case is really asking for two
interfaces. This was the original purpose of the test.
['instance of KVM_DiskResourceAllocationSettingData {\n\tPoolID =
"DiskPool/cimtest-diskpool";\n\tVirtualDevice = "hda";\n\tResourceType
=
17;\n\tAddress = "/tmp/default-kvm-dimage.2ND";\n\tVirtualQuantityUnits
= "count";\n\tInstanceID = "Default";\n\tEmulatedType =
0;\n\tVirtualQuantity = 4096;\n\tVirtualDevice = "hdb";\n};\n',
'instance of KVM_ProcResourceAllocationSettingData {\nResourceType =
3;\nVirtualQuantity = 1;\nInstanceID = "rstest_domain2/proc";\n};',
'instance of KVM_NetResourceAllocationSettingData {\nResourceType =
10;\nNetworkType = "network";\nPoolID =
"NetworkPool/cimtest-networkpool";\n};']
--
Kaitlin Rupert
IBM Linux Technology Center
kaitlin(a)linux.vnet.ibm.com