Expdp - AWR dump example awrextr.sql
SQL> start $ORACLE_HOME/rdbms/admin/awrextr.sql
~~~~~~~~~~~~~
AWR EXTRACT
~~~~~~~~~~~~~
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
~ This script will extract the AWR data for a range of snapshots ~
~ into a dump file. The script will prompt users for the ~
~ following information: ~
~ (1) database id ~
~ (2) snapshot range to extract ~
~ (3) name of directory object ~
~ (4) name of dump file ~
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
Databases in this Workload Repository schema
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
DB Id DB Name Host
------------ ------------ ------------
* 123456 Test_db Test_hostname
The default database id is the local one: '123456'. To use this
database id, press <return> to continue, otherwise enter an alternative.
Enter value for dbid: 123456
Using 123456 for Database ID
Specify the number of days of snapshots to choose from
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
Entering the number of days (n) will result in the most recent
(n) days of snapshots being listed. Pressing <return> without
specifying a number lists all completed snapshots.
Enter value for num_days: 2
Listing the last 2 days of Completed Snapshots
DB Name Snap Id Snap Started
------------ --------- ------------------
Test_db 44424 07 Sep 2022 00:00
44425 07 Sep 2022 01:00
44426 07 Sep 2022 02:00
44427 07 Sep 2022 03:00
44428 07 Sep 2022 04:00
44429 07 Sep 2022 05:01
44430 07 Sep 2022 06:00
44431 07 Sep 2022 07:00
44432 07 Sep 2022 08:00
44433 07 Sep 2022 09:00
44434 07 Sep 2022 10:00
DB Name Snap Id Snap Started
------------ --------- ------------------
Test_db 44435 07 Sep 2022 11:00
44436 07 Sep 2022 12:00
44437 07 Sep 2022 13:00
44438 07 Sep 2022 14:00
44439 07 Sep 2022 15:00
44440 07 Sep 2022 16:00
44441 07 Sep 2022 17:00
44442 07 Sep 2022 18:00
44443 07 Sep 2022 19:00
44444 07 Sep 2022 20:00
44445 07 Sep 2022 21:00
DB Name Snap Id Snap Started
------------ --------- ------------------
Test_db 44446 07 Sep 2022 22:00
44447 07 Sep 2022 23:00
44448 08 Sep 2022 00:00
44449 08 Sep 2022 01:00
44450 08 Sep 2022 02:00
44451 08 Sep 2022 03:00
44452 08 Sep 2022 04:00
44453 08 Sep 2022 05:00
44454 08 Sep 2022 06:00
44455 08 Sep 2022 07:00
44456 08 Sep 2022 08:00
DB Name Snap Id Snap Started
------------ --------- ------------------
Test_db 44457 08 Sep 2022 09:00
44458 08 Sep 2022 10:00
44459 08 Sep 2022 11:00
44460 08 Sep 2022 12:00
44461 08 Sep 2022 13:00
44462 08 Sep 2022 14:00
44463 08 Sep 2022 15:00
44464 08 Sep 2022 16:00
44465 08 Sep 2022 17:00
44466 08 Sep 2022 18:00
Specify the Begin and End Snapshot Ids
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
Enter value for begin_snap: 44457
Begin Snapshot Id specified: 44457
Enter value for end_snap: 44466
End Snapshot Id specified: 44466
Specify the Directory Name
~~~~~~~~~~~~~~~~~~~~~~~~~~
Directory Name Directory Path
------------------------------ -------------------------------------------------
DATA_PUMP_DIR <location>/Test_dbdump/exp
DATA_PUMP_DIR <location>/Test_dbdump/exp
Directory Name Directory Path
------------------------------ -------------------------------------------------
DATA_PUMP_DIR <location>/Test_dbdump/exp
DATA_PUMP_DIR <location>/Test_dbdump/exp
Choose a Directory Name from the above list (case-sensitive).
Enter value for directory_name: DATA_PUMP_DIR
Using the dump directory: DATA_PUMP_DIR
Specify the Name of the Extract Dump File
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
The prefix for the default dump file name is awrdat_44457_44466.
To use this name, press <return> to continue, otherwise enter
an alternative.
Enter value for file_name: awrdat_44457_44466
Using the dump file prefix: awrdat_44457_44466
|
| ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
| The AWR extract dump file will be located
| in the following directory/file:
| <location>/Test_dbdump/exp
| awrdat_44457_44466.dmp
| ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
|
| *** AWR Extract Started ...
|
| This operation will take a few moments. The
| progress of the AWR extract operation can be
| monitored in the following directory/file:
| <location>/Test_dbdump/exp
| awrdat_44457_44466.log
|
End of AWR Extract
SQL> exit
No comments:
Post a Comment