Pivotal Knowledge Base

Follow

Workload Manager Rules are not Applied to Sessions with query_start = NULL

Environment

Workload Manager (WLM) 1.8.3 and below

Symptom

WLM version 1.8.3 does not kill idle sessions.

Cause

When a user initially connects to Pivotal Greenplum Database (GPDB), the "query_start" in the view pg_catalog.pg_stat_activity is NULL as no query was started. While this is NULL, WLM will not apply any rules to the session. Therefore, it is not possible for the WLM to disconnect the session if it is idle for too long.

The proper solution for identifying idle sessions is to use the session_level_memory_consumption view as described in the 5.x documentation.
Once identified, the sessions can be killed using pg_terminate_backend.
The ability to terminate idle sessions will be available in Greenplum Command Center and Workload Manager for Greenplum version 5.x and above.

Resolution

Use the article, Scripts to Terminate all idle connections in Pivotal Greenplum database cluster in order to terminate sessions with "query_start = NULL" in 4.3.

Additional Information

Review request 2137 in GitHub to get more information on this.

Comments

Powered by Zendesk