Swift rebalance is extremely slow in Ubuntu
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
Fuel for OpenStack |
Fix Released
|
Critical
|
Nikolay Markov |
Bug Description
On Ubuntu + Python 2.7 swift rebalance takes up to 8 minutes to complete, instead of 1-2.
/bin/sh -c swift-ring-builder /etc/swift/
Looking through recent changes, I found that complexity and time spent on ring rebalancing was seriously increased with calling sorted() on each iteration through tiers depths
Profiling results:
Ordered by: cumulative time
ncalls tottime percall cumtime percall filename:
3145728 10.013 0.000 13.212 0.000 {sorted}
786432 4.811 0.000 8.633 0.000 /usr/lib/
12582912 6.418 0.000 6.418 0.000 {_bisect.
12582912 4.933 0.000 4.933 0.000 {method 'pop' of 'list' objects}
12582912 4.748 0.000 4.748 0.000 {method 'insert' of 'list' objects}
As I see this was made to increase quality of produced results, but performance is still bad.
Changed in fuel: | |
assignee: | nobody → Nikolay Markov (nmarkov) |
status: | New → In Progress |
Changed in fuel: | |
assignee: | Nikolay Markov (nmarkov) → Bogdan Dobrelya (bogdando) |
Changed in fuel: | |
assignee: | nobody → Nikolay Markov (nmarkov) |
importance: | High → Critical |
Changed in fuel: | |
assignee: | Nikolay Markov (nmarkov) → Nikolay Korshenin (nkorshenin) |
assignee: | Nikolay Korshenin (nkorshenin) → Nikolay Markov (nmarkov) |
Changed in fuel: | |
status: | Fix Committed → Fix Released |
I can confirm there are issues in swift code /swift/ common/ ring/builder. py which is called from ./bin/swift- ring-builder, causing timeouts on rebalance