Resource Identifiers
A resource-instance is a specific object within a class-name class. The resource-instance includes the resource type and the name of the specific resource.
In the following SSID that identifies CPU instance 0, id/0 is the
resource-instance, id is the resource type, and
0 is the name of the specific cpu resource:
//:class.cpu//:res.id/0
If class-name is svc,
resource-instance is a service instance FMRI. The following SSID
identifies the system/identity:node SMF service instance, where
fmri is the resource type, and system/identity:node is the
name of the specific svc resource:
//:class.svc//:res.fmri/system/identity:node
If class-name is app,
resource-instance is a running instance of the application.
Both class and res components are required to identify
any system resource. Identical resource names can identify completely different resources and are
differentiated by class. For example, in //:class.cpu//:res.id/0,
id/0 is CPU 0; in //:class.lgroup//:res.id/0,
id/0 is locality group 0; in //:class.pset//:res.id/0,
id/0 is processor set 0; and in //:class.zone//:res.id/0,
id/0 is non-global zone 0. The following command shows that the statistics
available for each of these identically-named resources are completely different because the
resources are not the same kind (class) of object:
$ sstore list //:class.*//:res.id/0//:stat.*
IDENTIFIER
//:class.cpu//:res.id/0//:stat.fpu-usage
//:class.cpu//:res.id/0//:stat.integer-pipe-usage
//:class.cpu//:res.id/0//:stat.interrupt-count
//:class.cpu//:res.id/0//:stat.interrupt-time
//:class.cpu//:res.id/0//:stat.usage
//:class.cpu//:res.id/0//:stat.xcalls
//:class.pset//:res.id/0//:stat.load-average
//:class.pset//:res.id/0//:stat.ncpus
//:class.pset//:res.id/0//:stat.runnable-threads
//:class.pset//:res.id/0//:stat.waiting-threadsAs much as possible, resource names are the same as names used in the related administrative
commands. The following example shows that the names of resources for disk and
nfs class objects match the names of the devices in iostat
output:
$ iostat -x extended device statistics device r/s w/s kr/s kw/s wait actv wsvc_t asvc_t %w %b sd0 0.0 0.0 0.0 0.0 0.0 0.0 0.0 0.0 0 0 sd1 0.0 0.0 0.0 0.0 0.0 0.0 0.0 0.0 0 0 sd2 0.4 1.0 66.9 223.8 0.0 0.0 0.0 4.8 0 0 sd3 1.9 7.7 20.9 86.1 0.0 0.1 0.0 6.4 0 2 ... nfs85 0.0 0.0 0.0 0.1 0.0 0.0 183.3 480.3 0 0 nfs1314 0.0 0.0 0.0 0.1 0.0 0.0 0.0 1.2 0 0 nfs2719 0.0 0.0 0.0 0.0 0.0 0.0 0.0 1.0 0 0 nfs3102 0.0 0.0 0.0 0.0 0.0 0.0 0.0 0.9 0 0 $ sstore list //:class.disk//:* IDENTIFIER //:class.disk//:event.fault //:class.disk//:res.name/sd0 //:class.disk//:res.name/sd1 //:class.disk//:res.name/sd10 ... $ sstore list //:class.nfs/client//:* IDENTIFIER //:class.nfs/client//:res.name/nfs1314 //:class.nfs/client//:res.name/nfs2719 //:class.nfs/client//:res.name/nfs3102
The SSID component that follows the res component is usually a statistic
(stat). This component could also be class or
event, as shown in the following example.
$ sstore list //:class.cpu//:res.id/0//:*
IDENTIFIER
//:class.cpu//:res.id/0//:class.chip
//:class.cpu//:res.id/0//:class.core
//:class.cpu//:res.id/0//:class.pset
//:class.cpu//:res.id/0//:event.adm-action
//:class.cpu//:res.id/0//:event.fault
//:class.cpu//:res.id/0//:stat.fpu-usage
//:class.cpu//:res.id/0//:stat.integer-pipe-usage
//:class.cpu//:res.id/0//:stat.interrupt-count
//:class.cpu//:res.id/0//:stat.interrupt-time
//:class.cpu//:res.id/0//:stat.usage
//:class.cpu//:res.id/0//:stat.xcallsA single system resource can be available through multiple classes or through multiple resource identifiers in the same class. See Using Statistics Store Identifier Aliases for examples. On a particular system, some classes might have no resources.