poor api performance with postgresql backend
Bug #1666547 reported by
Mate Lakat
This bug affects 4 people
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
Cinder |
Fix Released
|
Undecided
|
Mate Lakat | ||
OpenStack Shared File Systems Service (Manila) |
Invalid
|
Wishlist
|
Unassigned |
Bug Description
With a significant number of volumes, and using postgresql as the database backend, we found that the API requests are quite slow. We have around 500k rows in volumes table, also as we mostly boot from volume, 300k rows for volume_
Changed in cinder: | |
assignee: | nobody → Mate Lakat (mate-lakat) |
status: | New → In Progress |
Changed in manila: | |
assignee: | Marc Koderer (m-koderer) → nobody |
Changed in manila: | |
importance: | High → Medium |
Changed in manila: | |
status: | In Progress → Confirmed |
Changed in manila: | |
status: | Confirmed → Incomplete |
To post a comment you must log in.
Doing a tox -esmoke results in these metrics on the cinder database:
cinder=# SELECT relname, seq_scan, idx_scan, n_live_tup rows_in_table FROM pg_stat_user_tables ORDER BY rows_in_table DESC; ------- ------- ------- +------ ----+-- ------- -+----- ------- --- glance_ metadata | 372 | 0 | 64 admin_metadata | 422 | 0 | 15 volume_ cache_entries | 24 | 7 | 1 type_extra_ specs | 1261 | 0 | 1 type_projects | 2 | 20 | 0 of_service_ specs | 53 | 0 | 0 initiator_ data | 3 | 0 | 0 volume_ type_mapping | 1 | 0 | 0 type_projects | 2 | 0 | 0
relname | seq_scan | idx_scan | rows_in_table
-------
reservations | 164 | 64 | 180
volume_
quota_usages | 412 | 133 | 40
volumes | 571 | 710 | 21
volume_
volume_metadata | 986 | 0 | 10
volume_attachment | 1010 | 40 | 8
quota_classes | 3 | 68 | 6
services | 753 | 119 | 2
snapshots | 68 | 56 | 2
image_
volume_types | 91 | 654 | 1
group_types | 2 | 1 | 1
workers | 174 | 0 | 1
volume_
migrate_version | 1 | 54 | 1
group_type_specs | 2 | 0 | 1
volume_
group_snapshots | 2 | 0 | 0
quality_
backups | 1 | 0 | 0
groups | 2 | 514 | 0
attachment_specs | 1 | 0 | 0
encryption | 21 | 0 | 0
messages | 2 | 0 | 0
driver_
group_
snapshot_metadata | 46 | 0 | 0
consistencygroups | 3 | 514 | 0
quotas | 115 | 0 | 0
group_
transfers | 23 | 0 | 0
clusters | 45 | 0 | 0
cgsnapshots | 2 | 0 | 0
(34 rows)