1#Example fan monitor definitions for phosphor-fan-monitor
2
3#List the fans that need to be monitored, along with some
4#properties that define how much slack is allowed in the actual
5#tach value as compared to the target tach value.
6
7#fans:
8# - inventory:
9#    [The system inventory location for the fan]
10#  method: [timebased|count](optional)
11#    [Available methods:
12#     * timebased - use a percentage based deviation
13#     * count - run up/down count fault detection]
14#  functional_delay:
15#    [Delay (in secs) before a fan is marked functional after returning
16#     within the allowed deviation]
17#  allowed_out_of_range_time: (required for method timebased)
18#    [Time (in secs) actual speed can be outside of deviation of
19#     target speed]
20#  deviation:
21#    [Percentage that actual speed must be within target speed]
22#  num_sensors_nonfunc_for_fan_nonfunc:
23#    [How many sensors on the fan must be faulted before fan
24#     will be considered faulted]
25#  sensors: [array of speed sensors for the fan]
26#    - name [The name of the fan sensor]
27#      has_target [true|false  If this sensor has a Target property for
28#                  setting a fan speed (otherwise just for reads)]
29#      target_interface [The fan target interface used by the sensor.
30#                        Default is "xyz.openbmc_project.Control.FanSpeed"]
31#      factor [The factor to multiply with target to calculate the expected
32#              fan speed. Default is 1 for fan speed target;
33#              Customized value for pwm target]
34#      offset [The offset to add to calculate the expected fan speed.
35#              Default is 0 for fan speed target;
36#              Customized value for pwm target]
37#  condition: [optional condition function to create fan functional monitoring]
38#    name: [The name of an available condition function]
39#    properties: [The properties used in the condition function]
40#        - object: [Object path of property to use]
41#          interface: [Interface of property to use]
42#          property:
43#              name: [Property name]
44#              type: [Property data type]
45#              value: [Property value to check condition against]
46#
47#sensor_trust_groups:
48# - class: [Group class name
49#           Available classes:
50#           * NonzeroSpeed - Only trust if at least one sensor in the group
51#                            has a nonzero speed.]
52#   group:
53#     - name [The name of the fan sensor in this group]
54#       in_trust: [true|false] (optional)
55#         [Include in trust determination or not. Default = true]
56
57#The code uses these parameters as follows:
58#  After a speed reading of a sensor is outside of the allowed deviation of
59#  the target speed for the allowed out of range time, if at least
60#  num_sensors_nonfunc_for_fan_nonfunc sensors meet this condition,
61#  the fan will be set to nonfunctional in the inventory.
62#
63#  Sensor trust groups are used to specify that the speed values for the
64#  sensors in a group cannot be trusted based on some condition, where
65#  the condition is based on the class used to implement the group.  All
66#  sensors in the group go in and out of trust based on those defined
67#  to be part of determining the trust.  This section is optional.
68
69#Example entries for 1 fan system:
70#fans:
71#  - inventory: /system/chassis/motherboard/fan0
72#    functional_delay: 5
73#    allowed_out_of_range_time: 15
74#    deviation: 15
75#    num_sensors_nonfunc_for_fan_nonfunc: 1
76#    sensors:
77#      - name: fan0
78#        has_target: true
79#    # Only create fan functional properties and monitor on air cooled
80#    condition:
81#      name: propertiesMatch
82#      properties:
83#        - object: /xyz/openbmc_project/inventory/system/chassis
84#          interface: xyz.openbmc_project.Inventory.Decorator.CoolingType
85#          property:
86#            name: WaterCooled
87#            type: bool
88#            value: false
89#sensor_trust_groups:
90# - class: NonzeroSpeed
91#    group:
92#      - name: fan0_0
93#        in_trust: false
94#      - name: fan0_1
95
96#Example entries for count method fan system:
97#fans:
98#  - inventory: /system/chassis/motherboard/fan2
99#    method: count
100#    functional_delay: 5
101#    deviation: 15
102#    num_sensors_nonfunc_for_fan_nonfunc: 1
103#    sensors:
104#      - name: fan2
105#        has_target: true
106#    # Only create fan functional properties and monitor on air cooled
107#    condition:
108#      name: propertiesMatch
109#      properties:
110#        - object: /xyz/openbmc_project/inventory/system/chassis
111#          interface: xyz.openbmc_project.Inventory.Decorator.CoolingType
112#          property:
113#            name: WaterCooled
114#            type: bool
115#            value: false
116