[Openstack] cinder api list volumes very slow and inefficient.

Sam Morrison sorrison at gmail.com
Sun Jul 7 23:43:11 UTC 2013


Hi,

I'm wondering if anyone is using cinder and is having issue with the list volumes API call.

We have a grizzly install and we're at about 160 active volumes in cinder at the moment.

To do "cinder list" with a tenant that has about 140 volumes it takes about 6 seconds.
API calls on a specific volume are done in about 0.1 seconds so I'm happy with the API servers, it's the code I'm worried about.

Doing a "cinder list --all-tenants" as an admin it takes about 20 seconds.

Looking at the code it seems as an admin it will iterate over every volume 3 times and do a db requests on each volume.
As a normal user it iterates over every volume once.

The for loops are for adding glance image information and as an admin it also adds host and tenant information which is in the same table so it's a bit strange that it's doing more DB calls.

Does anyone use cinder with more that just a couple of active volumes and if so how do they when requests are so slow?
We have 36 cinder-api servers handling requests and they aren't under significant load. Also our DB cluster is handling things fine.

Cheers,
Sam








More information about the Openstack mailing list