DBCollect/Usage: Difference between revisions
No edit summary |
|||
Line 64: | Line 64: | ||
= Monitoring progress = | = Monitoring progress = | ||
Once {{dbcollect}} is running, it will pick up OS info, and after a few seconds it will start generating AWR reports. | |||
<syntaxhighlight lang=bash> | |||
[root@db08 ~](-) # dbcollect -o | |||
dbcollect 1.16.3 - collect Oracle AWR/Statspack, database and system info | |||
INFO : dbcollect 1.16.3 - database and system info collector | |||
INFO : Python version 3.6.8 | |||
INFO : Current user is oracle | |||
INFO : Zip file is /tmp/dbcollect-db08.lan.zip | |||
INFO : Collecting OS info (Linux) | |||
INFO : Collecting Linux SAR files | |||
INFO : Collecting Oracle info | |||
INFO : Detecting Oracle instances | |||
INFO : Stopped instances: demo81 | |||
INFO : Running instances: demo08 | |||
INFO : demo08: AWR usage detected, generating reports | |||
INFO : demo08: 25 reports | |||
INFO : demo08: Running opatch lspatches | |||
INFO : demo08: Running dbinfo scripts | |||
INFO : demo08: DBInfo processor finished, elapsed time 8.38 seconds | |||
INFO : demo08: Started 2 SQLPlus sessions | |||
Report 16 of 25 (64.0% done), elapsed: 0:00:30, remaining: 0:00:17, reports/s: 0.53 | |||
</syntaxhighlight> | |||
= Checking results = | = Checking results = |
Revision as of 12:38, 10 October 2024
Usage
Where to run
Where to run dbcollect
- All Database nodes (in scope of the project) including all RAC nodes and all Data Guard Standby nodes
- Optional: On all application nodes and hypervisors
- On non-database hosts, dbcollect will only pick up OS config and performance data
Short summary
If dbcollect is installed correctly:
# Simply run dbcollect
dbcollect
# Error: Zipfile already exists
# Overwrite previous zipfile
dbcollect --overwrite
# Error: No AWR or Statspack detected
# If you are sure the system is licensed with Diagnostics Pack
dbcollect --overwrite --force-awr
# If you want to retrieve more than 10 days worth of AWR files:
dbcollect --days 20
# Limit dbcollect to use only 2 tasks (CPUs) for AWR generation (default = 50% of CPUs, with a maximum of 8)
dbcollect --tasks 2
Resolve AWR reporting issues
dbcollect checks for prior AWR usage to make sure it will not trigger Oracle license violations ( More info)
If you get Error [DBC-E021] No AWR or Statspack detected:
# If you are sure you have Diagnostics Pack license:
dbcollect --force-awr
# If you want to ignore databases without AWR usage:
dbcollect --ignore-awr
# If the problem databases are not important, try excluding them:
dbcollect --exclude inst1,inst2
Oracle RAC
On RAC, dbcollect will generate AWR reports for all instances on all nodes. This means if you run dbcollect on all RAC nodes (which is recommended) then all AWR reports will be generated multiple times (2 times for a 2-node cluster). To avoid this, run with the --no-rac
option. This will cause AWR reports ONLY to be generated for the actual node, and saves on diskspace and resource overhead.
Oracle Data Guard
An Oracle instance that runs as Data Guard Standby is usually in MOUNT mode and does not allow AWR reports to be generated. Standby databases can be running in Real-Time Query or Real-Time Apply mode, but running standard AWR reports causes the AWR reports to be generated for the PRIMARY instance (there is no specific Standby performance data).
Data Guard can be configured with RMF (Remote Management Framework) which causes performance statistics to be collected for the STANDBY database.
dbcollect will pick up AWR reports for the STANDBY database if this is enabled. To disable this feature, use --no-stby
.
Monitoring progress
Once dbcollect is running, it will pick up OS info, and after a few seconds it will start generating AWR reports.
[root@db08 ~](-) # dbcollect -o
dbcollect 1.16.3 - collect Oracle AWR/Statspack, database and system info
INFO : dbcollect 1.16.3 - database and system info collector
INFO : Python version 3.6.8
INFO : Current user is oracle
INFO : Zip file is /tmp/dbcollect-db08.lan.zip
INFO : Collecting OS info (Linux)
INFO : Collecting Linux SAR files
INFO : Collecting Oracle info
INFO : Detecting Oracle instances
INFO : Stopped instances: demo81
INFO : Running instances: demo08
INFO : demo08: AWR usage detected, generating reports
INFO : demo08: 25 reports
INFO : demo08: Running opatch lspatches
INFO : demo08: Running dbinfo scripts
INFO : demo08: DBInfo processor finished, elapsed time 8.38 seconds
INFO : demo08: Started 2 SQLPlus sessions
Report 16 of 25 (64.0% done), elapsed: 0:00:30, remaining: 0:00:17, reports/s: 0.53
Checking results
Running unattended
aaa