diff options
| author | Nataliia Solomko <natalirs1985@gmail.com> | 2025-08-12 18:48:05 +0300 |
|---|---|---|
| committer | Nataliia Solomko <natalirs1985@gmail.com> | 2025-08-13 14:18:16 +0300 |
| commit | ebb4b887f888ba71afd8c52d17520de4bcc53889 (patch) | |
| tree | 358835190b99714e90409471e95b0f161a226e92 /python | |
| parent | 4c47b5c170baa189d9a4983f050856a226b6553e (diff) | |
| download | vyos-1x-ebb4b887f888ba71afd8c52d17520de4bcc53889.tar.gz vyos-1x-ebb4b887f888ba71afd8c52d17520de4bcc53889.zip | |
T7678: Remove host-resources from CLI
It will be configured in section "system option host-resources"
Diffstat (limited to 'python')
| -rw-r--r-- | python/vyos/vpp/config_resource_checks/memory.py | 8 | ||||
| -rw-r--r-- | python/vyos/vpp/config_verify.py | 15 |
2 files changed, 0 insertions, 23 deletions
diff --git a/python/vyos/vpp/config_resource_checks/memory.py b/python/vyos/vpp/config_resource_checks/memory.py index bce2df2bb..66b9fd9a3 100644 --- a/python/vyos/vpp/config_resource_checks/memory.py +++ b/python/vyos/vpp/config_resource_checks/memory.py @@ -51,14 +51,6 @@ def get_total_hugepages_memory() -> int: return hugepage_size * hugepages_total -def get_total_hugepages_count() -> int: - """ - Returns the total count of hugepages - """ - info = get_hugepages_info() - return info.get('HugePages_Total') - - def get_numa_count(): """ Run `numactl --hardware` and parse the 'available:' line. diff --git a/python/vyos/vpp/config_verify.py b/python/vyos/vpp/config_verify.py index 1beb3141b..9c56c8b95 100644 --- a/python/vyos/vpp/config_verify.py +++ b/python/vyos/vpp/config_verify.py @@ -19,7 +19,6 @@ import psutil from vyos import ConfigError -from vyos.base import Warning from vyos.utils.cpu import get_core_count as total_core_count from vyos.vpp.control_host import get_eth_driver @@ -391,17 +390,3 @@ def verify_vpp_interfaces_dpdk_num_queues(qtype: str, num_queues: int, workers: f'The number of {qtype} queues cannot be greater than the number of configured VPP workers: ' f'workers: {workers}, queues: {num_queues}' ) - - -def verify_vpp_host_resources(config: dict): - max_map_count = int(config['settings']['host_resources']['max_map_count']) - - # Get HugePages total count - hugepages = mem_checks.get_total_hugepages_count() - - if max_map_count < 2 * hugepages: - Warning( - 'The max-map-count should be greater than or equal to (2 * HugePages_Total) ' - 'or VPP could work not properly. Please set up ' - f'"vpp settings host-resources max-map-count" to {2 * hugepages} or higher' - ) |
