How to Install SQLT

How to Install SQLT

Step 0: Find SQLT Already Instlled or Not
Step 1: Download SQLT
Step 2: How to Install SQLT
Step 3: Verify


Step 0: Find SQLT Already Instlled or Not

SELECT
'SQLT version number: '||sqltxplain.sqlt$a.get_param('tool_version')||CHR(10)||
'SQLT version date : '||sqltxplain.sqlt$a.get_param('tool_date')||CHR(10)||
'Installation date : '||sqltxplain.sqlt$a.get_param('install_date') sqlt_version
FROM DUAL;

output

SQL> SELECT
'SQLT version number: '||sqltxplain.sqlt$a.get_param('tool_version')||CHR(10)||
'SQLT version date : '||sqltxplain.sqlt$a.get_param('tool_date')||CHR(10)||
'Installation date : '||sqltxplain.sqlt$a.get_param('install_date') sqlt_version
FROM DUAL;  2    3    4    5
'Installation date : '||sqltxplain.sqlt$a.get_param('install_date') sqlt_version
                        *
ERROR at line 4:
ORA-00904: "SQLTXPLAIN"."SQLT$A"."GET_PARAM": invalid identifier <-- Not installed

SQL>


Step 1: Download SQLT

All About the SQLT Diagnostic Tool (Doc ID 215187.1)


Step 2: How to Install SQLT

unzip sqlt_latest.zip
cd /home/oracle/sqlt/install
sqlplus / as sysdba
@sqcreate.sql

output

[oracle@rac1 ~]$ cd /home/oracle/sqlt/install
[oracle@rac1 install]$ ls -ltr sqcreate.sql
-rw-r--r-- 1 oracle oinstall 4771 Oct 30  2014 sqcreate.sql
[oracle@rac1 install]$

[oracle@rac1 install]$ sqlplus / as sysdba

SQL*Plus: Release 11.2.0.3.0 Production on Mon Oct 17 12:18:23 2016

Copyright (c) 1982, 2011, Oracle.  All rights reserved.


Connected to:
Oracle Database 11g Enterprise Edition Release 11.2.0.3.0 - 64bit Production
With the Partitioning, Automatic Storage Management, OLAP, Data Mining
and Real Application Testing options

SQL> @sqcreate.sql

zip error: Nothing to do! (SQLT_installation_logs_archive.zip)

zip error: Nothing to do! (SQLT_installation_logs_archive.zip)

PL/SQL procedure successfully completed.


Specify optional Connect Identifier (as per Oracle Net)
Include "@" symbol, ie. @PROD
If not applicable, enter nothing and hit the "Enter" key.
You *MUST* provide a connect identifier when installing
SQLT in a Pluggable Database in 12c
This connect identifier is only used while exporting SQLT
repository everytime you execute one of the main methods.

Optional Connect Identifier (ie: @PROD): <-- Just hit enter


PL/SQL procedure successfully completed.


PL/SQL procedure successfully completed.


Define SQLTXPLAIN password (hidden and case sensitive).

Password for user SQLTXPLAIN: <--- Enter the password
Re-enter password:


PL/SQL procedure successfully completed.

... please wait

TABLESPACE                     FREE_SPACE_MB
------------------------------ -------------
EXAMPLE                                  216
USERS                                  32735


Specify PERMANENT tablespace to be used by SQLTXPLAIN.

Tablespace name is case sensitive.

Default tablespace [UNKNOWN]: USERS <---

PL/SQL procedure successfully completed.

... please wait

TABLESPACE
------------------------------
TEMP


Specify TEMPORARY tablespace to be used by SQLTXPLAIN.

Tablespace name is case sensitive.

Temporary tablespace [UNKNOWN]: TEMP <---

PL/SQL procedure successfully completed.


The main application user of SQLT is the schema
owner that issued the SQL to be analyzed.
For example, on an EBS application you would
enter APPS.
You will not be asked to enter its password.
To add more SQLT users after this installation
is completed simply grant them the SQLT_USER_ROLE
role.

Main application user of SQLT: scott  <-----

PL/SQL procedure successfully completed.


SQLT can make extensive use of licensed features
provided by the Oracle Diagnostic and the Oracle
Tuning Packs, including SQL Tuning Advisor (STA),
SQL Monitoring and Automatic Workload Repository
(AWR).
To enable or disable access to these features
from the SQLT tool enter one of the following
values when asked:

"T" if you have license for Diagnostic and Tuning
"D" if you have license only for Oracle Diagnostic
"N" if you do not have these two licenses

Oracle Pack license [T]: <----

PL/SQL procedure successfully completed.


PL/SQL procedure successfully completed.


PL/SQL procedure successfully completed.


PL/SQL procedure successfully completed.


PL/SQL procedure successfully completed.


PL/SQL procedure successfully completed.


PL/SQL procedure successfully completed.


PL/SQL procedure successfully completed.

TADOBJ completed.

PL/SQL procedure successfully completed.
..
..
SQLT users must be granted SQLT_USER_ROLE before using this tool. <----

SQCREATE completed. Installation completed successfully.
SQL>


Step 3: Verify

SELECT
'SQLT version number: '||sqltxplain.sqlt$a.get_param('tool_version')||CHR(10)||
'SQLT version date : '||sqltxplain.sqlt$a.get_param('tool_date')||CHR(10)||
'Installation date : '||sqltxplain.sqlt$a.get_param('install_date') sqlt_version
FROM DUAL;

output

SQL> SELECT
'SQLT version number: '||sqltxplain.sqlt$a.get_param('tool_version')||CHR(10)||
'SQLT version date : '||sqltxplain.sqlt$a.get_param('tool_date')||CHR(10)||
'Installation date : '||sqltxplain.sqlt$a.get_param('install_date') sqlt_version
FROM DUAL;  2    3    4    5

SQLT_VERSION
-----------------------------------------
SQLT version number: 12.1.14
SQLT version date : 2015-12-06
Installation date : 2016-10-17/12:20:51


SQL>

Reference:

FAQ: SQLT (SQLTXPLAIN) Frequently Asked Questions (Doc ID 1454160.1)
All About the SQLT Diagnostic Tool (Doc ID 215187.1)
SQLT Usage Instructions (Doc ID 1614107.1)

Caution: Your use of any information or materials on this website is entirely at your own risk. It is provided for educational purposes only. It has been tested internally, however, we do not guarantee that it will work for you. Ensure that you run it in your test environment before using.

Thank you,
Rajasekhar Amudala