From e148e329d06238853b376116beec1b44d29694fd Mon Sep 17 00:00:00 2001 From: Peter Mikus Date: Mon, 28 Oct 2024 12:35:55 +0100 Subject: fix(ansible): Calibration role Signed-off-by: Peter Mikus Change-Id: Ie590eb5eaed0bec9b75ce786062f62f4a3a1d19d (cherry picked from commit d3d02ce8ef228ae02a3ebf485cd3a3395b03bbee) --- .../roles/calibration/defaults/main.yaml | 30 +------------------ .../roles/calibration/tasks/aarch64.yaml | 2 -- .../roles/calibration/tasks/main.yaml | 26 ++-------------- .../roles/calibration/tasks/x86_64.yaml | 35 ---------------------- .../report_iterative/2n-grc/vpp-mrr-00.md | 7 ----- .../report_iterative/2n-grc/vpp-ndrpdr-00.md | 7 ----- resources/libraries/bash/function/common.sh | 2 +- 7 files changed, 4 insertions(+), 105 deletions(-) delete mode 100644 fdio.infra.ansible/roles/calibration/tasks/aarch64.yaml delete mode 100644 fdio.infra.ansible/roles/calibration/tasks/x86_64.yaml diff --git a/fdio.infra.ansible/roles/calibration/defaults/main.yaml b/fdio.infra.ansible/roles/calibration/defaults/main.yaml index 0b7362b01f..dac42b84d4 100644 --- a/fdio.infra.ansible/roles/calibration/defaults/main.yaml +++ b/fdio.infra.ansible/roles/calibration/defaults/main.yaml @@ -1,30 +1,6 @@ --- # file: defaults/main.yaml -# Packages to install. -packages: "{{ packages_base + packages_by_distro[ansible_distribution|lower][ansible_distribution_release] + packages_by_arch[ansible_machine] }}" - -packages_base: - - [] - -packages_by_distro: - ubuntu: - jammy: - - "build-essential" - - "dmidecode" - noble: - - "build-essential" - - "dmidecode" - debian: - bullseye: - - "build-essential" - -packages_by_arch: - aarch64: - - [] - x86_64: - - [] - # Kernel version to check. kernel_version: "{{ kernel_version_by_distro_by_arch[ansible_distribution | lower][ansible_distribution_release][ansible_machine] }}" @@ -46,8 +22,4 @@ kernel_version_by_distro_by_arch: - "6.8.0-45-generic" debian: bullseye: - - "5.15.0-107-generic" - -pma_directory: "/tmp/pma_tools" -jitter_core: 7 -jitter_iterations: 20 + - "5.15.0-107-generic" \ No newline at end of file diff --git a/fdio.infra.ansible/roles/calibration/tasks/aarch64.yaml b/fdio.infra.ansible/roles/calibration/tasks/aarch64.yaml deleted file mode 100644 index e01245556a..0000000000 --- a/fdio.infra.ansible/roles/calibration/tasks/aarch64.yaml +++ /dev/null @@ -1,2 +0,0 @@ ---- -# file: tasks/aarch64.yaml diff --git a/fdio.infra.ansible/roles/calibration/tasks/main.yaml b/fdio.infra.ansible/roles/calibration/tasks/main.yaml index 9db95a87a0..77c9a43430 100644 --- a/fdio.infra.ansible/roles/calibration/tasks/main.yaml +++ b/fdio.infra.ansible/roles/calibration/tasks/main.yaml @@ -1,23 +1,7 @@ --- # file: tasks/main.yaml -- name: Update Package Cache (APT) - ansible.builtin.apt: - update_cache: true - cache_valid_time: 3600 - when: - - ansible_distribution|lower == 'ubuntu' - tags: - - calibration-inst-prerequisites - -- name: Prerequisites - ansible.builtin.package: - name: "{{ packages | flatten(levels=1) }}" - state: latest - tags: - - calibration-inst-prerequisites - -- name: Check Kernel Parameters +- name: "Check Kernel Parameters" ansible.builtin.assert: that: - item in ansible_cmdline @@ -29,7 +13,7 @@ tags: - check-kernel-params -- name: Check Kernel Version +- name: "Check Kernel Version" ansible.builtin.assert: that: - ansible_kernel not in kernel_version_by_distro_by_arch @@ -37,9 +21,3 @@ success_msg: "Kernel version match." tags: - check-kernel-version - -- name: "{{ ansible_machine }} Specific" - include_tasks: "{{ ansible_machine }}.yaml" - tags: - - check-machine-specific - - check-jitter-tool diff --git a/fdio.infra.ansible/roles/calibration/tasks/x86_64.yaml b/fdio.infra.ansible/roles/calibration/tasks/x86_64.yaml deleted file mode 100644 index dd4e307ca6..0000000000 --- a/fdio.infra.ansible/roles/calibration/tasks/x86_64.yaml +++ /dev/null @@ -1,35 +0,0 @@ ---- -# file: tasks/x86_64.yaml - -- name: Clone PMA Tool - ansible.builtin.git: - repo: "https://gerrit.fd.io/r/pma_tools" - dest: "{{ pma_directory }}" - tags: - - check-jitter-tool - -- name: Compile PMA Tool - ansible.builtin.raw: "cd {{ pma_directory }}/jitter && make" - tags: - - check-jitter-tool - -- name: Calibration - Run Jitter Tool - ansible.builtin.shell: "{{ pma_directory }}/jitter/jitter -c {{ jitter_core }} -i {{ jitter_iterations }} -f" - become: true - async: 60 - poll: 0 - ignore_errors: true - register: jitter_async - tags: - - check-jitter-tool - -- name: Check sync status - ansible.builtin.async_status: - jid: "{{ jitter_async.ansible_job_id }}" - register: "jitter_poll_results" - until: jitter_poll_results.finished - retries: 30 - -- ansible.builtin.debug: var=jitter_poll_results.stdout_lines - tags: - - check-jitter-tool diff --git a/resources/job_specs/report_iterative/2n-grc/vpp-mrr-00.md b/resources/job_specs/report_iterative/2n-grc/vpp-mrr-00.md index 0e224ab9aa..25da6ce77d 100644 --- a/resources/job_specs/report_iterative/2n-grc/vpp-mrr-00.md +++ b/resources/job_specs/report_iterative/2n-grc/vpp-mrr-00.md @@ -9,13 +9,6 @@ 1c AND 1518b AND mrr AND cx556a AND drv_mlx5_core AND eth-l2bdbasemaclrn-eth-2memif-1dcr 2c AND 1518b AND mrr AND cx556a AND drv_mlx5_core AND eth-l2bdbasemaclrn-eth-2memif-1dcr 4c AND 1518b AND mrr AND cx556a AND drv_mlx5_core AND eth-l2bdbasemaclrn-eth-2memif-1dcr -##### eth-l2bdbasemaclrn-eth-2memif-dma-1dcr -1c AND 64b AND mrr AND cx556a AND drv_mlx5_core AND eth-l2bdbasemaclrn-eth-2memif-dma-1dcr -2c AND 64b AND mrr AND cx556a AND drv_mlx5_core AND eth-l2bdbasemaclrn-eth-2memif-dma-1dcr -4c AND 64b AND mrr AND cx556a AND drv_mlx5_core AND eth-l2bdbasemaclrn-eth-2memif-dma-1dcr -1c AND 1518b AND mrr AND cx556a AND drv_mlx5_core AND eth-l2bdbasemaclrn-eth-2memif-dma-1dcr -2c AND 1518b AND mrr AND cx556a AND drv_mlx5_core AND eth-l2bdbasemaclrn-eth-2memif-dma-1dcr -4c AND 1518b AND mrr AND cx556a AND drv_mlx5_core AND eth-l2bdbasemaclrn-eth-2memif-dma-1dcr ##### eth-l2xcbase-eth-2memif-1dcr 1c AND 64b AND mrr AND cx556a AND drv_mlx5_core AND eth-l2xcbase-eth-2memif-1dcr 2c AND 64b AND mrr AND cx556a AND drv_mlx5_core AND eth-l2xcbase-eth-2memif-1dcr diff --git a/resources/job_specs/report_iterative/2n-grc/vpp-ndrpdr-00.md b/resources/job_specs/report_iterative/2n-grc/vpp-ndrpdr-00.md index 8896fcea7c..9f6e4f3265 100644 --- a/resources/job_specs/report_iterative/2n-grc/vpp-ndrpdr-00.md +++ b/resources/job_specs/report_iterative/2n-grc/vpp-ndrpdr-00.md @@ -9,13 +9,6 @@ 1c AND 1518b AND ndrpdr AND cx556a AND drv_mlx5_core AND eth-l2bdbasemaclrn-eth-2memif-1dcr 2c AND 1518b AND ndrpdr AND cx556a AND drv_mlx5_core AND eth-l2bdbasemaclrn-eth-2memif-1dcr 4c AND 1518b AND ndrpdr AND cx556a AND drv_mlx5_core AND eth-l2bdbasemaclrn-eth-2memif-1dcr -##### eth-l2bdbasemaclrn-eth-2memif-dma-1dcr -1c AND 64b AND ndrpdr AND cx556a AND drv_mlx5_core AND eth-l2bdbasemaclrn-eth-2memif-dma-1dcr -2c AND 64b AND ndrpdr AND cx556a AND drv_mlx5_core AND eth-l2bdbasemaclrn-eth-2memif-dma-1dcr -4c AND 64b AND ndrpdr AND cx556a AND drv_mlx5_core AND eth-l2bdbasemaclrn-eth-2memif-dma-1dcr -1c AND 1518b AND ndrpdr AND cx556a AND drv_mlx5_core AND eth-l2bdbasemaclrn-eth-2memif-dma-1dcr -2c AND 1518b AND ndrpdr AND cx556a AND drv_mlx5_core AND eth-l2bdbasemaclrn-eth-2memif-dma-1dcr -4c AND 1518b AND ndrpdr AND cx556a AND drv_mlx5_core AND eth-l2bdbasemaclrn-eth-2memif-dma-1dcr ##### eth-l2xcbase-eth-2memif-1dcr 1c AND 64b AND ndrpdr AND cx556a AND drv_mlx5_core AND eth-l2xcbase-eth-2memif-1dcr 2c AND 64b AND ndrpdr AND cx556a AND drv_mlx5_core AND eth-l2xcbase-eth-2memif-1dcr diff --git a/resources/libraries/bash/function/common.sh b/resources/libraries/bash/function/common.sh index e8a5efaa87..fa00b14ded 100644 --- a/resources/libraries/bash/function/common.sh +++ b/resources/libraries/bash/function/common.sh @@ -770,7 +770,7 @@ function reserve_and_cleanup_testbed () { } # Cleanup + calibration checks set +e - ansible_playbook "cleanup" + ansible_playbook "cleanup,calibration" result="$?" set -e if [[ "${result}" == "0" ]]; then -- cgit 1.2.3-korg