{"id":972,"date":"2024-12-27T22:26:27","date_gmt":"2024-12-27T22:26:27","guid":{"rendered":"https:\/\/w3buddy.com\/?p=972"},"modified":"2026-01-15T13:17:33","modified_gmt":"2026-01-15T07:47:33","slug":"how-to-resolve-hung-awr-process-in-oracle","status":"publish","type":"post","link":"https:\/\/w3buddy.com\/blog\/how-to-resolve-hung-awr-process-in-oracle\/","title":{"rendered":"How to Resolve a Hung AWR Process in Oracle"},"content":{"rendered":"\n<p class=\"wp-block-paragraph\">If you encounter a hung <strong>AWR (Automatic Workload Repository)<\/strong> process in Oracle, you may need to identify and terminate the associated session. Here&#8217;s a step-by-step guide on how to troubleshoot and resolve the issue:<\/p>\n\n\n\n<p class=\"wp-block-paragraph\">1. <strong>Identify the Session Associated with the AWR Process:<\/strong> First, use the following SQL query to identify the sessions related to the AWR process:<\/p>\n\n\n\n<ol class=\"wp-block-list\">\n<li><\/li>\n<\/ol>\n\n\n\n<pre class=\"wp-block-prismatic-blocks\"><code class=\"language-sql\">SQL> SELECT sid, serial#, program, logon_time FROM v$session WHERE program LIKE '%M00%';<\/code><\/pre>\n\n\n\n<p class=\"wp-block-paragraph\">This will return a list of sessions associated with AWR processes, for example:<\/p>\n\n\n\n<pre class=\"wp-block-prismatic-blocks\"><code class=\"language-sql\">SID    SERIAL# PROGRAM                                          LOGON_TIME\n---------- ---------- ------------------------------------------------ --------\n   2118      13632 oracle@hostname (QM00)                         17.05.20\n   2331      23309 oracle@hostname (M000)                         09.06.20\n   7861      57138 oracle@hostname (M003)                         14.06.20<\/code><\/pre>\n\n\n\n<p class=\"wp-block-paragraph\">In this case, you can see multiple processes such as QM00, M000, and M003.<\/p>\n\n\n\n<p class=\"wp-block-paragraph\">2. <strong>Locate the Process on the OS Level:<\/strong> Once you have identified the session, you can locate the corresponding process in the operating system. First, access the Oracle user&#8217;s terminal session. Then, use the following command to list the processes associated with AWR sessions:<\/p>\n\n\n\n<ol start=\"2\" class=\"wp-block-list\">\n<li><\/li>\n<\/ol>\n\n\n\n<pre class=\"wp-block-prismatic-blocks\"><code class=\"language-bash\">[hostname:\/path\/to\/oracle_home][oracle_user]$ps -ef | grep m00<\/code><\/pre>\n\n\n\n<p class=\"wp-block-paragraph\">This will show you the processes associated with the AWR session. For example:<\/p>\n\n\n\n<pre class=\"wp-block-prismatic-blocks\"><code class=\"language-bash\">ora01 23972     1  0  May 17  ?         0:29 ora_qm00_hostname_o\nora01 28150     1 200  Jun  9  ?        713:56 ora_m000_hostname_o\nora01 26346 24281  0 15:45:53 pts\/3     0:00 grep m00\nora01  2279     1  0 14:31:02 ?         0:08 ora_m003_hostname_o<\/code><\/pre>\n\n\n\n<p class=\"wp-block-paragraph\">In this example, you can see the processes for qm00, m000, and m003.<\/p>\n\n\n\n<p class=\"wp-block-paragraph\">3. <strong>Kill the Hung AWR Session:<\/strong><\/p>\n\n\n\n<p class=\"wp-block-paragraph\">If you identify a hung process that needs to be terminated, you can kill the session at the OS level. For example, use the kill -9 command with the appropriate process ID (PID):<\/p>\n\n\n\n<pre class=\"wp-block-prismatic-blocks\"><code class=\"language-bash\">kill -9 26346<\/code><\/pre>\n\n\n\n<p class=\"wp-block-paragraph\">This will forcefully terminate the session and should resolve the issue with the hung AWR process.<\/p>\n\n\n\n<p class=\"wp-block-paragraph\">4. <strong>Verify the Process is Terminated:<\/strong><\/p>\n\n\n\n<p class=\"wp-block-paragraph\">After killing the process, run the following SQL query again to verify that the session is no longer active:<\/p>\n\n\n\n<pre class=\"wp-block-prismatic-blocks\"><code class=\"language-sql\">SQL> SELECT sid, serial#, program, logon_time FROM v$session WHERE program LIKE '%M00%';<\/code><\/pre>\n\n\n\n<p class=\"wp-block-paragraph\">If the session was successfully terminated, it should no longer appear in the list.<\/p>\n","protected":false},"excerpt":{"rendered":"<p>If you encounter a hung AWR (Automatic Workload Repository) process in Oracle, you may need to identify and terminate the associated session. Here&#8217;s a step-by-step guide on how to troubleshoot and resolve the issue: 1. Identify the Session Associated with the AWR Process: First, use the following SQL query to identify the sessions related to [&hellip;]<\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"googlesitekit_rrm_CAowu461DA:productID":"","footnotes":""},"categories":[1225],"tags":[],"class_list":["post-972","post","type-post","status-publish","format-standard","hentry","category-database"],"_links":{"self":[{"href":"https:\/\/w3buddy.com\/blog\/wp-json\/wp\/v2\/posts\/972","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/w3buddy.com\/blog\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/w3buddy.com\/blog\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/w3buddy.com\/blog\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/w3buddy.com\/blog\/wp-json\/wp\/v2\/comments?post=972"}],"version-history":[{"count":2,"href":"https:\/\/w3buddy.com\/blog\/wp-json\/wp\/v2\/posts\/972\/revisions"}],"predecessor-version":[{"id":1566,"href":"https:\/\/w3buddy.com\/blog\/wp-json\/wp\/v2\/posts\/972\/revisions\/1566"}],"wp:attachment":[{"href":"https:\/\/w3buddy.com\/blog\/wp-json\/wp\/v2\/media?parent=972"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/w3buddy.com\/blog\/wp-json\/wp\/v2\/categories?post=972"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/w3buddy.com\/blog\/wp-json\/wp\/v2\/tags?post=972"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}