Go to main content

man pages section 8: System Administration Commands

Exit Print View

Updated: Thursday, June 13, 2019
 
 

devprop(8)

Name

devprop - display device property-value or device-path information

Synopsis

/usr/sbin/devprop [-n device-path] [-v] [-{e|b|i|l|s}] [-q]
	[-c separator] property-name ...
/usr/sbin/devprop -a [-v] [-{e|b|i|l|s}] [-q]
	[-c separator] property-name ...

Description

Use of '-n device-path' and '–a' are exclusive. If neither are specified then '–n /' is assumed.

If no property-name is specified, the devprop -n device-path command produces one line of property-name=property-value output for each device-path property that exists.

For each property-name specified, the 'devprop -n device-path' command produces one line output detailing the property-value. If a property-name is not defined at the device-path node, then the output is a blank line. If the –v option is specified, each line of output will begin with "property-name=".

The 'devprop -a' command locates all device-paths that define every single property-name specified. Without the –v option, for each qualified device-path, one line of "device-path" output is produced (independent of the number of property-names used). If the –v option is specified, a line of device-path property-name=property-value output is produced for each property-name specified.

All other command line options relate to property-value type and display variations. The boolean property-value prints true (with the –e option) if it exists; it is otherwise false. A byte, int, or int_64 property-value is displayed in hex format if one specifies type by means of options –b, –i, or –l; otherwise the property-value is displayed in decimal format. The –e, –b, –i, –l, and –s options are mutually exclusive. Array property-value elements are separated by a user-defined separator character. When –q option is specified, a string property-value is surrounded by double quotation marks (").

Options

The options below are supported.

–n device-path

The path to a target device node for which properties are displayed. The default path is that of the root node, equivalent to specifying -n /.

–a

Details which device-paths define the specified property-name.

–v

Specifies verbose mode for –noption. The "property-name=" is displayed before each property-value for the –a option. The "property-name=property-value" is displayed after the device-path.

The following options are related to property-value type.

–b

The properties to be displayed are sequences of hex bytes (DI_PROP_TYPE_BYTES).

–e

The properties to be output are boolean (DI_PROP_TYPE_BOOLEAN). Prints "true" if the property-name exists, otherwise prints "false".

–i

The properties to be displayed are hex integers (DI_PROP_TYPE_INT).

–l

The properties to be displayed are 64-bit hex integers (DI_PROP_TYPE_INT64).

–s

The properties to be displayed are strings (DI_PROP_TYPE_STRING). This is the default property.

The following options related to property-value display.

–c separator

Specifies the separator between array property-value elements. Use double quotation marks (" ") to specify a space. The default separator is the plus sign (+) for the string type, and period (.) for others, such as prtconf(8).

–q

Specifies quoted display mode in which string properties are displayed surrounded by double quotation marks (").

Operands

Only the '-n device-path' invocation takes additional operands:

property-name...

For each property-name in the list, display the property-value.

Exit Status

0

No error occurred.

non-zero

An error occurred.

Attributes

See attributes(7) for descriptions of the following attributes:

ATTRIBUTE TYPE
ATTRIBUTE VALUE
Availability
system/core-os
Interface Stability
See below

The location of the utility is Committed. The utility options are all Uncommitted, with property-names and device-paths used being Volatile. In general, the results displayed are Volatile, and are highly dependent on the system configuration.

See Also

libdevinfo(3LIB), attributes(7), prtconf(8)