7 Monitoring Commands

You can use the monitoring commands to check the Oracle Key Vault configuration, health, and deployment modes.

7.1 okv cluster info get Command

The okv cluster info get command retrieves status information about a cluster or a cluster node.

okv cluster info get retrieves the following information:

  • Cluster name
  • Cluster version
  • Maximum Disable Node Duration setting
  • List of cluster subgroups
  • Information of cluster nodes including their configuration mode, status, subgroup, version information, and so on.

Required Authorization

System Administrator role

Syntax

okv cluster info get --node node_name

JSON Input File Template

{
  "service" : {
    "category" : "cluster",
    "resource" : "info",
    "action" : "get",
    "options" : {
      "node" : "#VALUE"
    }
  }
}

Parameters

Parameter/Template Parameter Required? Description

--node / node

Optional

Name of the node within the current cluster. If you omit this setting, then information for the entire cluster is retrieved.

JSON Example

  1. Generate JSON input for the okv cluster info get command.
    okv cluster info get --generate-json-input

    The generated input appears as follows:

    {
      "service" : {
        "category" : "cluster",
        "resource" : "info",
        "action" : "get",
        "options" : {
          "node" : "#VALUE"
        }
      }
    }
  2. Save the generated input to a file (for example, get_cluster_info.json).

    Depending on the kind of information that you want to find, do one of the following:

    • Get cluster information for a specific node: Edit the file to specify the node value. For example:
      {
        "service" : {
          "category" : "cluster",
          "resource" : "info",
          "action" : "get",
          "options" : {
            "node" : "node_1"
          }
        }
      }
    • Get cluster information for all nodes in the cluster: Edit the file to remove the node entry.
      {
        "service" : {
          "category" : "cluster",
          "resource" : "info",
          "action" : "get"
        }
      }
  3. Run the okv cluster info get command using the generated JSON file.
    okv cluster info get --from-json get_cluster_info.json

    Depending on how you handled the file in Step 2, output similar to the following appears.

    • Get cluster information for a specific node:
      {
        "result" : "Success",
        "value" : {
          "clusterSubgroup" : "subgrp1",
          "disableDate" : "",
          "ipAddress" : "192.0.2.114",
          "joinDate" : "2021-06-16 06:57:45",
          "mode" : "Read-Write",
          "nodeID" : "1",
          "nodeName" : "node1",
          "readWritePeer" : "node2",
          "status" : "ACTIVE",
          "version" : "21.2.0.0.0"
        }
      }
    • Get cluster information for all nodes in the cluster:
      {
        "result" : "Success",
        "value" : {
          "clusterName" : "cluster1",
          "clusterSubgroups" : [ "subgrp1", "subgrp2" ],
          "clusterVersion" : "21.2.0.0.0",
          "maximumDisableNodeDuration" : "24 hrs",
          "nodes" : [ {
            "nodeName" : "node1",
            "nodeID" : "1",
            "ipAddress" : "192.0.2.114",
            "mode" : "Read-Write",
            "status" : "ACTIVE",
            "readWritePeer" : "node2",
            "clusterSubgroup" : "subgrp1",
            "joinDate" : "2021-06-16 06:57:45",
            "disableDate" : "",
            "version" : "21.2.0.0.0"
          }, {
            "nodeName" : "node2",
            "nodeID" : "2",
            "ipAddress" : "192.0.2.115",
            "mode" : "Read-Write",
            "status" : "ACTIVE",
            "readWritePeer" : "node1",
            "clusterSubgroup" : "subgrp2",
            "joinDate" : "2021-06-16 07:05:34",
            "disableDate" : "",
            "version" : "21.2.0.0.0"
          } ]
        }
      }

7.2 okv cluster status get Command

The okv cluster status get command retrieves dynamic information about the cluster or the specified cluster node.

okv cluster status get retrieves the following information:

  • Nodes that are read-write pairs
  • Nodes that are read-only pairs
  • The number and type of unresolved name conflicts
  • Alerts that are related to the cluster

Required Authorization

System Administrator role

Syntax

okv cluster status get --node node_name

JSON Input File Template

{
  "service" : {
    "category" : "cluster",
    "resource" : "status",
    "action" : "get",
    "options" : {
      "node" : "#VALUE"
    }
  }
}

Parameters

Parameter/Template Parameter Required? Description

--node / node

Optional

Name of the node within the current cluster. If you omit this setting, then information for the entire cluster is retrieved.

JSON Example

  1. Generate JSON input for the okv cluster status get command.
    okv cluster status get --generate-json-input

    The generated input appears as follows:

    {
      "service" : {
        "category" : "cluster",
        "resource" : "status",
        "action" : "get",
        "options" : {
          "node" : "#VALUE"
        }
      }
    }
  2. Save the generated input to a file (for example, get_cluster_status.json).

    Depending on the kind of information that you want to find, do one of the following:

    • Get cluster status for a specific node: Edit the file to specify the node value. For example:
      {
        "service" : {
          "category" : "cluster",
          "resource" : "status",
          "action" : "get",
          "options" : {
            "node" : "node_1"
          }
        }
      }
    • Get the status of the cluster: Edit the file to remove the node entry.
      {
        "service" : {
          "category" : "cluster",
          "resource" : "status",
          "action" : "get"
        }
      }
  3. Run the okv cluster status get command using the generated JSON file.
    okv cluster status get --from-json get_cluster_status.json

    Depending on how you handled the file in Step 2, output similar to the following appears.

    • Get cluster status for a specific node:
      {
        "result" : "Success",
        "value" : {
          "mode" : "Read-Write",
          "nameResolutionTime" : "Could not determine",
          "nodeID" : 1,
          "nodeName" : "node1",
          "status" : "ACTIVE"
        }
      }
    • Get the status of the cluster:
      {
        "result" : "Success",
        "value" : {
          "alertsCount" : "1",
          "clusterServiceStatus" : "Up",
          "nodes" : [ {
            "nodeID" : "1",
            "nodeName" : "node1",
            "mode" : "Read-Write",
            "status" : "ACTIVE",
            "nameResolutionTime" : "Could not determine"
          }, {
            "nodeID" : "2",
            "nodeName" : "node2",
            "mode" : "Read-Write",
            "status" : "ACTIVE",
            "nameResolutionTime" : "119.98 sec(s)"
          } ],
          "unresolvedConflicts" : {
            "endpointNameConflicts" : "0",
            "endpointGroupNameConflicts" : "0",
            "userNameConflicts" : "0",
            "userGroupNameConflicts" : "0",
            "walletNameConflicts" : "0",
            "kmipObjectNameConflicts" : "0"
          }
        }
      }

7.3 okv primary-standby info get Command

The okv primary-standby info get command displays static information about the Oracle Key Vault primary-standby configuration.

okv primary-standby info retrieves the following information:

  • The primary-standby status
  • The primary server IP address
  • The standby server IP address
  • The fast-start failover threshold value

Required Authorization

System Administrator role

Syntax

okv primary-standby info get 

JSON Input File Template

{
  "service" : {
    "category" : "primary-standby",
    "resource" : "info",
    "action" : "get"
  }
}

Parameters

None

JSON Example

  1. Generate JSON input for the okv primary-standby info get command.
    okv primary-standby info get --generate-json-input

    The generated input appears as follows:

    {
      "service" : {
        "category" : "primary-standby",
        "resource" : "info",
        "action" : "get"
      }
    }
  2. Save the output to a file (for example, primary_standby_info.json).
  3. Run the okv primary-standby info get command using the generated JSON file.
    okv primary-standby info get --from-json primary_standby_info.json

    Output similar to the following appears:

    {
      "result" : "Success",
      "value" : {
        "fsfo" : "60",
        "primaryIPAddress" : "192.0.2.114",
        "primaryStandbyStatus" : "Primary",
        "standbyIPAddress" : "192.0.2.115"
      }
    }

7.4 okv primary-standby status get Command

The okv primary-standby status get command retrieves dynamic information about the Oracle Key Vault primary-standby configuration.

okv primary-standby status get get retrieves the following information:

  • The switchover status
  • The failover status
  • Whether the primary is in read-only restricted mode

Required Authorization

System Administrator role

Syntax

okv primary-standby status get

JSON Input File Template

  "service" : {
    "category" : "primary-standby",
    "resource" : "status",
    "action" : "get"
  }
}

Parameters

None

JSON Example

  1. Generate JSON input for the okv primary-standby status get command.
    okv primary-standby status get --generate-json-input

    The generated input appears as follows:

      "service" : {
        "category" : "primary-standby",
        "resource" : "status",
        "action" : "get"
      }
    }
  2. Save the generated input to a file (for example, primary_standby_status.json).
  3. Run the okv primary-standby status get command using the generated JSON file.
    okv primary-standby status get --from-json primary_standby_status.json

    Output similar to the following appears:

    {
      "result" : "Success",
      "value" : {
        "failoverStatus" : "SYNCHRONIZED",
        "rormMode" : "No",
        "switchoverStatus" : "TO STANDBY"
      }
    }

7.5 okv server info get Command

The okv server info get command retrieves static information about an Oracle Key Vault server.

okv server info get displays the following:

  • The current version of the Oracle Key Vault server
  • The Oracle Key Vault server certification expiration date
  • The deployment type of the Oracle Key Vault server, such as standalone, cluster, or primary-standby

Required Authorization

System Administrator role

Syntax

okv server info get 

JSON Input File Template

{
  "service" : {
    "category" : "server",
    "resource" : "info",
    "action" : "get"
  }
}

Parameters

None

JSON Example

  1. Generate JSON input for the okv server info get command.
    okv server info get --generate-json-input

    The generated input appears as follows:

    {
      "service" : {
        "category" : "server",
        "resource" : "info",
        "action" : "get"
      }
    }
  2. Save the generated input to a file (for example, server_info_get.json). You do not need to edit the file because it has no parameters to modify.
  3. Run the okv server info get command using the generated JSON file.
    okv server info get --from-json server_info_get.json

    Output similar to the following appears:

    {
      "result" : "Success",
      "value" : {
       "caCertificateExpirationDate" : "2022-06-01 08:08:50",
       "cpu" : "4 Cores",
       "deploymentType" : "Cluster",
       "disk" : "293GB",
       "fra" : "20GB",
       "memory" : "7.49GB",
       "serverCertificateExpirationDate" : "2025-05-29 18:34:07",
       "serverTime" : "2023-05-30 18:34:28",
       "version" : "21.5.0.0.0"
       }
      }
    }

    All dates are shown in UTC.

7.6 okv server status get Command

The okv server status get command retrieves status information about an Oracle Key Vault server.

okv server status get displays the following:

  • The amount of time (uptime) that the Oracle Key Vault has been running
  • How much current free space is left on the Oracle Key Vault server
  • The status of any backup jobs that have been started for Oracle Key Vault
  • Number of alerts that have been raised concerning the Oracle Key Vault system
  • Current CPU usage percentage and number of CPU cores installed on the Oracle Key Vault server
  • Current disk space usage percentage and amount in GB and total disk space in GB on the Oracle Key Vault server
  • Current Fast Recovery Area (FRA) space usage percentage, amount in GB, and total space in GB for FRA on the Oracle Key Vault server
  • Current memory usage percentage, amount in KB, and total memory amount in KB installed on the Oracle Key Vault server
  • Status of services running on the Oracle Key Vault server

Required Authorization

System Administrator role

Syntax

okv server status get 

JSON Input File Template

{
 "service" : {
  "category" : "server",
  "resource" : "status",
  "action" : "get"
  }
}

Parameters

None

JSON Example

  1. Generate JSON input for the okv server status get command.
    okv server status get --generate-json-input

    The generated input appears as follows:

    {
     "service" : {
      "category" : "server",
      "resource" : "status",
      "action" : "get"
      }
    }
  2. Save the generated input to a file (for example, server_status.json).
  3. Run the okv server status get command using the generated JSON file.
    okv server status get --from-json server_status.json

    Output similar to the following appears:

    {
      "result" : "Success",
      "value" : {
        "alertsRaised" : "1",
        "backupStatus" : "25 day(s) since successful backup",
        "cpu" : {
          "usagePercentage" : "2",
          "cpuCores" : "16"
        },
        "disk" : {
          "usagePercentage" : "14",
          "usedInGB" : "42",
          "totalInGB" : "293"
        },
        "fra" : {
          "usagePercentage" : "20",
          "usedInGB" : "4",
          "totalInGB" : "20"
        },
        "freeSpacePercentage" : "86",
        "memory" : {
          "usagePercentage" : "98",
          "usedInKB" : "7655964",
          "totalInKB" : "7847768"
        },
        "services" : {
          "RESTfulService" : "Up",
          "emailService" : "Up",
          "KMIPService" : "Up",
          "storageDB" : "Up",
          "auditVaultAgentMonitor" : "Not enabled"
        },
        "uptime" : "11:59 HH:MM"
      }
    }

7.7 okv metrics server get Command

The okv metrics server get command retrieves System Metrics information of an Oracle Key Vault server.

Installed resources on an Oracle Key Vault server shown under reserved resources, including:

  • Number of CPU Cores
  • Total amount of memory installed in KB

Note:

There can be multiple entries for reserved resources in case there's a change in resources installed or an Oracle Key Vault server reboot.
Metrics details of Oracle Key Vault server:
  • CPU Utilization Percentage
  • CPU load averages from last one, five and fifteen minutes
  • Free Memory in KB

Required Authorization

System Administrator role

Syntax

okv metrics server get

JSON Input File Template

{
 "service" : {
  "category" : "metrics",
  "resource" : "server",
  "action" : "get",
  "options" : {
   "startTime" : "#YYYY-MM-DD hh:mm:ss",
   "endTime" : "#NOW|YYYY-MM-DD hh:mm:ss",
   "interval" : "#VALUE",
   "statistic" : "#MEAN|MAX|MIN",
   "include" : [ "ALL" ],
   "limit" : "#VALUE"
   }
  }
 }

Parameters

Parameter/Template Parameter Required? Description
--start-time

Optional

Specifies the start time for which results should be returned. It should be entered as timestamp in "YYYY-MM-DD HH:mm:ss" format.

Example: Timestamp : YYYY-MM-DD HH:mm:ss

--end-time

Optional

The end time for which results should be returned.

Example: Timestamp : YYYY-MM-DD HH:mm:ss or NOW.

--interval

Optional

Specifies the time window used to convert given set of raw data points. Enter this value using the ISO 8601 standard. For example, enter PT10M to specify an interval size of 10 Minutes.

Note:

The timestamp of the aggregated data point corresponds to the start of the time window during which raw data points are assessed. For example, for a 10 minutes interval, the timestamp "09:00" corresponds to the 10 minutes time window from 09:00 to 09:10.

Example: ISO 8601 Duration

--statistic

Optional

Specifies the aggregation function applied to the given set of raw data points in an interval. Supported functions are MEAN, MIN and MAX.

Example: MEAN, MIN, or MAX.

--include

Optional

Specifies the list of system resources that requires data. The supported resources are CPU and Memory.

Example: Specify "CPU" to include CPU, "CPU, MEMORY" to include CPU and Memory, "ALL" to include all resources.

CLI Command

okv metrics server get --options <argument>

JSON Example

  1. Generate JSON input for the okv metrics server get command.
    okv metrics server get --generate-json-input

    The generated input appears as follows:

    {
     "service" : {
      "category" : "metrics",
      "resource" : "server",
      "action" : "get",
      "options" : {
       "startTime" : "#YYYY-MM-DD hh:mm:ss",
       "endTime" : "#NOW|YYYY-MM-DD hh:mm:ss",
       "interval" : "#VALUE",
       "statistic" : "#MEAN|MAX|MIN",
       "include" : [ "ALL" ],
       "limit" : "#VALUE"
       }
      }
     }
  2. Save the generated output to a file (for example, metric_server_get.json).
    {
      "service" : {
        "category" : "metrics",
        "resource" : "server",
        "action" : "get",
        "options" : {
          "startTime" : "2022-09-20 20:05:00",
          "endTime" : "NOW",
          "interval" : "PT10M",
          "statistic" : "MEAN",
          "include" : [ "ALL" ],
          "limit" : "3"
        }
      }
    }
  3. Run the okv metrics server get command using the generated JSON file.
    okv metrics server get --from-json metric_server_get.json

    Output similar to the following appears:

    {
      "result" : "Success",
      "value" : {
        "availableResources" : [ {
          "sampleTime" : "2022-09-20 19:38:30",
          "cpuCores" : "16",
          "totalMemoryInKB" : "7847752"
        } ],
        "metrics" : [ {
          "sampleTime" : "2022-09-20 20:05:00",
          "cpuUtilizationPercentage" : "1",
          "loadAverage1Minute" : "0.36",
          "loadAverage5Minutes" : "0.43",
          "loadAverage15Minutes" : "0.65",
          "freeMemoryInKB" : "144172"
        }, {
          "sampleTime" : "2022-09-20 20:15:00",
          "cpuUtilizationPercentage" : "0",
          "loadAverage1Minute" : "0.1",
          "loadAverage5Minutes" : "0.15",
          "loadAverage15Minutes" : "0.38",
          "freeMemoryInKB" : "159638"
        }, {
          "sampleTime" : "2022-09-20 20:25:10",
          "cpuUtilizationPercentage" : "0",
          "loadAverage1Minute" : "0.05",
          "loadAverage5Minutes" : "0.06",
          "loadAverage15Minutes" : "0.21",
          "freeMemoryInKB" : "150341"
        } ]
      }
    }