yahoo-eng-team team mailing list archive
-
yahoo-eng-team team
-
Mailing list archive
-
Message #76891
[Bug 1813253] Re: Update the processing of assigned addresses when assigning addresses
Reviewed: https://review.openstack.org/633406
Committed: https://git.openstack.org/cgit/openstack/neutron/commit/?id=1746d7e0e682eab1001bfc434b73efb1cdf5f0f4
Submitter: Zuul
Branch: master
commit 1746d7e0e682eab1001bfc434b73efb1cdf5f0f4
Author: liuchengqian90 <xieling1990.happy@xxxxxxx>
Date: Sun Jan 27 20:47:50 2019 +0800
Update the processing of assigned addresses when assigning addresses
1.It is best not to use 'netaddr.IPSet.add',
because _compact_single_network in 'IPSet.add' is quite time consuming
2.When the current address pool does not have enough addresses,
all addresses are allocated from the current pool,
and allocations are continued from the next address pool
until all addresses are assigned.
Change-Id: I804a95fdaa3552c785e85ffab7b8ac849c634a87
Closes-Bug: #1813253
** Changed in: neutron
Status: In Progress => Fix Released
--
You received this bug notification because you are a member of Yahoo!
Engineering Team, which is subscribed to neutron.
https://bugs.launchpad.net/bugs/1813253
Title:
Update the processing of assigned addresses when assigning addresses
Status in neutron:
Fix Released
Bug description:
openstack allinone.
16 cpus with 2.40GHz
16G memery
only one subnet in a network.
1. Neutron-server takes a long time when creating a port with multiple
addresses at once
neutron port-create --fixed-ip subnet_id=474b9575-b569-48dd-
a3f2-0b02b752c098 --fixed-ip subnet_id=474b9575-b569-48dd-
a3f2-0b02b752c098 --fixed-ip subnet_id=474b9575-b569-48dd-
a3f2-0b02b752c098 --fixed-ip subnet_id=474b9575-b569-48dd-
a3f2-0b02b752c098 --fixed-ip subnet_id=474b9575-b569-48dd-
a3f2-0b02b752c098 --fixed-ip subnet_id=474b9575-b569-48dd-
a3f2-0b02b752c098 --fixed-ip subnet_id=474b9575-b569-48dd-
a3f2-0b02b752c098 --fixed-ip subnet_id=474b9575-b569-48dd-
a3f2-0b02b752c098 --fixed-ip subnet_id=474b9575-b569-48dd-
a3f2-0b02b752c098 --fixed-ip subnet_id=474b9575-b569-48dd-
a3f2-0b02b752c098 66105fab-7ea9-4efc-b9c8-1839f742bdd1
When there are already 6300+ addresses, it takes 50s to allocate the
address part every time the command is run.
in _generate_ips,
2s+ for list_allocations (not fixed in this fix)
2s+ for ip_allocations.add(ipallocation.ip_address)
10 times.
https://github.com/drkjam/netaddr/issues/171
- list_allocations
I found it is slow because of log in process_rows method. https://github.com/sqlalchemy/sqlalchemy/blob/master/lib/sqlalchemy/engine/result.py
I turn off 'connection_debug' in neutron.conf ,Speed increases quickly, '2 seconds , 741903 microseconds' to '711636 microseconds'.
2.When the current address pool does not have enough addresses,
all addresses are allocated from the current pool,
and allocations are continued from the next address pool
until all addresses are assigned.
To manage notifications about this bug go to:
https://bugs.launchpad.net/neutron/+bug/1813253/+subscriptions
References