[Openstack-operators] Fwd: [openstack-dev] [nova][neutron] Filtering Instances by IP address performance improvement test result

Matt Riedemann mriedemos at gmail.com
Fri Jan 5 23:09:15 UTC 2018

FYI, some performance test results for a series of patches between nova 
and neutron to try and improve the performance of listing instances and 
filtering by ip.

-------- Forwarded Message --------
Subject: 	[openstack-dev] [nova][neutron] Filtering Instances by IP 
address performance improvement test result
Date: 	Fri, 5 Jan 2018 10:53:56 +0800
From: 	Zhenyu Zheng <zhengzhenyulixi at gmail.com>
Reply-To: 	OpenStack Development Mailing List (not for usage questions) 
<openstack-dev at lists.openstack.org>
To: 	OpenStack Development Mailing List (not for usage questions) 
<openstack-dev at lists.openstack.org>

Hi All,

We are working on patches to improve the performance filtering instance 
by IP address this cycle. As discussed in the previous ML[1], it 
contains both patches from Nova and Neutron[2][3][4][5][6].

As the POC is almost functional(the neutron extension part seems not 
working, it cannot be successfully listed in patchset 14 of [5] , I have 
to bypass the "if" condition for checking neutron 
"ip-substring-filtering" extension to make it work, but that seems easy 
to fix), I made some tests to check what kind of improvement has been 
done with those patches.

In the tests, I wrote a simple script [7](the script is silly, please 
don't laugh at me:) ) which generated 2000 vm records in Nova DB with IP 
address allocated(one IP for each vm), and also 2000 port records with 
corresponding IP addresses in my local devstack env.

Before adding those patches, querying instance with a specific IP 
filtering causes about 4000 ms, the test has been done several times, 
and I took the averaged result:
Inline image 1

After adding those patches(and some modifications as mentioned above) 
querying with the same request causes only about 400ms:
Inline image 2

So, the design seems working well.

I also tested with a "Sub-String" manner filtering with IP address:, which will match 66 instances, and it takes about 900ms:
Inline image 3

It increased, but seems reasonable as it matches more instances, and 
still much better than current implementation.

Please test out in your own env if interested, the script might need 
some modification as I hardcoded db connection, network_id and subnet_id.

And also, please help review the patches :)

[2] https://review.openstack.org/#/c/509326/
[3] https://review.openstack.org/#/c/525505/
[4] https://review.openstack.org/#/c/518865/
[5] https://review.openstack.org/#/c/521683/
[6] https://review.openstack.org/#/c/525284/


Kevin Zheng
-------------- next part --------------
OpenStack Development Mailing List (not for usage questions)
Unsubscribe: OpenStack-dev-request at lists.openstack.org?subject:unsubscribe

More information about the OpenStack-operators mailing list