Created
March 13, 2015 21:11
-
-
Save xtender/c024cd87ff86cb213c94 to your computer and use it in GitHub Desktop.
parallel-px-real time sql monitoring-2
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| SQL> alter system set parallel_max_servers=4; | |
| System altered. | |
| SQL> select /*+ PARALLEL */ count(*) from Large_Table; | |
| COUNT(*) | |
| ---------- | |
| 100000 | |
| SQL> alter system set parallel_max_servers=2; | |
| System altered. | |
| SQL> select /*+ PARALLEL */ count(*) from Large_Table; | |
| COUNT(*) | |
| ---------- | |
| 100000 | |
| SQL> select executions, px_servers_executions | |
| 2 from v$sqlstats | |
| 3 where sql_id = '8b0ybuspqu0mm'; | |
| EXECUTIONS PX_SERVERS_EXECUTIONS | |
| ---------- --------------------- | |
| 2 6 | |
| SQL> select r.SQL_EXEC_ID | |
| ,r.status | |
| ,r.PROCESS_NAME | |
| ,r.PX_IS_CROSS_INSTANCE | |
| ,r.PX_MAXDOP | |
| ,r.PX_QCSID | |
| ,r.PX_SERVER_SET | |
| ,r.PX_SERVER# | |
| ,r.PX_SERVER_GROUP | |
| from v$sql_monitor r | |
| where r.SQL_ID='8b0ybuspqu0mm' | |
| order by SQL_EXEC_ID,PX_SERVER_SET,PX_SERVER#; | |
| SQL_EXEC_ID STATUS PROCE P PX_MAXDOP PX_QCSID PX_SERVER_SET PX_SERVER# PX_SERVER_GROUP | |
| ----------- ------------------- ----- - ---------- ---------- ------------- ---------- --------------- | |
| 16777216 DONE (ALL ROWS) p000 130 1 1 1 | |
| 16777216 DONE (ALL ROWS) p001 130 1 2 1 | |
| 16777216 DONE (ALL ROWS) p002 130 1 3 1 | |
| 16777216 DONE (ALL ROWS) p003 130 1 4 1 | |
| 16777216 DONE (ALL ROWS) ora N 4 | |
| 16777217 DONE (ALL ROWS) p000 130 1 1 1 | |
| 16777217 DONE (ALL ROWS) p001 130 1 2 1 | |
| 16777217 DONE (ALL ROWS) ora N 2 | |
| 8 rows selected. |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment