Bug 869210 - Custom report cause the db server to oom
Custom report cause the db server to oom
Product: TCMS
Classification: Other
Component: Database (Show other bugs)
Unspecified Unspecified
unspecified Severity urgent
: ---
: ---
Assigned To: Yang Ren
Depends On:
  Show dependency treegraph
Reported: 2012-10-23 05:43 EDT by jianchen
Modified: 2018-02-15 19:39 EST (History)
4 users (show)

See Also:
Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
Last Closed:
Type: Bug
Regression: ---
Mount Type: ---
Documentation: ---
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---

Attachments (Terms of Use)

  None (edit)
Description jianchen 2012-10-23 05:43:26 EDT
Description of problem:

Version-Release number of selected component (if applicable):

How reproducible:

Steps to Reproduce:
1. use customer report to create report (eg, create report for RHEL 7)
2. the custom report will load for quite a while with no response.
3. Others operation besides report unavailable too.
Actual results:
Custom report cause the db server to oom 

Expected results:

Additional info:
Comment 1 jianchen 2012-10-25 23:10:43 EDT
This bug was fixed in tcms 3.8.2.

Previously, tcms custom report raise complex SQL query statement stacked up and eventually caused the database server to oom. It's will only involve RHEL6/RHEL7 custom report because this products exist a large number testcaseruns. Query and statistical testcaserun to a high load on the database server.

Add property (eg. failed_case_run_num, passed_case_run_num) to testrun, each time change testcaserun's status will update relevent testrun's properties. The report will query testrun's properties directly and no need to queries testcaserun one by one which reduce database server pressure.
Comment 2 Xin Gao 2012-10-26 05:46:40 EDT
Verify 3.8.2 on tcms-test -->PASS

processor	: 0
vendor_id	: GenuineIntel
cpu family	: 6
model		: 13
model name	: QEMU Virtual CPU version (cpu64-rhel6)
stepping	: 3
cpu MHz		: 2400.056
cache size	: 4096 KB

memory: 1002M

swap:      3148732

Verify steps:
1. use customer report to create RHEL 7 report. And at the same time, another user do advanced Search operation.
2. check the tcms-test env resources while tcms query data, such as, %CPU, %MEM.

Actual result:
after 15s, report generated successfully, And didn't effect advanced search.

But, actually tcms-test env cpu utilization rate reached 95.6% at the beginning of query. this means tcms performance is still not very well, and Query algorithm need to be improved in the future.

Note You need to log in before you can comment on or make changes to this bug.