Skip to main content
Version: NG-3.1

Oracle

Introduction

Oracle DB monitoring is the process of collecting and analyzing data about the performance of an Oracle database. This data can be used to identify potential performance problems and take corrective action to improve performance.

Getting Started

Compatibility

The Oracle O11ySource supports Oracle Database versions 11g and later.

Data Collection Method

vuSmartMaps collects health and performance data from Oracle server through a data collector deployed within the vuSmartMaps. Logs are collected using the log collection probe of the OmniAgent.

Prerequisites

Dependent Configuration

To configure this O11ySource, create a 'credential' of type 'user' under the 'Definition' tab.

Inputs for Configuring Data Source

  • Instance Name: Please enter the name of the Oracle instance. This should be a unique identifier for the specific Oracle deployment you want to monitor.
  • DB Details: Please provide the database details.
  • IP Address: The IP address must be a valid IP address.
  • Port: Please enter a valid port number.
  • Credential: This field is required.
  • DB Name: Please enter the name of the database to connect to.
nan
  • Oracle Log Path(s): Enter one or more full log file paths (comma-separated). Each path must be a valid Linux (/path/to/file) or Windows (C:\path\to\file) path, must not end with / or \, and may end with patterns like ., xyz?.log, or xyz*.
  • Metrics Collection Queries: These queries are used to collect Oracle server metrics.
  • Query: Enter the SQL query to execute for metric collection.
  • Polling Interval [seconds]: Defines how frequently Oracle metrics and queries are collected from the database.
  • Collection Offset [in seconds]: Specify the delay (in seconds) from the scheduled execution time to avoid simultaneous execution of queries.
  • Custom SQL Queries: Optional.
  • Query Name: Enter a unique query name (max 63 chars; letters/numbers/_/-).
  • Query Topic: This field is optional.
  • Encoding: Select the file encoding to correctly read logs that contain international characters. If no encoding is selected, plain (ASCII) will be used by default.
  • Max Bytes: The maximum number of bytes that a single log message can have. All bytes after max_bytes are discarded and not sent. This setting is especially useful for multiline log messages, which can get large. The default is 10MB (10485760).

Firewall Requirement

To collect data from this O11ySource, ensure the following ports are opened:

Source IPDestination IPDestination PortProtocolDirection
vuSmartMaps Collection/Ingress node IPIP address of the Oracle Database server1521TCPOutbound
IP address of the Oracle Database servervuSmartMaps Collection/Ingress node IP443*TCPInbound

*Before providing the firewall requirements, please update the port based on the customer environment.

Configuring the Target

Configure Metrics Collection from Oracle Server Metrics from Oracle Database are collected by establishing a JDBC connection to the server.

To get started, create a read-only vunet user with the required access on your Oracle Database server. Connect to your Oracle Database and execute the following commands to create the vunet user and grant the required permissions:

sqlplus sys/<PASSWORD>@<IPADDRESS>:<PORT>/<SERVICE_NAME> as SYSDBA
CREATE USER vunet IDENTIFIED BY <PASSWORD>;
GRANT CONNECT TO vunet;
GRANT SELECT ON sys.dba_data_files TO vunet;
GRANT SELECT ON sys.dba_free_space TO vunet;
GRANT SELECT ON sys.dba_hist_active_sess_history TO vunet;
GRANT SELECT ON sys.dba_hist_snapshot TO vunet;
GRANT SELECT ON sys.dba_hist_sqlstat TO vunet;
GRANT SELECT ON sys.dba_hist_sqltext TO vunet;
GRANT SELECT ON sys.dba_indexes TO vunet;
GRANT SELECT ON sys.dba_objects TO vunet;
GRANT SELECT ON sys.dba_scheduler_job_run_details TO vunet;
GRANT SELECT ON sys.dba_tablespace_usage_metrics TO vunet;
GRANT SELECT ON sys.dba_tablespaces TO vunet;
GRANT SELECT ON sys.dba_users TO vunet;
GRANT SELECT ON GV_$PROCESS TO vunet;
GRANT SELECT ON gv_$sysmetric TO vunet;
GRANT SELECT ON gv_$active_session_history TO vunet;
GRANT SELECT ON gv_$asm_diskgroup TO vunet;
GRANT SELECT ON gv_$event_name TO vunet;
GRANT SELECT ON gv_$instance TO vunet;
GRANT SELECT ON gv_$lock TO vunet;
GRANT SELECT ON gv_$locked_object TO vunet;
GRANT SELECT ON gv_$log_history TO vunet;
GRANT SELECT ON gv_$metric TO vunet;
GRANT SELECT ON gv_$pgastat TO vunet;
GRANT SELECT ON gv_$resource_limit TO vunet;
GRANT SELECT ON gv_$segment_statistics TO vunet;
GRANT SELECT ON gv_$session TO vunet;
GRANT SELECT ON gv_$sesstat TO vunet;
GRANT SELECT ON gv_$sgastat TO vunet;
GRANT SELECT ON gv_$sqlarea TO vunet;
GRANT SELECT ON gv_$statname TO vunet;
GRANT SELECT ON gv_$log TO vunet;
GRANT SELECT ON v_$resource_limit TO vunet;
GRANT SELECT ON v_$active_session_history TO vunet;
GRANT SELECT ON v_$archived_log TO vunet;
GRANT SELECT ON v_$asm_diskgroup TO vunet;
GRANT SELECT ON v_$event_name TO vunet;
GRANT SELECT ON v_$instance TO vunet;
GRANT SELECT ON v_$lock TO vunet;
GRANT SELECT ON v_$log TO vunet;
GRANT SELECT ON v_$log_history TO vunet;
GRANT SELECT ON v_$metric TO vunet;
GRANT SELECT ON v_$pgastat TO vunet;
GRANT SELECT ON v_$recovery_file_dest TO vunet;
GRANT SELECT ON v_$segment_statistics TO vunet;
GRANT SELECT ON v_$session TO vunet;
GRANT SELECT ON v_$session_longops TO vunet;
GRANT SELECT ON v_$sesstat TO vunet;
GRANT SELECT ON v_$sgastat TO vunet;
GRANT SELECT ON v_$sqlarea TO vunet;
GRANT SELECT ON v_$statname TO vunet;
GRANT SELECT ON gv_$instance TO vunet;

Verify that the Oracle user vunet can connect to the database using the specified password.

Configuration Steps

Metrics Collected

NameDescriptionData Type
@timestampThe event timestamp in string format, likely ISO-8601.String
timestampPrecise timestamp of the event, with milliseconds precision.DateTime64
targetThe target object or resource being monitored.String
db_nameDatabase Instance name of Oracle ServerString
typeThe type of metric or event.String
HOSTNAMEThe hostname of the Oracle server.String
METRIC_NAMEThe name of the metric (e.g., CPU usage, memory usage).String
METRIC_UNITThe unit of the metric (e.g., percentage, seconds).String
ORACLE_DOC_TYPEThe document type, used for classification.String
VALUEThe numeric value of the metric being measured.UInt64
nameName of the monitoring event or system.LowCardinality(String)
bu_idBusiness unit identifier.LowCardinality(String)
tenant_idTenant identifier in a multi-tenant environment.LowCardinality(String)
hostHostname or identifier of the Oracle instance.String
DatabaseNameThe name of the Oracle database being monitored.String
OwnerThe owner of the Oracle schema or object.String
databasenameA secondary or related database name.String
DB_ACCOUNT_CREATED_DATEThe creation date of the Oracle database account.String
DB_ACCOUNT_LOCK_DATEThe lock date for the Oracle database account.String
DB_USER_ACCOUNT_STATUSStatus of the Oracle database account (e.g., ACTIVE, LOCKED).String
DB_USERNAMEThe name of the user account.String
INSTANCE_NAMEThe name of the Oracle instance.LowCardinality(String)
INSTANCE_NUMBERInstance number in multi-instance setups (e.g., RAC).UInt64
OBJ_CREATED_TIMETime the Oracle object was created.Float64
OBJ_IDID of the Oracle object.Float64
OBJ_LAST_DDL_TIMELast DDL operation time on the object.Float64
OBJ_NAMEThe name of the Oracle object (e.g., table, index).LowCardinality(String)
OBJ_OWNEROwner of the object (e.g., schema owner).LowCardinality(String)
OBJ_STATUSStatus of the object (e.g., VALID, INVALID).LowCardinality(String)
OBJ_TYPEType of object (e.g., TABLE, INDEX).LowCardinality(String)
BLOCK_INST_IDInstance ID where a blocking session occurs.UInt64
BLOCK_SECONDS_IN_WAITTime in seconds the session has been waiting for the lock.UInt64
BLOCK_SERIALSerial number of the blocking session.UInt64
BLOCK_SQL_IDSQL ID of the blocking session.UInt64
BLOCK_WAIT_CLASSThe wait class of the blocking session (e.g., User I/O).String
LONGOPS_OPNAMEName of the long-running operation.String
LONGOPS_REMAINING_MINEstimated remaining time in minutes for the long-running operation.String
LONGOPS_SERIALSerial number for the long operation.Float64
LONGOPS_SIDSession ID of the long operation.Float32
LONGOPS_START_TIMEStart time of the long operation.String
LONGOPS_TOTAL_WORKTotal amount of work for the long operation.String
LONGOPS_WORK_DONE_SOFARAmount of work completed so far for the long operation.String
LOCKED_LOCK_MODEMode of the lock (e.g., Exclusive, Shared).String
LOCKED_OBJ_NAMEName of the locked object.String
LOCKED_OBJ_OWNEROwner of the locked object.LowCardinality(String)
LOCKED_OS_USERNAMEOS username of the user causing the lock.LowCardinality(String)
LOCKED_SIDSession ID of the locked session.Float64
LOCKED_USERNAMEOracle username causing the lock.LowCardinality(String)
SGA_FREE_SPACEFree space available in the System Global Area (SGA).Float64
SGA_NAMEName of the SGA component.String
SGA_TOTAL_SPACETotal space allocated to SGA.Float64
SGA_USED_PCTPercentage of SGA space used.UInt64
SGA_USED_SPACEAmount of SGA space used.Float64
INSTANCE_ACTIVE_STATEThe active state of the Oracle instance (e.g., OPEN, MOUNTED).LowCardinality(String)
INSTANCE_ARCHIVERIndicates whether the archiver is enabled or disabled.LowCardinality(String)
INSTANCE_DB_STATUSCurrent status of the database (e.g., OPEN, MOUNTED).LowCardinality(String)
INSTANCE_HOST_NAMEHostname of the server where the instance is running.String
INSTANCE_LOGINSNumber of logins to the instance.LowCardinality(String)
INSTANCE_ROLERole of the instance (e.g., PRIMARY, STANDBY).LowCardinality(String)
INSTANCE_STARTUP_TIMETime when the instance was started.String
INSTANCE_STATUSStatus of the instance (e.g., STARTED, STOPPED).LowCardinality(String)
INSTANCE_VERSIONVersion of the Oracle instance.String
PLAN_HASHHash value of the execution plan.UInt64
BLOCKING_SESSIONID of the session that is blocking this session.Float32
BLOCKING_SESSION_STATUSStatus of the blocking session (e.g., ACTIVE, INACTIVE).String
CPU_TIMETotal CPU time consumed by the session.Float64
ELAPSED_TIMETotal elapsed time of the session.UInt64
EVENT_IDID of the event being waited on.LowCardinality(String)
EVENTName of the event being waited on.String
EXECUTIONSNumber of times the SQL statement has been executed.UInt32
INST_IDInstance ID in a RAC (Real Application Clusters) environment.UInt32
MACHINEMachine name from which the session is connecting.String
MACHINE_SIDSession ID on the machine.String
PROGRAMName of the program connected to the instance.String
SAMPLE_TIMETime when the sample was taken.String
SESSION_SERIALNUMSerial number of the session.UInt32
SESSION_STATECurrent state of the session (e.g., ACTIVE, INACTIVE).LowCardinality(String)
SQL_EXEC_IDExecution ID for the SQL statement.UInt32
SQL_EXEC_STARTTimestamp when the SQL execution started.String
SQL_IDUnique identifier for the SQL statement.String
SQL_TYPEType of the SQL statement (e.g., SELECT, INSERT).String
TIME_WAITEDTotal time waited for events.UInt32
USER_IDID of the user connected to the session.UInt32
USERNAMEUsername of the connected user.String
WAIT_CLASSClass of wait event.String
WAIT_TIMETotal wait time.UInt32
USER_SESSION_COUNTCount of user sessions.UInt32
USER_SESSION_STATUSStatus of the user session (e.g., ACTIVE, INACTIVE).LowCardinality(String)
USER_SESSION_WAIT_CLASSWait class of the user session.LowCardinality(String)
SCHD_ACTUAL_START_DATEActual start date of the scheduled job.String
SCHD_ERROR_MSGError message associated with the scheduled job.String
SCHD_ERROR_NUMError number associated with the scheduled job.Float32
SCHD_JOBNAMEName of the scheduled job.String
SCHD_OUTPUT_MSGOutput message from the scheduled job.String
SCHD_OWNEROwner of the scheduled job.String
SCHD_RUN_DURATIONDuration of the scheduled job run.Float32
SCHD_STATUSStatus of the scheduled job (e.g., SUCCESS, FAILED).String
AGGREGATE_PGA_AUTO_TARGETTarget memory for Automatic PGA management.UInt64
AGGREGATE_PGA_TARGET_PARAMETERCurrent value of the target PGA memory.UInt64
PGA_CACHE_HIT_PERCENTAGEPercentage of hits in the PGA cache.UInt64
PGA_OVER_ALLOCATION_COUNTCount of times PGA was over-allocated.UInt32
TOTAL_FREEABLE_PGA_MEMORYTotal freeable memory in the PGA.UInt64
TOTAL_PGA_ALLOCATEDTotal PGA memory allocated.UInt64
TOTAL_PGA_INUSETotal PGA memory currently in use.UInt64
LONGQUERY_PHVLong query private hash value.UInt64
LONGQUERY_CHILDChild number for long-running queries.Float32
LONGQUERY_EVENTEvent associated with long-running queries.String
LONGQUERY_ICEIce for long queries (wait time, etc.).Float32
LONGQUERY_MACHINEMachine name for long queries.String
LONGQUERY_OSUSEROS username for long queries.String
LONGQUERY_PROGRAMProgram name for long queries.LowCardinality(String)
LONGQUERY_SERIALSerial number for long queries.UInt64
LONGQUERY_SIDSession ID for long queries.UInt32
LONGQUERY_SQL_IDSQL ID for long queries.String
LONGQUERY_STATEState of long queries.LowCardinality(String)
LONGQUERY_STATUSStatus of long queries.LowCardinality(String)
LONGQUERY_USERNAMEUsername for long queries.LowCardinality(String)
LONGQUERY_WAIT_CLASSWait class for long queries.LowCardinality(String)
FIELDS_ROW_WAIT_OBJIDObject ID for row waits.Float32
TBLS_CONTENTS_NAMEName of contents for tables.LowCardinality(String)
TBLS_NAMEName of the table.LowCardinality(String)
TBLS_SIZESize of the table.LowCardinality(String)
TBLS_STATUSStatus of the table (e.g., ACTIVE, INACTIVE).LowCardinality(String)
TBLS_USED_PERCENTPercentage of space used in the table.Float32
TBLS_USED_SPACEAmount of space used by the table.UInt64
REDO_ARCHIVEDIndicates if redo is archived.LowCardinality(String)
REDO_BYTES_MBAmount of redo in megabytes.LowCardinality(String)
REDO_GROUPGroup number for redo log.UInt64
REDO_MEMBERMember number for redo log.UInt64
REDO_SEQUENCESequence number for redo log.UInt32
REDO_STATUSStatus of the redo log.LowCardinality(String)
REDO_THREADThread number for redo log in a RAC environment.UInt16
RESOURCE_CURRENT_UTILIZATIONCurrent utilization of the resource.UInt32
RESOURCE_INITIAL_ALLOCATIONInitial allocation for the resource.UInt32
RESOURCE_LIMITLimit for the resource.LowCardinality(String)
RESOURCE_MAX_UTILIZATIONMaximum utilization of the resource.UInt32
RESOURCE_NAMEName of the resource.LowCardinality(String)
RESOURCE_USED_PCTPercentage of the resource that is used.Float32
@timestampOriginal timestamp as a string format for logging purposes.String
messageDetailed log message containing event or error information.String
_docDocument type or identifier used for indexing or classification.LowCardinality(String)
log_file_pathPath to the log file where the log entry was recorded.String
oradb_statusStatus indicator of the Oracle database (e.g., Online, Offline, Maintenance).String
categoryLog category indicating the type or nature of the log (e.g., Error, Warning, Info).String
priorityPriority level of the log (e.g., High, Medium, Low).LowCardinality(String)
ORACodeOracle error code (e.g., ORA-12345) associated with the log.String
db_serverName or identifier of the database server where the log entry was generated.LowCardinality(String)
targetTarget component or system referenced in the log.String
hostHostname or IP address of the server generating the log.String
timestampTimestamp in precise DateTime format with millisecond accuracy for better temporal queries.DateTime64(3)
typeType of the log or component (e.g., Application, Database, Network).LowCardinality(String)
NAMEName of the ASM diskgroup.String
FREE_MBAmount of free space in the ASM diskgroup in MB.UInt64
TOTAL_MBTotal size of the ASM diskgroup in MB.UInt64
REQUIRED_MIRROR_FREE_MBThe free space required for mirroring in the ASM diskgroup.UInt64
USABLE_FILE_MBUsable file space in the ASM diskgroup in MB.UInt64
PERCENTAGEPercentage of free space in the ASM diskgroup.Float64
FREE_BYTESFree space in the ASM diskgroup in bytes.UInt64
USED_MBAmount of used space in the ASM diskgroup in MB.UInt64
USED_BYTESAmount of used space in the ASM diskgroup in bytes.UInt64
TOTAL_BYTESTotal size of the ASM diskgroup in bytes.UInt64
USABLE_FILE_BYTESUsable file space in the ASM diskgroup in bytes.UInt64
STATEThe current state of the ASM diskgroup (e.g., MOUNTED, DISMOUNTED).String
REDUNDANCY_TYPEThe redundancy type of the ASM diskgroup (e.g., EXTERNAL, NORMAL, HIGH).String
QUERY_SIDThe session ID of the executing query.UInt64
QUERY_SERIALThe serial number of the executing query session.UInt64
QUERY_USERNAMEThe username associated with the executing query.String
QUERY_STATEThe current state of the session (e.g., WAITING, ACTIVE).String
QUERY_STATUSThe status of the session (e.g., OPEN, CLOSED).String
QUERY_EVENTThe event the session is waiting for.String
QUERY_PROGRAMThe program initiating the SQL query execution.String
QUERY_MACHINEThe machine where the session is executing.String
QUERY_OSUSERThe OS username for the session.String
QUERY_SQL_IDThe SQL ID of the executing query.String
QUERY_CHILDThe child number for the executing query.UInt64
QUERY_WAIT_CLASSThe wait class for the session's event (e.g., CPU, I/O).String
QUERY_PHVThe SQL plan hash value of the executing query.UInt64
QUERY_SQL_PROFILEThe SQL profile used by the query.String
QUERY_ICEThe total elapsed time in seconds for the query execution.UInt64
BLOCKING_SESS_IDThe session ID of the blocking session, if applicable.UInt64
BLOCKING_SESS_STATUSThe status of the blocking session.String
BLOCK_SESS_SEC_IN_WAITTime the blocking session has been in wait, in seconds.UInt64
ROW_WAIT_OBJIDThe object ID of the row being waited on.UInt64
LONGOPS_SQL_TXTSQL text of the long-running operationString
TOTAL_PGA_USED_PERCENTAGEShows the percentage of Oracle Program Global Area (PGA) memory currently being utilized compared to the configured PGA memory limit.Float64