Skip to content

Commit 5366934

Browse files
authored
F #7052: OneCfg: handle pci.conf for lxc (#3962)
1 parent 6893ef4 commit 5366934

File tree

2 files changed

+69
-0
lines changed

2 files changed

+69
-0
lines changed

src/onecfg/share/etc/files.yaml

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -431,6 +431,13 @@
431431
mode: '0640'
432432
src: src/im_mad/remotes/lib/forecast.conf
433433

434+
- name: /var/lib/one/remotes/etc/im/lxc-probes.d/pci.conf
435+
class: Yaml
436+
owner: oneadmin
437+
group: oneadmin
438+
mode: '0640'
439+
src: src/im_mad/remotes/lib/pci.conf
440+
434441
- name: /var/lib/one/remotes/etc/im/lxd-probes.d/pci.conf
435442
class: Yaml
436443
owner: oneadmin

src/onecfg/share/migrators/7.0.0_to_7.1.80.yaml

Lines changed: 62 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -9044,3 +9044,65 @@ patches:
90449044
\ lookback: 60 # The look-back windows in minutes to use for the predictions\n forecast_far:\n enabled:
90459045
false\n period: 2880 # Number of minutes\n lookback: 10080 # The look-back windows in minutes to use
90469046
for the predictions\n"
9047+
"/var/lib/one/remotes/etc/im/lxc-probes.d/pci.conf":
9048+
class: Yaml
9049+
owner: oneadmin
9050+
group: oneadmin
9051+
mode: '0640'
9052+
action: create
9053+
content: |
9054+
# This option specifies the main filters for PCI card monitoring. The format
9055+
# is the same as used by lspci to filter on PCI card by vendor:device(:class)
9056+
# identification. Several filters can be added as a list, or separated
9057+
# by commas. The NULL filter will retrieve all PCI cards.
9058+
#
9059+
# From lspci help:
9060+
# -d [<vendor>]:[<device>][:<class>]
9061+
# Show only devices with specified vendor, device and class ID.
9062+
# The ID's are given in hexadecimal and may be omitted or given
9063+
# as "*", both meaning "any value"#
9064+
#
9065+
# For example:
9066+
# :filter:
9067+
# - '10de:*' # all NVIDIA VGA cards
9068+
# - '10de:11bf' # only GK104GL [GRID K2]
9069+
# - '*:10d3' # only 82574L Gigabit Network cards
9070+
# - '8086::0c03' # only Intel USB controllers
9071+
#
9072+
# or
9073+
#
9074+
# :filter: '*:*' # all devices
9075+
#
9076+
# or
9077+
#
9078+
# :filter: '0:0' # no devices
9079+
#
9080+
:filter: '0:0'
9081+
9082+
# The PCI cards list restricted by the :filter option above can be even more
9083+
# filtered by the list of exact PCI addresses (bus:device.func).
9084+
#
9085+
# For example:
9086+
# :short_address:
9087+
# - '07:00.0'
9088+
# - '06:00.0'
9089+
#
9090+
:short_address: []
9091+
9092+
# The PCI cards list restricted by the :filter option above can be even more
9093+
# filtered by matching the device name against the list of regular expression
9094+
# case-insensitive patterns.
9095+
#
9096+
# For example:
9097+
# :device_name:
9098+
# - 'Virtual Function'
9099+
# - 'Gigabit Network'
9100+
# - 'USB.*Host Controller'
9101+
# - '^MegaRAID'
9102+
#
9103+
:device_name: []
9104+
9105+
# List of NVIDIA vendor IDs, these are used to recognize PCI devices from
9106+
# NVIDIA and use vGPU feature
9107+
:nvidia_vendors:
9108+
- '10de'

0 commit comments

Comments
 (0)