Utilization of a Resource that is Not a Partition
The following commands show how much memory the system has and how much of that memory is available:
$ sstore export -t 2020-09-02T15:00:00 -p 1 //:class.system//:stat.total-memory TIME VALUE IDENTIFIER 2020-09-02T15:00:00 273804165120 //:class.system//:stat.total-memory $ sstore export -t 2020-09-02T15:00:00 -e 2020-09-02T18:00:00 -i 3600 \ > //:class.system//:stat.available-memory TIME VALUE IDENTIFIER 2020-09-02T16:00:00 17605545259.563152 //:class.system//:stat.available-memory 2020-09-02T17:00:00 17127931904.0 //:class.system//:stat.available-memory 2020-09-02T18:00:00 16594131156.955187 //:class.system//:stat.available-memory
When you apply the util operation to a statistic that is not a partition,
the metadata is searched to determine whether the statistic has a known capacity. In this example,
total-memory is the known capacity of available-memory, as
shown by the following sstore info command:
$ sstore info //:class.system//:stat.available-memory
Identifier: //:class.system//:stat.available-memory
$schema: //:stat
copyright: Copyright (c) 2014, 2020, Oracle and/or its affiliates.
description: Available system memory
id: //:class.system//:stat.available-memory
max-capacity: //:stat.total-memory
stability: stable
type: scalar
units: bytesApplying the util operation to available-memory returns
the percent of memory that is available at each time stamp: available-memory
divided by total-memory.
$ sstore export -t 2020-09-02T15:00:00 -e 2020-09-02T18:00:00 -i 3600 \ > //:class.system//:stat.available-memory//:op.util TIME VALUE IDENTIFIER 2020-09-02T15:00:00 NO_DATA //:class.system//:stat.available-memory//:op.util 2020-09-02T16:00:00 6.429977152410074 //:class.system//:stat.available-memory//:op.util 2020-09-02T17:00:00 6.255541034773285 //:class.system//:stat.available-memory//:op.util 2020-09-02T18:00:00 6.060583902981347 //:class.system//:stat.available-memory//:op.util
In the following example, the difference operation shows the amount of
memory that is being used. When the util operation is applied to the new
synthetic statistic, the result is the percent of memory that is being used:
total-memory less available-memory divided by
total-memory.
$ sstore export -t 2020-09-02T15:00:00 -e 2020-09-02T18:00:00 -i 3600 \ > //:class.system//:stat.//:s.[total-memory,available-memory]//:op.difference TIME VALUE IDENTIFIER 2020-09-02T15:00:00 NO_DATA //:class.system//:stat.//:s.[total-memory,available-memory]//:op.difference 2020-09-02T16:00:00 256198619860.43686 //:class.system//:stat.//:s.[total-memory,available-memory]//:op.difference 2020-09-02T17:00:00 256676233216.0 //:class.system//:stat.//:s.[total-memory,available-memory]//:op.difference 2020-09-02T18:00:00 257210033963.0448 //:class.system//:stat.//:s.[total-memory,available-memory]//:op.difference $ sstore export -t 2020-09-02T15:00:00 -e 2020-09-02T18:00:00 -i 3600 \ > //:class.system//:stat.//:s.[total-memory,available-memory]//:op.difference//:op.util TIME VALUE IDENTIFIER 2020-09-02T15:00:00 NO_DATA //:class.system//:stat.//:s.[total-memory,available-memory]//:op.difference//:op.util 2020-09-02T16:00:00 93.57002284758993 //:class.system//:stat.//:s.[total-memory,available-memory]//:op.difference//:op.util 2020-09-02T17:00:00 93.74445896522671 //:class.system//:stat.//:s.[total-memory,available-memory]//:op.difference//:op.util 2020-09-02T18:00:00 93.93941609701865 //:class.system//:stat.//:s.[total-memory,available-memory]//:op.difference//:op.util