Get comprehensive insights into your Amazon RDS Oracle Database performance with database monitoring, query analysis, and system health metrics using the New Relic Distribution of OpenTelemetry (NRDOT) collector.
Guided installation
To install through the New Relic UI instead, go to one.newrelic.com > Integrations & Agents > Oracle (OpenTelemetry) . This page covers manual installation only.
Prerequisites
Before you begin, ensure you have the following:
- A valid New Relic license key
- Supported architecture: Linux with AMD64 and ARM64
- Network connectivity to New Relic OTLP endpoint
- Oracle Database
19cor later
Install NRDOT Collector
Select the appropriate installation distribution method for your Linux environment:
Configure database user
Create a monitoring user with necessary privileges for your RDS Oracle Database.
Log in to the root database as an administrator:
CREATE USER <YOUR_DB_USERNAME> IDENTIFIED BY "<YOUR_DB_PASSWORD>";Grant
CONNECTprivileges to the newly created user:GRANT CONNECT TO <YOUR_DB_USERNAME>;
Grant monitoring privileges for RDS database
Execute the following SQL statements to grant monitoring privileges. Replace <YOUR_DB_USERNAME_UPPERCASE> with your username in uppercase:
EXEC rdsadmin.rdsadmin_util.grant_sys_object('V_$SYSMETRIC', '<YOUR_DB_USERNAME_UPPERCASE>', 'SELECT', false);EXEC rdsadmin.rdsadmin_util.grant_sys_object('V_$CON_SYSMETRIC', '<YOUR_DB_USERNAME_UPPERCASE>', 'SELECT', false);EXEC rdsadmin.rdsadmin_util.grant_sys_object('V_$CONTAINERS', '<YOUR_DB_USERNAME_UPPERCASE>', 'SELECT', false);EXEC rdsadmin.rdsadmin_util.grant_sys_object('V_$SESSION', '<YOUR_DB_USERNAME_UPPERCASE>', 'SELECT', false);EXEC rdsadmin.rdsadmin_util.grant_sys_object('V_$SESSION_EVENT', '<YOUR_DB_USERNAME_UPPERCASE>', 'SELECT', false);EXEC rdsadmin.rdsadmin_util.grant_sys_object('V_$SYSSTAT', '<YOUR_DB_USERNAME_UPPERCASE>', 'SELECT', false);EXEC rdsadmin.rdsadmin_util.grant_sys_object('V_$CON_SYSSTAT', '<YOUR_DB_USERNAME_UPPERCASE>', 'SELECT', false);EXEC rdsadmin.rdsadmin_util.grant_sys_object('V_$OSSTAT', '<YOUR_DB_USERNAME_UPPERCASE>', 'SELECT', false);EXEC rdsadmin.rdsadmin_util.grant_sys_object('V_$SGAINFO', '<YOUR_DB_USERNAME_UPPERCASE>', 'SELECT', false);EXEC rdsadmin.rdsadmin_util.grant_sys_object('V_$SQL', '<YOUR_DB_USERNAME_UPPERCASE>', 'SELECT', false);EXEC rdsadmin.rdsadmin_util.grant_sys_object('V_$SQL_PLAN_STATISTICS_ALL', '<YOUR_DB_USERNAME_UPPERCASE>', 'SELECT', false);EXEC rdsadmin.rdsadmin_util.grant_sys_object('V_$PROCESS', '<YOUR_DB_USERNAME_UPPERCASE>', 'SELECT', false);EXEC rdsadmin.rdsadmin_util.grant_sys_object('V_$TRANSACTION', '<YOUR_DB_USERNAME_UPPERCASE>', 'SELECT', false);EXEC rdsadmin.rdsadmin_util.grant_sys_object('V_$PARAMETER', '<YOUR_DB_USERNAME_UPPERCASE>', 'SELECT', false);EXEC rdsadmin.rdsadmin_util.grant_sys_object('V_$ROWCACHE', '<YOUR_DB_USERNAME_UPPERCASE>', 'SELECT', false);EXEC rdsadmin.rdsadmin_util.grant_sys_object('V_$RESOURCE_LIMIT', '<YOUR_DB_USERNAME_UPPERCASE>', 'SELECT', false);EXEC rdsadmin.rdsadmin_util.grant_sys_object('V_$LOCK', '<YOUR_DB_USERNAME_UPPERCASE>', 'SELECT', false);EXEC rdsadmin.rdsadmin_util.grant_sys_object('V_$DATABASE', '<YOUR_DB_USERNAME_UPPERCASE>', 'SELECT', false);EXEC rdsadmin.rdsadmin_util.grant_sys_object('V_$INSTANCE', '<YOUR_DB_USERNAME_UPPERCASE>', 'SELECT', false);EXEC rdsadmin.rdsadmin_util.grant_sys_object('V_$DATAFILE', '<YOUR_DB_USERNAME_UPPERCASE>', 'SELECT', false);EXEC rdsadmin.rdsadmin_util.grant_sys_object('V_$PDBS', '<YOUR_DB_USERNAME_UPPERCASE>', 'SELECT', false);EXEC rdsadmin.rdsadmin_util.grant_sys_object('DBA_DATA_FILES', '<YOUR_DB_USERNAME_UPPERCASE>', 'SELECT', false);EXEC rdsadmin.rdsadmin_util.grant_sys_object('DBA_FREE_SPACE', '<YOUR_DB_USERNAME_UPPERCASE>', 'SELECT', false);EXEC rdsadmin.rdsadmin_util.grant_sys_object('DBA_RECYCLEBIN', '<YOUR_DB_USERNAME_UPPERCASE>', 'SELECT', false);EXEC rdsadmin.rdsadmin_util.grant_sys_object('DBA_TABLESPACES', '<YOUR_DB_USERNAME_UPPERCASE>', 'SELECT', false);EXEC rdsadmin.rdsadmin_util.grant_sys_object('DBA_TABLESPACE_USAGE_METRICS', '<YOUR_DB_USERNAME_UPPERCASE>', 'SELECT', false);EXEC rdsadmin.rdsadmin_util.grant_sys_object('DBA_PROCEDURES', '<YOUR_DB_USERNAME_UPPERCASE>', 'SELECT', false);EXEC rdsadmin.rdsadmin_util.grant_sys_object('DBA_OBJECTS', '<YOUR_DB_USERNAME_UPPERCASE>', 'SELECT', false);EXEC rdsadmin.rdsadmin_util.grant_sys_object('CDB_TABLESPACE_USAGE_METRICS', '<YOUR_DB_USERNAME_UPPERCASE>', 'SELECT', false);EXEC rdsadmin.rdsadmin_util.grant_sys_object('CDB_TABLESPACES', '<YOUR_DB_USERNAME_UPPERCASE>', 'SELECT', false);EXEC rdsadmin.rdsadmin_util.grant_sys_object('CDB_SERVICES', '<YOUR_DB_USERNAME_UPPERCASE>', 'SELECT', false);GRANT CREATE SESSION TO <YOUR_DB_USERNAME_UPPERCASE>;Configure NRDOT Collector
Configure the NRDOT Collector with your RDS-specific settings.
Create the configuration file. The filename must be
oracle-config.yaml.bash$sudo nano /etc/nrdot-collector/oracle-config.yamlAdd the configuration content below to the
oracle-config.yamlfile you created in the previous step.full configuration
This configuration captures essential baseline metrics. To see the complete metric catalog, refer to the configuration reference.
oracle-config.yaml1receivers:2nroracledb/rds:3endpoint: mydb-instance.xxxxxxxxxxxx.us-east-1.rds.amazonaws.com:15214username: newrelic5password: YOUR_PASSWORD6service: YOUR_SERVICE_NAME7collection_interval: 15s8events:9db.server.query_sample:10enabled: true11db.server.top_query:12enabled: true13db.server.session.wait_sample:14enabled: true15db.server.top_procedure:16enabled: true17db.server.query_plan:18enabled: true1920top_query_collection:21max_query_sample_count: 100022top_query_count: 20023collection_interval: 60s24allowed_comment_keys:25- nr_service_guid2627query_sample_collection:28max_rows_per_query: 10029allowed_comment_keys:30- nr_service_guid3132session_wait_event_collection:33max_rows_per_query: 1003435top_procedure_collection:36max_procedure_sample_count: 100037top_procedure_count: 25038collection_interval: 60s3940# Metrics configuration - This baseline configuration captures essential metrics. To enable advanced monitoring and extended telemetry, refer to the full configuration documentation41metrics:42oracledb.buffer_cache.utilization:43enabled: true44attributes:45- oracle.db.pdb46oracledb.consistent_gets:47enabled: true48attributes:49- oracle.db.pdb50oracledb.cpu_time:51enabled: true52attributes:53- oracle.db.pdb54oracledb.database.cpu.utilization:55enabled: true56attributes:57- oracle.db.pdb58oracledb.database.wait.utilization:59enabled: true60attributes:61- oracle.db.pdb62oracledb.db_block_gets:63enabled: true64attributes:65- oracle.db.pdb66oracledb.enqueue_deadlocks:67enabled: true68attributes:69- oracle.db.pdb70oracledb.execution.utilization:71enabled: true72attributes:73- oracledb.parse.type74- oracle.db.pdb75oracledb.executions:76enabled: true77attributes:78- oracle.db.pdb79oracledb.hard_parses:80enabled: true81attributes:82- oracle.db.pdb83oracledb.host.cpu.utilization:84enabled: true85attributes:86- oracle.db.pdb87oracledb.library_cache.utilization:88enabled: true89attributes:90- oracle.db.pdb91oracledb.logical_reads:92enabled: true93attributes:94- oracle.db.pdb95oracledb.logons:96enabled: true97attributes:98- oracle.db.pdb99oracledb.parse.rate:100enabled: true101attributes:102- oracledb.parse.result103- oracle.db.pdb104oracledb.parse_calls:105enabled: true106attributes:107- oracle.db.pdb108oracledb.pga_memory:109enabled: true110attributes:111- oracle.db.pdb112oracledb.physical_io.requests:113enabled: true114attributes:115- disk.io.direction116- disk.io.block_size117- oracle.db.pdb118oracledb.physical_reads:119enabled: true120attributes:121- oracle.db.pdb122oracledb.physical_writes:123enabled: true124attributes:125- oracle.db.pdb126oracledb.processes.usage:127enabled: true128oracledb.sessions.usage:129enabled: true130attributes:131- session_type132- session_status133- oracle.db.pdb134oracledb.sga.usage:135enabled: true136attributes:137- oracledb.sga.component.name138oracledb.shared_pool.utilization:139enabled: true140attributes:141- oracle.db.pdb142oracledb.sql_service.response.duration:143enabled: true144attributes:145- oracle.db.pdb146oracledb.sqlnet.io.transferred:147enabled: true148attributes:149- network.io.direction150- destination.type151- oracle.db.pdb152oracledb.tablespace_size.usage:153enabled: true154attributes:155- tablespace_name156- oracle.db.pdb157oracledb.transactions.usage:158enabled: true159oracledb.user_commits:160enabled: true161attributes:162- oracle.db.pdb163oracledb.user_rollbacks:164enabled: true165attributes:166- oracle.db.pdb167168# Resource attributes attached to all metrics/logs (all enabled by default)169resource_attributes:170oracle.db.edition:171enabled: true172exporters:173otlp/newrelic:174endpoint: https://otlp.nr-data.net:4318175headers:176api-key: YOUR_LICENSE_KEY177compression: gzip178retry_on_failure:179enabled: true180initial_interval: 5s181max_interval: 30s182max_elapsed_time: 300s183sending_queue:184enabled: true185sizer: bytes186queue_size: 100_000_000187num_consumers: 10188batch:189sizer: bytes190max_size: 1_000_000191min_size: 0192flush_timeout: 5s193service:194pipelines:195metrics/oracledb:196receivers: [nroracledb/rds]197exporters: [otlp/newrelic]198logs/oracledb:199receivers: [nroracledb/rds]200exporters: [otlp/newrelic]Under the Events section, enable these event types to collect their metrics:
Event
Description
db.server.query_samplePer-session active query samples capturing current SQL, wait state, and blocking details.
db.server.top_queryTop N SQL statements by CPU or elapsed time, including execution stats and query plans.
db.server.session.wait_samplePer-session cumulative wait counts and durations from
v$session_event.db.server.top_procedureTop N stored procedures ranked by resource usage, including execution stats.
db.server.query_planExecution plan details for top and sampled queries.
Configure the collection settings for each event type:
Configuration section
Parameter
Value
top_query_collectionmax_query_sample_count1000
top_query_collectiontop_query_count200
top_query_collectioncollection_interval60s
query_sample_collectionmax_rows_per_query100
session_wait_event_collectionmax_rows_per_query100
top_procedure_collectionmax_procedure_sample_count1000
top_procedure_collectiontop_procedure_count250
top_procedure_collectioncollection_interval60s
Update NRDOT Collector configuration
Update the NRDOT Collector configuration to use your oracle-config.yaml file.
$sudo sed -i 's|OTELCOL_OPTIONS="--config=/etc/nrdot-collector/config.yaml"|OTELCOL_OPTIONS="--config=/etc/nrdot-collector/oracle-config.yaml"|' /etc/nrdot-collector/nrdot-collector.confDica
You can also:
- Configure multiple receivers: To monitor multiple Oracle Database instances from one collector.
- Configure SQL Query Receiver: To collect custom metrics from your Oracle Database.
- Link your Oracle Database with APM: To correlate your application performance with database operations. This allows you to see exactly which applications are generating specific database workloads.
- Set up secret management: To securely manage sensitive information, such as database credentials. This helps to enhance the security of your monitoring setup by avoiding hardcoding sensitive data in configuration files.
Restart NRDOT Collector
After updating your configuration, restart the NRDOT Collector:
$sudo systemctl restart nrdot-collector.service$sudo systemctl status nrdot-collector.serviceDica
Always restart the NRDOT Collector after making configuration changes to ensure the new settings take effect.
Find and use your data
Once your data is being collected, you can access comprehensive Oracle Database monitoring through the New Relic UI.
To find your Oracle Database entity in New Relic:
- Go to https://one.newrelic.com > All Capabilities > Databases.
- Set the search criteria as
instrumentation.provider = opentelemetry. - Select your Oracle Database from the list of entities.