0% found this document useful (0 votes)
3 views

AG6_Performance_tuning_and_monitoring_the_Autonomous_DB_(SQL+Monitoring)_ed3

Uploaded by

govindarao dba
Copyright
© © All Rights Reserved
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
3 views

AG6_Performance_tuning_and_monitoring_the_Autonomous_DB_(SQL+Monitoring)_ed3

Uploaded by

govindarao dba
Copyright
© © All Rights Reserved
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 26

Performance tuning

and monitoring the Autonomous


DB (SQL Monitoring)

[Edition 3]
[Last Update 190712]

For any issues/help contact : support@k21academy.com

1 support@k21academy.com
Contents
1 Introduction................................................................................................................................................... 3
2 Documentation ............................................................................................................................................. 4
2.1 Oracle Documentation ........................................................................................................................................ 4
3 Performance Monitoring IN Autonomous Data Warehouse ............................................................ 5
3.1 Console Overview:................................................................................................................................................ 5
3.2 Console Activity: ................................................................................................................................................... 8
4 Manage Runaway SQL Statements on Autonomous Data Warehouse ........................................ 15
5 Development .............................................................................................................................................. 20
6 Performance Hub Console ...................................................................................................................... 24
7 SUMMARY .................................................................................................................................................... 26

2 support@k21academy.com
1 INTRODUCTION

This activity guide covers Performance tuning and monitoring the Autonomous DB (SQL
Monitoring)

Pre-Requisite: AG2_Provisioning_Autonomous_Data_Warehouse
Pre-Requisite: AG3_Connecting_SQL_Developer_to_ADW_&_Creating Tables

This guide covers,

• Performance monitoring

• Run-away query management

• Manage Optimizer Statistics On Autonomous Data Warehouse

3 support@k21academy.com
2 DOCUMENTATION

2.1 Oracle Documentation

1. Autonomous Data Warehouse


https://docs.cloud.oracle.com/iaas/Content/Database/Concepts/adwoverview.htm
2. Creating an Autonomous Data Warehouse
https://docs.cloud.oracle.com/iaas/Content/Database/Tasks/adwcreating.htm
3. Connecting with Oracle SQL Developer (earlier than Version 18.2)
https://www.oracle.com/webfolder/technetwork/tutorials/obe/cloud/adwc/obe_connecting_s
ql_developer_to_autonomous_data_warehouse_and_creating_tables/connecting_sql_dev_
to_adw_and_creating_tables.html
4. SQL Developer 18.3
https://www.oracle.com/technetwork/developer-tools/sql-developer/downloads/index.html
5. Loading Your Data Into Autonomous Data Warehouse
https://www.oracle.com/webfolder/technetwork/tutorials/obe/cloud/adwc/OBE_Loading%20
Your%20Data/loading_your_data.html
6. Managing and Monitoring Performance of Autonomous Data Warehouse
https://docs.oracle.com/en/cloud/paas/autonomous-data-warehouse-cloud/user/manage-
service.html#GUID-759EFFFA-9FAC-4439-B47F-281E470E01DE

4 support@k21academy.com
3 PERFORMANCE MONITORING IN AUTONOMOUS DATA WAREHOUSE

1. In your ADW instance details page, click on Service Console.

2. Once you click on Service Console another Tab will open from where you will see all the
performance details of your ADW Instance Under Overview Section.

3.1 Console Overview:

5 support@k21academy.com
1. The Overview page shows real-time and historical information about the utilization of the
service. The components on this page are:
• Storage

This chart shows the total and used storage capacity of the service. It indicates what
percentage of the space is currently in-use.

• CPU utilization (%)

This chart shows the historical CPU utilization of the service.

• Running SQL statements

This chart shows the average number of running SQL statements historically.

6 support@k21academy.com
• Number of OCPUs Allocated:

This chart shows the actual number of OCPUs allocated by the service.

• SQL Statement Response Time (s):

This chart shows the average response time of SQL statements historically.

7 support@k21academy.com
3.2 Console Activity:

The Activity page shows real-time and historical information about the utilization of the service.

1. To access detailed information about the service performance click the Activity tab in the
service console.

The components on this page are:


• Database Activity :This chart shows the average number of sessions in the database using
CPU or waiting on a wait event. See Oracle Database Reference for more information on
wait events.

8 support@k21academy.com
• CPU Utilization: This chart shows the CPU utilization of each consumer group. See
Managing Priorities on Autonomous Transaction Processing for detailed information on
consumer groups.

• Running Statements: This chart shows the average number of running SQL statements in
each consumer group. See Managing Priorities on Autonomous Transaction Processing for
detailed information about consumer groups.

9 support@k21academy.com
• Queued Statements:This chart shows the average number of queued SQL statements in
each consumer group. See Managing Priorities on Autonomous Transaction Processing for
detailed information on consumer groups.

Note: The default view in this tab is real-time. This view shows performance data for the last
hour.
To see earlier data click Time period. The default retention period for performance data is
eight days. So, this view shows information for the last eight days by default.

10 support@k21academy.com
Note: The retention time can be changed by changing the Automatic Workload Repository
retention setting with the PL/SQL procedure
DBMS_WORKLOAD_REPOSITORY.MODIFY_SNAPSHOT_SETTINGS. Be aware that
increasing the retention time results in more storage usage for performance data
2. The Monitored SQL tab shows information about current and past monitored SQL statements.
Click the Monitored SQL tab to see these statements.

3. To see the detailed SQL Monitor report for a statement, select a statement and click Show
Details.

11 support@k21academy.com
4. The Overview tab in the pop-up shows general information for that statement.

5. Click Plan Statistics tab to see the runtime execution plan of the statement.

12 support@k21academy.com
6. Click Parallel tab to see information about the parallel processes, if the statement uses
parallelism.

7. If you want to download an active SQL Monitor report for a statement, select the statement in
the Monitored SQL page and click Download report. This will save the active SQL Monitor
report to your client

13 support@k21academy.com
8. To cancel a running statement, select that statement in the Monitored SQL list and click Cancel
execution.

In this section we have successfully learn Performance Monitoring in Autonomous Data


Warehouse

14 support@k21academy.com
4 MANAGE RUNAWAY SQL STATEMENTS ON AUTONOMOUS DATA
WAREHOUSE

Specifies how you configure Autonomous Data Warehouse to terminate SQL statements
automatically based on their runtime or the amount of IO they are doing.
You can set rules from the service console or using the PL/SQL package
cs_resource_manager.
Steps to set rules from the service console:

1. On the Service Console click the Administration tab.

2. The components on this page are:

• Download Client Credentials (Wallet): You can download the Wallet to connect to
Database from here .

You will get below screen after clicking on same. Enter the password and download the wallet.

15 support@k21academy.com
• Set Resources Management Rules:

Click Set Resource Management Rules to open the page to set runaway query rules for
consumer groups.

You will get below acreen after clicking on same. Under Run-away criteria, you can set query

run time and Amount of IO for consumer Groups.

16 support@k21academy.com
Under CPU/IO shares, you can set CPU/IO for consumer groups.

When a SQL statement in the specified consumer runs more than the specified runtime limit
or does more IO than the specified amount, then the SQL statement will be terminated.

To reset the values and lift the limits, you can use the same screen, delete the values, and
save the changes.

You can also use the procedure cs_resource_manager.update_plan_directive to set


these rules. For example, to set a runtime limit of 120 seconds and an IO limit of 1000MB for
the HIGH consumer group run the following command when connected to the database as
the ADMIN user:

BEGIN
cs_resource_manager.update_plan_directive(consumer_group => 'HIGH',
io_megabytes_limit => 1000, elapsed_time_limit => 120);
END;
/
To reset the values and lift the limits, you can set the values to null:

BEGIN
cs_resource_manager.update_plan_directive(consumer_group => 'HIGH',
io_megabytes_limit => null, elapsed_time_limit => null);
END;
/

• Set Administrative Password: Use this to set the Admin Password.

17 support@k21academy.com
You will get below screen after clicking on same. Set the Password and Click OK.

• Manage Oracle ML Users: This option is used to View and Create Machine Language
Users.

After Clicking on same, you will be redirected to the Machine Learning (ML) User Admin
Console.

18 support@k21academy.com
• Send Feedback to Oracle:

This option is used for sending any feedback to Oracle.

19 support@k21academy.com
5 DEVELOPMENT

1. Last tab you have is Development Tab where you have APEX, SQL Developer Web, OML
Notebooks and Download Oracle Instant Client.

• APEX:
Oracle Application Express (APEX) is a low-code development platform that enables you to
build scalable, secure enterprise applications with world-class features that can be deployed
anywhere.

After Clicking on APEX, you will be redirected to APEX Console.

20 support@k21academy.com
• SQL Developer Web:
SQL Developer Web is a browser-based interface of Oracle SQL Developer and provides a
subset of the features of the desktop version.

After Clicking on SQL Developer Web, you will be redirected to SQL Developer Web Console.

• OML Notebooks:
Autonomous Data Warehouse includes built-in support for data analytics using Oracle Machine
Learning (OML) a browser-based interactive data analysis environment for data scientists.

21 support@k21academy.com
After Clicking on OML Notebooks, You will be prompted for Machine learning User Login.

• Download Oracle Instant Client:


This is a free, light-weight set of tools, libraries and SDKs for building and connecting
applications.

After Clicking on same, you will be redirected to Oracle site to download the Oracle Instant
Client.

22 support@k21academy.com
23 support@k21academy.com
6 PERFORMANCE HUB CONSOLE

1. After Clicking on Autonomous Database, you will see the Performance Hub Tab to monitor the
performance.

2. After Clicking on Performance Hub, you will see below screen where you can see Active
session History, ASH Analytics and SQL Monitoring.

24 support@k21academy.com
25 support@k21academy.com
7 SUMMARY

In this activity Guide we learned Performance tuning and monitoring the Autonomous DB (SQL
Monitoring).

26 support@k21academy.com

You might also like