Support Article
OutOfMemory error when activating SystemCleaner agent
SA-44473
Summary
OutOfMemory error occurs when activating the SystemCleaner agent. This occurs for a cluster environment with four nodes. This results in large amounts of data in the PR_SYS_CONTEXT and PR_PAGE_STORE tables.
Error Messages
615 [fault (self-tuning)'] [STANDARD] [an_app:0x.0x] (internal.async.Agent) ERROR - Encountered unhandled exception during agent processing
java.lang.OutOfMemoryError: Java heap space
at com.pega.pegarules.data.internal.clipboard.directstream.InflaterV7.inflateV7(InflaterV7.java:47)
at com.pega.pegarules.data.internal.access.CompressImpl.inflate(CompressImpl.java:176)
at com.pega.pegarules.data.internal.clipboard.StorageStreamCommonImpl.inflateStream(StorageStreamCommonImpl.java:625)
at com.pega.pegarules.data.internal.access.PageDatabaseMapperImpl.populatePageOrStringMapFromStreamColumn(PageDatabaseMapperImpl.java:2104)
at com.pega.pegarules.data.internal.access.ResultPageIteratorImpl.getClipboardPage(ResultPageIteratorImpl.java:1074)
at com.pega.pegarules.data.internal.access.ResultPageIteratorImpl.next(ResultPageIteratorImpl.java:558)
at com.pega.pegarules.data.internal.access.PageResultPackager.createResultPages(PageResultPackager.java:399)
at com.pega.pegarules.data.internal.access.PageResultPackager.packageResults(PageResultPackager.java:294)
at com.pega.pegarules.data.internal.access.DatabaseImpl.list(DatabaseImpl.java:5812)
at com.pega.pegarules.data.internal.access.DatabaseImpl.list(DatabaseImpl.java:5616)
Steps to Reproduce
Start the SystemCleaner agent.
Root Cause
A large amount of passivation data was accumulated in the PR_SYS_CONTEXT and PR_PAGE_STORE tables. This caused the SystemCleaner agent overhead.
Resolution
Perform the following local-change:
- Delete the obsolete passivation data older than three days (to account for weekends) from the PR_PAGE_STORE and PR_PAGE_STORE tables.
- Create a backup of the database before a direct manipulation.
- Use the below SQL queries to delete the obsolete data:
- SELECT * FROM <data schema name>.pr_page_store INNER JOIN <data schema name>.pr_sys_context ON <data schema name>.pr_page_store.pyrequestorid = <data schema name>.pr_sys_context.pxrequestorid WHERE <data schema name>.pr_sys_context.pxcreatedatetime < '<3 days ago>';
- SELECT * FROM <data schema name>.pr_sys_context WHERE pxcreatedatetime < '<3 days ago>';
Note: Enter these queries as SELECTs to verify which data to delete. Change to DELETE queries upon confirmation that the correct records are selected for deletion.
Published March 18, 2018 - Updated October 8, 2020
Have a question? Get answers now.
Visit the Collaboration Center to ask questions, engage in discussions, share ideas, and help others.