<commit_before>---
# collectd
include:
  default:
    - profile::monitoring::collectd

named_interfaces::config:
  mgmt:
    - em1
  trp:
    - team1
  live:
    - team1.120

# Turn off nested virtualization
profile::virtualization::nested::manage: false

profile::monitoring::collectd::enable: true

collectd::plugin::interface::interfaces:
  - "%{::interface_trp1}"
  - "%{::interface_mgmt1}"

profile::monitoring::collectd::plugins:
  - collectd::plugin::aggregation
  - collectd::plugin::cpu
  - collectd::plugin::disk
  - collectd::plugin::load
  - collectd::plugin::memory
  - collectd::plugin::interface
  - collectd::plugin::write_graphite
  - collectd::plugin::virt

# Enable hugepages to prevent OOM-killer when using NUMA
profile::base::physical::enable_hugepages: true
# Number and size of hugepages, based on 512GB - 32 GB (4GB free pr node)
profile::base::physical::hugepagesz:       '2M'
profile::base::physical::hugepages:        '245760'

# Nover overrides
nova::compute::libvirt::libvirt_cpu_model: 'EPYC'
nova::cpu_allocation_ratio:                '1'

# Create and enable more swap
profile::base::common::extraswap:        true
profile::base::common::extraswap_sizegb: 30

profile::base::lvm::physical_volume:
  '/dev/sda4':
    ensure: present
    force:  true
  '/dev/nvme0n1':
    ensure: present
    force:  true
profile::base::lvm::volume_group:
  'vg_instances':
    physical_volumes:
      - /dev/nvme0n1
profile::base::lvm::logical_volume:
  'lv_instances':
    volume_group: 'vg_instances'
    fs_type:      "xfs"
    mountpath:    "/var/lib/nova/instances"

profile::base::network::network_auto_opts:
  mgmt:
    'defroute': 'no'
  trp:
    'defroute': 'no'
    'ipv6init': 'yes'
    'devicetype': 'Team'
    'mtu': '9000'
    'team_config': >-
                   { "runner" : {  "name" : "lacp",  "active": true, "fast_rate" : true,
                   "tx_hash": ["eth", "ipv4", "ipv6"], "tx_balancer": { "name": "basic" } },
                   "link_watch" : {  "name" : "ethtool" } }
  live:
    'defroute': 'no'

profile::base::network::network_auto_bonding:
  trp:
    p1p1:
      'team_port_config': '{ "prio" : 100 }'
      'mtu': '9000'
    p1p2:
      'team_port_config': '{ "prio" : 100 }'
      'mtu': '9000'

# These compute host uses local storage for instances
nova::compute::rbd::ephemeral_storage: false
nova::config::nova_config:
  libvirt/images_type:
    value: default
  DEFAULT/metadata_workers:
    value: '4'

sensu__memory__check:     "check-memory.rb -w 2048 -c 1024"<commit_msg>fix network config<commit_after>---
# collectd
include:
  default:
    - profile::monitoring::collectd

named_interfaces::config:
  mgmt:
    - em1
  trp:
    - team1
  live:
    - team1.120

# Turn off nested virtualization
profile::virtualization::nested::manage: false

profile::monitoring::collectd::enable: true

collectd::plugin::interface::interfaces:
  - "%{::interface_trp1}"
  - "%{::interface_mgmt1}"

profile::monitoring::collectd::plugins:
  - collectd::plugin::aggregation
  - collectd::plugin::cpu
  - collectd::plugin::disk
  - collectd::plugin::load
  - collectd::plugin::memory
  - collectd::plugin::interface
  - collectd::plugin::write_graphite
  - collectd::plugin::virt

# Enable hugepages to prevent OOM-killer when using NUMA
profile::base::physical::enable_hugepages: true
# Number and size of hugepages, based on 512GB - 32 GB (4GB free pr node)
profile::base::physical::hugepagesz:       '2M'
profile::base::physical::hugepages:        '245760'

# Nover overrides
nova::compute::libvirt::libvirt_cpu_model: 'EPYC'
nova::cpu_allocation_ratio:                '1'

# Create and enable more swap
profile::base::common::extraswap:        true
profile::base::common::extraswap_sizegb: 30

profile::base::lvm::physical_volume:
  '/dev/sda4':
    ensure: present
    force:  true
  '/dev/nvme0n1':
    ensure: present
    force:  true
profile::base::lvm::volume_group:
  'vg_instances':
    physical_volumes:
      - /dev/nvme0n1
profile::base::lvm::logical_volume:
  'lv_instances':
    volume_group: 'vg_instances'
    fs_type:      "xfs"
    mountpath:    "/var/lib/nova/instances"

profile::base::network::network_auto_opts:
  mgmt:
    'defroute': 'no'
  trp:
    'defroute': 'no'
    'ipv6init': 'yes'
    'devicetype': 'Team'
    'mtu': '9000'
    'team_config': >-
                   { "runner" : {  "name" : "lacp",  "active": true, "fast_rate" : true,
                   "tx_hash": ["eth", "ipv4", "ipv6"], "tx_balancer": { "name": "basic" } },
                   "link_watch" : {  "name" : "ethtool" } }
  live:
    'defroute': 'no'

profile::base::network::network_auto_bonding:
  trp:
    em3:
      'team_port_config': '{ "prio" : 100 }'
      'mtu': '9000'
    em4:
      'team_port_config': '{ "prio" : 100 }'
      'mtu': '9000'

# These compute host uses local storage for instances
nova::compute::rbd::ephemeral_storage: false
nova::config::nova_config:
  libvirt/images_type:
    value: default
  DEFAULT/metadata_workers:
    value: '4'

sensu__memory__check:     "check-memory.rb -w 2048 -c 1024"
{'fraction_non_alphanumeric': 0.15697101163478605, 'fraction_numerical': 0.024452770656675213, 'mean_word_length': 3.6746543778801843, 'pattern_counts': {'":': 8, '<': 3, '<?xml version=': 0, '>': 5, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '7045783', 'n_tokens_mistral': 1923, 'n_tokens_neox': 1824, 'n_words': 339}