Francesco Romani has uploaded a new change for review.
Change subject: vmstats: user proper way to detect host devices ......................................................................
vmstats: user proper way to detect host devices
Lacking better ways, back in time we detected host devices checking their name (!). Now we the code is evolved and we have proper and safer way to do the same task, so this patch updates the vmstats code accordingly.
Change-Id: Ic71db639b980dbdf29284c432f4acda95b402c4f Signed-off-by: Francesco Romani fromani@redhat.com --- M lib/vdsm/virt/vmstats.py 1 file changed, 1 insertion(+), 1 deletion(-)
git pull ssh://gerrit.ovirt.org:29418/vdsm refs/changes/71/65771/1
diff --git a/lib/vdsm/virt/vmstats.py b/lib/vdsm/virt/vmstats.py index 8e271cb..9b65fbd 100644 --- a/lib/vdsm/virt/vmstats.py +++ b/lib/vdsm/virt/vmstats.py @@ -330,7 +330,7 @@ last_indexes = _find_bulk_stats_reverse_map(last_sample, 'net')
for nic in vm.getNicDevices(): - if nic.name.startswith('hostdev'): + if nic.is_hostdevice: continue
# may happen if nic is a new hot-plugged one
gerrit-hooks has posted comments on this change.
Change subject: vmstats: user proper way to detect host devices ......................................................................
Patch Set 1:
* Update Tracker::IGNORE, no bug url/s found * Check Bug-Url::IGNORE, no bug url/s found * Check Public Bug::WARN, no public bug url found * Check merged to previous::IGNORE, Not in stable branch (['ovirt-3.6', 'ovirt-4.0'])
Martin Polednik has posted comments on this change.
Change subject: vmstats: user proper way to detect host devices ......................................................................
Patch Set 1: Code-Review-1
Jenkins failure is relevant:
15:47:23 Traceback (most recent call last): 15:47:23 File "/home/jenkins/workspace/vdsm_master_check-patch-el7-x86_64/vdsm/tests/vmStatsTests.py", line 353, in test_networks_good_interval 15:47:23 1) 15:47:23 File "/home/jenkins/workspace/vdsm_master_check-patch-el7-x86_64/vdsm/lib/vdsm/virt/vmstats.py", line 333, in networks 15:47:23 if nic.is_hostdevice: 15:47:23 AttributeError: 'FakeNic' object has no attribute 'is_hostdevice'
Please extend the FakeNic (should've been done by networking team in the past).
From Dan Kenigsberg danken@redhat.com:
Dan Kenigsberg has posted comments on this change.
Change subject: vmstats: user proper way to detect host devices ......................................................................
Patch Set 2: Code-Review-1
I have a vague memory that this needs to be tested with the vmfex hook. I'm marking with -1 until I dig a bit deeper into its history.
vdsm-patches@lists.fedorahosted.org