URGENT - GET /VM? ERROR from sunstone portal

OpenNebula version: 4.8.0

It happened time to time. Sunstone.log has output as below:

Mon Jul 06 13:31:35 2015 [I]: 138.120.133.141 - - [06/Jul/2015 13:31:35] “GET /vm?timeout=false&csrftoken=4a606635a0ee2ce5b13c08118d45c342 HTTP/1.1” 500 - 30.0336

Impact: The web-portal (sunstone) list an empty “Virtual Machines” page. End-user can not see the VMs.
Error on user’s portal:
Net::ReadTimeout

In case anyone has similar issue.
It’s related to the backend database (MySQL) performance. The default setting of MySQL can not handle the big volume of the request. A tuned MySQL resolved the issue.

Hi Gene liu

Just out of curiosity, How did you tune the MySQL?

Cheers

We tuned w/ innodb_buffer and query_buffer
We also turned off vm.swappiness