A P P E N D I X  G

Sensor Commands

The sensor command reports or sets the value of an environmental sensor or control.

TABLE G-1 lists the groups of sensor subcommands.


TABLE G-1 Sensor Subcommand Groups

Subcommand Group

Description

sensor get

Returns all data associated with a sensor.

sensor set

Sets some of the data associated with a specific sensor or a class of sensors.




Note - Every command returns a return code upon completion.





Note - There are some sensors whose value does not change, some that are there to provide information in the event of a problem, and others to facilitate the proper operation of the software.

Many of these sensors do not have a related component (parent) associated with them. For example, the die-temperature sensor for a CPU has the CPU as its parent component and a fan-speed sensor has the fan as its parent component; the product-id sensor, however, only reports a static value and has no parent relationship.

This relationship establishes the component(s) which is affected by changes in the value of the sensor. You cannot modify the thresholds for sensors without a parent relationship since an event will never occur for these threshold crossings.



Sensor Get Subcommand

Description: Returns all data associated with a sensor.

By default, only the sensor ID and its current value are displayed. You can specify on the command line the order of the data output.



Note - The identifier field is always displayed first, unless you suppress it with the -I option.



Format

Command format:

sensor get [{{-i | --id} ID | {-t | --type} TYPE_ID}] [{-v | --value}] [{-n | --nominal}] [{-C | --crithigh}] [{-c | --critlow}] [{-W | -warnhigh}] [{-w | --warnlow}] [{-N | --name}] [{-d | --description}] [{-S | --sensor-type}] [{-p | --parent-comp}] [{-s | --severity}] | [{--verbose}] [{-I | --noid}] [{-H | noheader}] [{-D | --delim <DELIMITER>}] 

TABLE G-2 lists the arguments for this subcommand.


TABLE G-2 Arguments for Subcommand sensor get

Arguments

Description

{-i | --id}

SENSOR_ID, PRODUCT-ID, BOARD-REVISION, PRS-REVISION

Specifies the sensor for which the data is desired. You can specify this argument multiple times, in which case the sensor data is reported in the order specified.

You can also retrieve the product ID, board-revision number and PRS revision number using this flag. Specify [-vIH] following the ID to convert the output to the appropriate product ID.

For example, product ID 255 indicates the 2100 server and product ID 239 indicates the 4300 server. You can also obtain this information using the inventory get hardware command.

{-t | --type}

Specifies the sensor class for which the data is desired. You can specify this argument multiple times, in which case the sensor output is grouped by type in the order specified. Current sensor classes are voltage, fan, temperature, current, power and switch.

{-v | --value}

Displays the current value. of the sensor.

{-n | --nominal}

Displays the nominal value of the sensor.

{-C | --crithigh}

Displays the critical high threshold value for the sensor. Thresholds configured to a value other than the factory value display with a trailing asterisk (*) character.

{-c | --critlow}

Displays the critical low threshold value for the sensor.

{-W | -warnhigh}

Displays the warning high threshold value for the sensor.

{-w | --warnlow}

Displays the warning low threshold value for the sensor.

{-N | --name}

Displays the name of the sensor.

{-d | --description}

Displays a description of the sensor.

{-S | --sensor-type}

Displays the type of sensor (for use with --type).

{-p | --parent-comp}

Displays the parent component list for the sensor. These are the components that are affected by changes in the value of a sensor (for example, the components that change severity as the sensor changes severity).

{-s | --severity}

Displays the current severity lever of the sensor (nominal, warning or critical).

{--verbose}

Displays all columns; you cannot use this argument with any of the other column addition options.

{-I | --noid}

Suppresses the display of the sensor ID column. By default, this column always displays when more than one sensor is selected.

[-H | --noheader]

Suppresses the column headings.

{ -D | --delim }

Delimits columns with the specified delimiter. Headings are also delimited unless suppressed. The delimiter can be any character or string.


Return Codes

TABLE G-3 lists the arguments for this subcommand.


TABLE G-3 Return Codes for Subcommand sensor get

Return Code

ID

Description

NWSE_Success

0

Command successfully completed.

NWSE_InvalidUsage

1

Invalid usage: bad parameter usage, conflicting options specified.

NWSE_RPCTimeout

2

Request was issued, but was not serviced by the server. RPC procedure timed out and the request may or may not have been serviced by the server.

NWSE_RPCNotConnected

3

Unable to connect to the RPC server.

NWSE_InvalidArgument

4

One or more arguments were incorrect or invalid.

NWSE_NotFound

5

Entity (user, service, file, path or other) was not found.

NWSE_NoPermission

6

Not authorized to perform this operation.




Note - There are some sensors whose value does not change, some that are there to provide information in the event of a problem, and others to facilitate the proper operation of the software.

Many of these sensors do not have a related component (parent) associated with them. For example, the die-temperature sensor for a CPU has the CPU as its parent component and a fan-speed sensor has the fan as its parent component; the product-id sensor, however, only reports a static value and has no parent relationship.

This relationship establishes the component(s) which is affected by changes in the value of the sensor. You cannot modify the thresholds for sensors without a parent relationship since an event will never occur for these threshold crossings.



Sensor Set Subcommand

Description: Allows you to set some of the data associated with a specific sensor or a class of sensors.

Format

Command format:

sensor set [{-i | --id} SENSOR_ID [{-i | --id} SENSOR_ID] ...] {[{-C | --crithigh} VALUE] [[{-c | --critlow} VALUE] [{-W | --warnhigh] VALUE] [{-w | --warnlow} VALUE] [{-v | --value} {on|off}] | {-r | --reset}} 
sensor set [{-t | --type] TYPE_ID] {[{-C | --crithigh} VALUE] [[{-c| --critlow} VALUE] [{-W | --warnhigh] VALUE] [{-w | --warnlow} VALUE] [{-v | --value} {on|off}] | {-r | --reset}}
sensor set [{-R | --resetall}] 

TABLE G-4 lists the arguments for this subcommand.


TABLE G-4 Arguments for Subcommand sensor set

Arguments

Description

{-i | --id}

Specifies the specific sensor on which to operate. You can specify multiple sensors by repeating --id.

{-t | --type}

Specifies the specific sensor class on which to operate (for example, fan, voltage and so on).

{-C | --crithigh}

Specifies the critical high threshold value for the sensor.

  • Setting the string to clear disables the threshold.
  • Setting the string to reset sets the value to the original factory-specified value.
  • If the value specified ends in a percent sign (%), the threshold is set to that percentage of the nominal value for the sensor.
  • Any other value is interpreted as the actual value to which to set the threshold.

{-c | --critlow}

Specifies the critical low threshold value for the sensor. Setting the string to clear disables the threshold.

{-W | -warnhigh}

Specifies the warning high threshold value for the sensor. Setting the string to clear disables the threshold.

{-w | --warnlow}

Specifies the warning low threshold value for the sensor. Setting the string to clear disables the threshold.

{-v | --value}

Sets the value of the sensor.

{-r | --reset}

Resets all thresholds for the specified sensor(s) to the factory defaults.

{-R | --resetall}

Resets all thresholds for all sensors to the factory defaults.


Return Codes

TABLE G-5 lists the arguments for this subcommand.


TABLE G-5 Return Codes for Subcommand sensor set

Return Code

ID

Description

NWSE_Success

0

Command successfully completed.

NWSE_InvalidUsage

1

Invalid usage: bad parameter usage, conflicting options specified.

NWSE_RPCTimeout

2

Request was issued, but was not serviced by the server. RPC procedure timed out and the request may or may not have been serviced by the server.

NWSE_RPCNotConnected

3

Unable to connect to the RPC server.

NWSE_InvalidArgument

4

One or more arguments were incorrect or invalid.

NWSE_NotFound

5

Entity (user, service, file, path or other) was not found.

NWSE_NoPermission

6

Not authorized to perform this operation.




Note - There are some sensors whose value does not change, some that are there to provide information in the event of a problem, and others to facilitate the proper operation of the software.

Many of these sensors do not have a related component (parent) associated with them. For example, the die-temperature sensor for a CPU has the CPU as its parent component and a fan-speed sensor has the fan as its parent component; the product-id sensor, however, only reports a static value and has no parent relationship.

This relationship establishes the component(s) which is affected by changes in the value of the sensor. You cannot modify the thresholds for sensors without a parent relationship since an event will never occur for these threshold crossings.