From 5fa2ba9bae1f3f86ad9aa5c13eefa0aff49fd7f4 Mon Sep 17 00:00:00 2001 From: Nataliia Solomko Date: Tue, 19 Aug 2025 17:28:44 +0300 Subject: T7678: Change node name to resource-limits --- interface-definitions/system_option.xml.in | 4 ++-- smoketest/scripts/cli/test_vpp.py | 4 ++-- src/conf_mode/system_option.py | 6 +++--- 3 files changed, 7 insertions(+), 7 deletions(-) diff --git a/interface-definitions/system_option.xml.in b/interface-definitions/system_option.xml.in index fad894153..e6a2b0b65 100644 --- a/interface-definitions/system_option.xml.in +++ b/interface-definitions/system_option.xml.in @@ -32,9 +32,9 @@ Must be ignore, reboot, or poweroff - + - Sysctl parameters for host resources + Resource limits diff --git a/smoketest/scripts/cli/test_vpp.py b/smoketest/scripts/cli/test_vpp.py index cfb159e9a..b55db9e49 100755 --- a/smoketest/scripts/cli/test_vpp.py +++ b/smoketest/scripts/cli/test_vpp.py @@ -1418,10 +1418,10 @@ class TestVPP(VyOSUnitTestSHIM.TestCase): self.cli_delete(base_sflow) self.cli_commit() - def test_19_host_resources(self): + def test_19_resource_limits(self): max_map_count = '100000' shmmax = '55555555555555' - hr_path = ['system', 'option', 'host-resources'] + hr_path = ['system', 'option', 'resource-limits'] # Check if max-map-count has default auto calculated value # but not less than '65530' diff --git a/src/conf_mode/system_option.py b/src/conf_mode/system_option.py index 92f644437..303557412 100755 --- a/src/conf_mode/system_option.py +++ b/src/conf_mode/system_option.py @@ -267,7 +267,7 @@ def apply(options): else: write_file(kernel_dynamic_debug, f'module {module} -p') - if 'host_resources' in options: + if 'resource_limits' in options: unit_map = {'M': 1 << 20, 'G': 1 << 30} total_pages = 0 @@ -283,8 +283,8 @@ def apply(options): max_map_count_min = 65530 # ensures large workload compatibility shmmax_min = 8589934592 # 8 GiB safe default for large allocations - max_map_count_conf = options['host_resources'].get('max_map_count', 'auto') - shmmax_conf = options['host_resources'].get('shmmax', 'auto') + max_map_count_conf = options['resource_limits'].get('max_map_count', 'auto') + shmmax_conf = options['resource_limits'].get('shmmax', 'auto') parameters = { 'vm.max_map_count': ( -- cgit v1.2.3