Procházet zdrojové kódy

system.hugepages: sysctl vm.nr_hugepages

Allow hugepages to be used right away. This is a best effort attempt,
as memory might be too fragmented to free enough contiguous regions
for all hugepages, so early allocation during boot remains the norm.

This allows using ovs-switchd-dpdk without rebooting the node first.

Signed-off-by: Alexandru Avadanii <Alexandru.Avadanii@enea.com>
pull/145/head
Alexandru Avadanii před 6 roky
rodič
revize
5e035c2307
1 změnil soubory, kde provedl 7 přidání a 0 odebrání
  1. +7
    -0
      linux/system/hugepages.sls

+ 7
- 0
linux/system/hugepages.sls Zobrazit soubor

@@ -29,6 +29,13 @@ hugepages_mount_{{ hugepages_type }}:
- mkmnt: true
- opts: mode=775,pagesize={{ hugepages.size }}

# Make hugepages available right away with a temporary systctl write
# This will be handled via krn args after reboot, so don't use `sysctl.present`
hugepages_sysctl_vm_nr_hugepages:
cmd.run:
- name: "sysctl vm.nr_hugepages={{ hugepages.count }}"
- unless: "sysctl vm.nr_hugepages | grep -qE '{{ hugepages.count }}'"

{%- endif %}

{%- endfor %}

Načítá se…
Zrušit
Uložit