Ales Komarek | 32fea93 | 2016-12-15 12:20:33 +0100 | [diff] [blame] | 1 | |
| 2 | ===================== |
| 3 | Generic system models |
| 4 | ===================== |
| 5 | |
| 6 | This repo contains general reclass system level of salt model. It is to be |
| 7 | used along with service models and concrete cluster deployment model. |
| 8 | |
| 9 | Network configuration |
| 10 | ===================== |
| 11 | |
Petr Jediný | 2418e4e | 2017-02-15 16:12:32 +0100 | [diff] [blame] | 12 | Enable SR-IOV support |
| 13 | --------------------- |
| 14 | |
| 15 | Include class at `cluster.<name>.openstack.compute` |
| 16 | |
Petr Jediný | efc605a | 2017-03-27 11:49:40 +0200 | [diff] [blame] | 17 | .. code-block:: yaml |
Petr Jediný | 2418e4e | 2017-02-15 16:12:32 +0100 | [diff] [blame] | 18 | |
Petr Jediný | efc605a | 2017-03-27 11:49:40 +0200 | [diff] [blame] | 19 | - system.nova.compute.nfv.sriov |
Petr Jediný | 2418e4e | 2017-02-15 16:12:32 +0100 | [diff] [blame] | 20 | |
Petr Jediný | efc605a | 2017-03-27 11:49:40 +0200 | [diff] [blame] | 21 | For single SR-IOV interface setup you can set parameters: |
| 22 | ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ |
| 23 | |
| 24 | `sriov_nic01_device_name` |
| 25 | Name of the Physical Function interface (pF) |
| 26 | |
| 27 | `sriov_nic01_numvfs` |
Michal Kobus | e59ffcf | 2018-03-13 15:44:29 +0100 | [diff] [blame] | 28 | Number of Virtual Functions (VF), for number of |
Petr Jediný | efc605a | 2017-03-27 11:49:40 +0200 | [diff] [blame] | 29 | supported VF check documentation for your network interface card. |
| 30 | |
| 31 | `sriov_nic01_physical_network` |
| 32 | Default **physnet1**, label for physical network the interface belongs to. |
| 33 | |
| 34 | `sriov_unsafe_interrupts` |
Michal Kobus | e59ffcf | 2018-03-13 15:44:29 +0100 | [diff] [blame] | 35 | Default **False**, needs to be set **True** if your hw platform does not |
Petr Jediný | efc605a | 2017-03-27 11:49:40 +0200 | [diff] [blame] | 36 | support interrupt remapping. |
| 37 | |
| 38 | |
| 39 | Multiple SR-IOV interface setup: |
| 40 | ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ |
| 41 | |
| 42 | By default, the metadata model contains configuration for 1 NIC |
| 43 | dedicated for SR-IOV, so we need to setup network interfaces like in the |
| 44 | following example. |
| 45 | |
| 46 | .. code-block:: yaml |
| 47 | |
| 48 | ... |
| 49 | nova: |
| 50 | compute: |
| 51 | sriov: |
| 52 | sriov_nic01: |
| 53 | devname: eth1 |
| 54 | physical_network: physnet3 |
| 55 | sriov_nic02: |
| 56 | devname: eth2 |
| 57 | physical_network: physnet4 |
| 58 | sriov_nic03: |
| 59 | devname: eth3 |
| 60 | physical_network: physnet3 |
| 61 | sriov_nic04: |
| 62 | devname: eth4 |
| 63 | physical_network: physnet6 |
| 64 | linux: |
| 65 | system: |
| 66 | kernel: |
| 67 | sriov: True |
| 68 | unsafe_interrupts: False |
| 69 | rc: |
| 70 | local: | |
| 71 | #!/bin/sh -e |
| 72 | # Enabling 7 VFs on eth1 PF |
| 73 | echo 7 > /sys/class/net/eth1/device/sriov_numvfs; sleep 2; ip link set eth1 up |
| 74 | # Enabling 15 VFs on eth2 PF |
| 75 | echo 15 > /sys/class/net/eth2/device/sriov_numvfs; sleep 2; ip link set eth2 up |
| 76 | # Enabling 15 VFs on eth3 PF |
| 77 | echo 15 > /sys/class/net/eth3/device/sriov_numvfs; sleep 2; ip link set eth3 up |
| 78 | # Enabling 7 VFs on eth4 PF |
| 79 | echo 7 > /sys/class/net/eth4/device/sriov_numvfs; sleep 2; ip link set eth4 up |
| 80 | exit 0 |
Swann Croiset | 09be814 | 2017-01-24 11:37:56 +0100 | [diff] [blame] | 81 | |
Swann Croiset | 34c033b | 2017-04-12 15:50:57 +0200 | [diff] [blame] | 82 | Grafana |
| 83 | ======= |
| 84 | |
| 85 | Configure Grafana client |
| 86 | ------------------------ |
| 87 | |
| 88 | The grafana.client talks to Grafana server to create datasource(s) and install |
| 89 | Grafana plugin(s). |
| 90 | |
| 91 | User models must first include this class and define corresponding parameters: |
| 92 | |
| 93 | - grafana.client |
| 94 | - grafana_protocol (default: http) |
| 95 | - grafana_address |
| 96 | - grafana_port (default: 3000) |
| 97 | - grafana_user |
| 98 | - grafana_password |
| 99 | |
| 100 | Then include datasource(s) and define corresponding parameters: |
| 101 | |
| 102 | - grafana.client.datasource.influxdb |
| 103 | - grafana_influxdb_address |
| 104 | - grafana_influxdb_port |
| 105 | - grafana_influxdb_user |
| 106 | - grafana_influxdb_password |
| 107 | - grafana_influxdb_database |
| 108 | - grafana_influxdb_is_default (default true) |
| 109 | |
| 110 | - grafana.client.datasource.prometheus |
| 111 | - grafana_prometheus_address |
| 112 | - grafana_prometheus_port |
| 113 | - grafana_prometheus_is_default (default true) |
| 114 | |
Michal Kobus | e59ffcf | 2018-03-13 15:44:29 +0100 | [diff] [blame] | 115 | Backward compatiblity |
Swann Croiset | 34c033b | 2017-04-12 15:50:57 +0200 | [diff] [blame] | 116 | --------------------- |
| 117 | |
| 118 | The class **grafana.client.single** configures grafana client and an InfluxDB |
| 119 | datasource. This is the legacy of LMA (aka StackLight) integration with Grafana |
| 120 | and InfluxDB. |
Swann Croiset | 09be814 | 2017-01-24 11:37:56 +0100 | [diff] [blame] | 121 | |
| 122 | Nagios Monitoring |
| 123 | ================= |
| 124 | |
| 125 | Configure Hosts dynamically |
| 126 | --------------------------- |
| 127 | |
| 128 | The nagios formula looks up grains.items throught Salt mines to discover hosts. |
| 129 | There are two different parameters that tell the nagios formula how to determine |
| 130 | the hosts' IP address: |
| 131 | |
| 132 | - nagios_monitoring_network: IP subnet(s) in CIDR notation (can be a list) |
| 133 | - nagios_monitoring_interface: interface name(s). Default ['eth0', 'ens3']. |
| 134 | |
| 135 | 'nagios_monitoring_network' parameter takes precedence over 'nagios_monitoring_interface' list. |