DEVATTR(8) BSD System Manager's Manual DEVATTR(8)NAMEdevattr — tool for displaying devices and their associated properties
SYNOPSISdevattr [-Ah] [-p property] [-d device] [-m key:value] [-r key:value]
DESCRIPTION
The devattr tool is for displaying a list of devices and some associated
properties such as their name. This tool exposes the same functionality
provided by the devattr(3) library, namely the filtering capabilities
offered.
The options are as follows:
-A Excludes aliases from the listing.
-h Displays a help message.
-p Only display the specified property. This can be can be speci‐
fied multiple times and combined with all other options.
-d Only display devices with name device. When used with -p, only
the specified properties of device are listed. Can be specified
multiple times. Allows wildcards.
-m Only display devices whose property key matches with wildcards
value value unless the key-value pair starts with ~, in which
case the match is inverted. Stacks with -p, -d, -m. Can be
specified multiple times.
-r Behaves similarly to -m, but matches with regex.
EXAMPLES
List all devices named 'pts/0':
devattr-d pts/0
List all devices whose major number is 64:
devattr-m major:64
List all devices whose name is 'pts/0' and major number is not 64:
devattr-d pts/0 -m ~major:64
SEE ALSOdevattr(3), udevd(8)AUTHORS
Nolan Lum
BSD December 6, 2010 BSD