-
-
Notifications
You must be signed in to change notification settings - Fork 213
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Avoiding excessive memory consumption by undo-log after series of updates [CORE1477] #1893
Comments
Commented by: Kuznetsov Eugene (eugene) Test database |
Modified by: Kuznetsov Eugene (eugene)Attachment: Test.zip [ 10590 ] |
Modified by: @dyemanovassignee: Dmitry Yemanov [ dimitr ] |
Modified by: @dyemanovTarget: 2.5.0 [ 10221 ] |
Modified by: @pcisarWorkflow: jira [ 13160 ] => Firebird [ 15593 ] |
Modified by: @dyemanovstatus: Open [ 1 ] => Open [ 1 ] Fix Version: 2.5 Beta 1 [ 10251 ] Fix Version: 2.5 Alpha 1 [ 10224 ] => |
Modified by: @dyemanovstatus: Open [ 1 ] => In Progress [ 3 ] |
Modified by: @dyemanovstatus: In Progress [ 3 ] => Open [ 1 ] |
Modified by: @pcisarstatus: Resolved [ 5 ] => Closed [ 6 ] |
Modified by: @pavel-zotovQA Status: No test |
Commented by: @pavel-zotov Problem still exists, it seems to me that ticket should be reopened. Following is result for several FB versions: 1) WI-V2.0.0.12724 (Firebird 2.0 Release Candidate 4): execute procedure TEST3; execute procedure TEST3; 2) WI-V2.5.1.26351: execute procedure TEST3; execute procedure TEST3; 3) WI-V2.5.7.27025: execute procedure TEST3; execute procedure TEST3; 4) WI-V3.0.1.32585, Classic: execute procedure TEST3; execute procedure TEST3; 5) WI-V3.0.1.32588, SuperServer: execute procedure TEST3; execute procedure TEST3; In all cases ratio of 'Max memory' values for two subsequent calls of SP test3 is extremely high. |
Modified by: @pavel-zotovAttachment: c1477-ddl-and-run.sql [ 13011 ] |
Commented by: @dyemanov Pavel, what TempCacheLimit was used in your tests? It should be default (low) value to see the effect of the patch. |
Commented by: @pavel-zotov All except FB 3.0 SS - default values; on WI-V3.0.1.32588, SuperServer: TempCacheLimit = 2147483647 After changing TempCahceLimit to default value on 3.0 SS statistics is: execute procedure TEST3; execute procedure TEST3; So, ratio between Maxmemory values is about 7 times ( 142.2 / 21.5 ). |
Commented by: @dyemanov 64MB is occupied by the temp cache, so the query actually uses ~80MB. The ratio is ~4x. This is expected. |
Modified by: @pavel-zotovstatus: Closed [ 6 ] => Closed [ 6 ] QA Status: No test => Deferred Test Details: Waiting for reply from dimitr, letter 09-sep-2016 09:48. |
Submitted by: Kuznetsov Eugene (eugene)
Is related to CORE1575
Attachments:
Test.zip
c1477-ddl-and-run.sql
Look at the example
Start Transaction: isc_tpb_consistency,isc_tpb_no_auto_undo,isc_tpb_nowait
execute procedure TEST3
-----Statistics-----
Reads = 5344
Writes = 5053
Fetches = 8499490
Marks = 2810214
CurrentMemory = 17139964
MaxMemory = 17840520
NumBuffers = 1000
-----Detail statistics-----
read_seq_count
TEST_TABLE2 = 1000000
update_count
TEST_TABLE2 = 1000000
-----End------
execute procedure TEST3
-----Statistics-----
Reads = 12200
Writes = 495276
Fetches = 15811015
Marks = 5306902
CurrentMemory = 17140460
MaxMemory = 716093252
NumBuffers = 1000
-----Detail statistics-----
read_seq_count
TEST_TABLE2 = 1000000
update_count
TEST_TABLE2 = 1000000
-----End------
Commit Transaction
TEST3 is a simple procedure with the single update statement into it.
During the second call of TEST3 memory consumption grows extensively (see MaxMemory), exceeding database size at least five times more.
It seems, undo-log code needs for optimization.
With best regards, Eugene
Commits: e0db5f3 1a943d1
====== Test Details ======
Waiting for reply from dimitr, letter 09-sep-2016 09:48.
The text was updated successfully, but these errors were encountered: