salt.modules.devinfo

maintainer

Alberto Planas <aplanas@suse.com>

maturity

new

depends

None

platform

Linux

salt.modules.devinfo.filter_(udev_in=None, udev_ex=None)

Returns a list of devices, filtered under udev keys.

udev_in

A dictionary of key:values that are expected in the device udev information

udev_ex

A dictionary of key:values that are not expected in the device udev information (excluded)

The key is a lower case string, joined by dots, that represent a path in the udev information dictionary. For example, 'e.id_bus' will represent the udev entry udev['E']['ID_BUS']

If the udev entry is a list, the algorithm will check that at least one item match one item of the value of the parameters.

Returns list of devices that match udev_in and do not match udev_ex.

CLI Example:

salt '*' devinfo.filter udev_in='{"e.id_bus": "ata"}'
salt.modules.devinfo.hwinfo(items=None, short=True, listmd=False, devices=None)

Probe for hardware

items

List of hardware items to inspect. Default ['bios', 'cpu', 'disk', 'memory', 'network', 'partition']

short

Show only a summary. Default True.

listmd

Report RAID devices. Default False.

devices

List of devices to show information from. Default None.

CLI Example:

salt '*' devinfo.hwinfo
salt '*' devinfo.hwinfo items='["disk"]' short=no
salt '*' devinfo.hwinfo items='["disk"]' short=no devices='["/dev/sda"]'
salt '*' devinfo.hwinfo devices=/dev/sda