Skip to content
This repository has been archived by the owner on Sep 17, 2024. It is now read-only.

Add support for Debian 11 and Ubuntu 22.04 platforms #2603

Merged
merged 15 commits into from
Jun 7, 2022

Conversation

narph
Copy link
Contributor

@narph narph commented Jun 3, 2022

What does this PR do?

Adds support for Debian 11 and Ubuntu 22.04 platforms

Why is it important?

Adds support for Debian 11 and Ubuntu 22.04 platforms.
Latest Debian and Ubuntu versions are already supported for other stack components and customers are asking if we support it as well.
We need to make sure elastic agent/fleet server tests will pass on these 2 platforms as well.

Checklist

  • My code follows the style guidelines of this project
  • I have commented my code, particularly in hard-to-understand areas
  • I have made corresponding changes to the documentation
  • I have made corresponding change to the default configuration files
  • I have added tests that prove my fix is effective or that my feature works
  • I have run the Unit tests (make unit-test), and they are passing locally
  • I have run the End-2-End tests for the suite I'm working on, and they are passing locally
  • I have noticed new Go dependencies (run make notice in the proper directory)

Related issues

@mergify
Copy link
Contributor

mergify bot commented Jun 3, 2022

This pull request does not have a backport label. Could you fix it @narph? 🙏
To fixup this pull request, you need to add the backport labels for the needed
branches, such as:

  • backport-v./d./d./d is the label to automatically backport to the 7./d branch. /d is the digit
    NOTE: backport-skip has been added to this pull request.

@mergify mergify bot added the backport-skip Skip notification from the automated backport with mergify label Jun 3, 2022
@elasticmachine
Copy link
Contributor

elasticmachine commented Jun 3, 2022

💔 Tests Failed

the below badges are clickable and redirect to their specific view in the CI or DOCS
Pipeline View Test View Changes Artifacts preview preview

Expand to view the summary

Build stats

  • Start Time: 2022-06-07T08:02:51.548+0000

  • Duration: 77 min 7 sec

Test stats 🧪

Test Results
Failed 2
Passed 384
Skipped 0
Total 386

Test errors 2

Expand to view the tests failures

Initializing / End-To-End Tests / fleet_sles15_fleet_mode / Deploying the agent – Fleet Mode
    Expand to view the error details

     Step the "elastic-agent" process is in the "started" state on the host 
    

  • no stacktrace
Initializing / End-To-End Tests / fleet_debian_10_arm64_system_integration / Adding diskio system/metrics Integration to a Policy – System Integration
    Expand to view the error details

     Step "system/metrics" with "diskio" metrics are present in the datastreams 
    

  • no stacktrace

Steps errors 6

Expand to view the steps failures

Executing ansible-playbook
  • Took 21 min 24 sec . View more details here
  • Description: /var/lib/jenkins/workspace/2e-tests_e2e-testing-mbp_PR-2603/.venv/bin/ansible-playbook --private-key="/var/lib/jenkins/workspace/2e-tests_e2e-testing-mbp_PR-2603/src/github.com/elastic/e2e-testing/e2essh" --extra-vars="workspace=/var/lib/jenkins/workspace/2e-tests_e2e-testing-mbp_PR-2603/src/github.com/elastic/e2e-testing/ runId=5a71cdc9 sshPublicKey=/var/lib/jenkins/workspace/2e-tests_e2e-testing-mbp_PR-2603/src/github.com/elastic/e2e-testing/e2essh.pub" --ssh-common-args='-o StrictHostKeyChecking=no -o UserKnownHostsFile=/dev/null' /var/lib/jenkins/workspace/2e-tests_e2e-testing-mbp_PR-2603/src/github.com/elastic/e2e-testing/.ci/ansible/playbook.yml -i "18.191.46.99," -t setup-stack --extra-vars="buildURL=https://beats-ci.elastic.co/job/e2e-tests/job/e2e-testing-mbp/job/PR-2603/12/ gitSha=0a59572acf470885ac6bd2988c82473a61e240f9 build=12 repo=e2e-testing branch=pr-2603 type=ci stackRunner=18.191.46.99 nodeLabel=stack nodeUser=admin nodeImage=ami-0d90bed76900e679a nodeInstanceType=t3.xlarge"
Sleep
  • Took 0 min 5 sec . View more details here
  • Description: 5
Shell Script
  • Took 9 min 28 sec . View more details here
  • Description: ssh -tt -o TCPKeepAlive=yes -o ServerAliveInterval=60 -o ServerAliveCountMax=10 -o StrictHostKeyChecking=no -o UserKnownHostsFile=/dev/null -i /var/lib/jenkins/workspace/PR-2603-12-bbfa62ed-7d79-472a-b060-03d3e0c22f52/e2essh ec2-user@52.15.75.181 -- 'sudo bash /home/ec2-user/e2e-testing/.ci/scripts/functional-test.sh'
Archive the artifacts
  • Took 0 min 0 sec . View more details here
  • Description: [2022-06-07T09:04:10.911Z] Archiving artifacts script returned exit code 2
Shell Script
  • Took 23 min 18 sec . View more details here
  • Description: ssh -tt -o TCPKeepAlive=yes -o ServerAliveInterval=60 -o ServerAliveCountMax=10 -o StrictHostKeyChecking=no -o UserKnownHostsFile=/dev/null -i /var/lib/jenkins/workspace/PR-2603-12-a4fa5bb0-82da-4f2f-bc3f-9a63e6193ea9/e2essh admin@3.16.23.219 -- 'sudo bash /home/admin/e2e-testing/.ci/scripts/functional-test.sh'
Archive the artifacts
  • Took 0 min 0 sec . View more details here
  • Description: [2022-06-07T09:19:50.477Z] Archiving artifacts script returned exit code 2

🐛 Flaky test report

❕ There are test failures but not known flaky tests.

Expand to view the summary

Genuine test errors 2

💔 There are test failures but not known flaky tests, most likely a genuine test failure.

  • Name: Initializing / End-To-End Tests / fleet_sles15_fleet_mode / Deploying the agent – Fleet Mode
  • Name: Initializing / End-To-End Tests / fleet_debian_10_arm64_system_integration / Adding diskio system/metrics Integration to a Policy – System Integration

🤖 GitHub comments

To re-run your PR in the CI, just comment with:

  • /test : Re-trigger the build.

.ci/.e2e-platforms.yaml Outdated Show resolved Hide resolved
Copy link
Contributor

@mdelapenya mdelapenya left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This looks good to me, although we need one more thing, as described in https://github.com/elastic/e2e-testing/pull/2589/files#diff-53b78ab29e8f8423188da6c0806aaa9de90d39bd3502d83a655a1a68429fcfe2R43, which is to actually run the desired scenarios in the new platforms

.ci/.e2e-platforms.yaml Outdated Show resolved Hide resolved
.ci/.e2e-platforms.yaml Outdated Show resolved Hide resolved
@narph narph requested a review from mdelapenya June 3, 2022 14:56
@narph narph self-assigned this Jun 3, 2022
@narph narph added v8.4.0 area:ci Anything related to the CI labels Jun 3, 2022
@@ -5,51 +5,51 @@ SUITES:
scenarios:
Copy link
Contributor

@mdelapenya mdelapenya Jun 3, 2022

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think we want to include debian11 and ubuntu in the nightly builds. So I guess they should be added in this file too.

@jlind23 could you confirm?

@@ -5,54 +5,54 @@ SUITES:
scenarios:
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This file is mainly used by the test framework while developing it. The other descriptors are used by downstream jobs: Beats, Agent, Nightly...

.ci/.e2e-platforms.yaml Outdated Show resolved Hide resolved
@mergify
Copy link
Contributor

mergify bot commented Jun 3, 2022

This pull request is now in conflict. Could you fix it @narph? 🙏
To fixup this pull request, you can check out it locally. See documentation: https://help.github.com/articles/checking-out-pull-requests-locally/

git fetch upstream
git checkout -b add-debian-support upstream/add-debian-support
git merge upstream/main
git push upstream add-debian-support

@mdelapenya
Copy link
Contributor

@narph I'm seeing the very same error while creating all the new instances for Debian 11 and Ubuntu:

An exception occurred during task execution. To see the full traceback, use -vvv. The error was: InvalidParameterCombinationEnhanced networking with the Elastic Network Adapter (ENA) is required for the 't3.xlarge' instance type. Ensure that you are using an AMI that is enabled for ENA.c59200f8-6a5a-4e28-b750-160b59f2125c

Will fetch this PR locally and run it from local using the build scripts. Will ping you here with my investigation about that issue

@mdelapenya
Copy link
Contributor

@narph I replaced current Ubuntu AMI with the one provided by AWS as a Quickstart AMI and the creation works:

Screenshot 2022-06-06 at 12 22 52

I'm currently running a few scenarios on that Ubuntu to check it. If it works, I will push a commit to this branch with the changes. Same for Debian 11.

@mdelapenya
Copy link
Contributor

For Debian, I'm checking their website for the AMIs: https://wiki.debian.org/Cloud/AmazonEC2Image/Bullseye, where they say that ami-0c7c4e3c6b4941f0f is the AMI in us-east-2.

I do not know why I'm not able to discover that AMI ID in the AWS console 🤷 Anyway. I checked locally and I'm able to create a node with that AMI, successfully running the test scenarios on it 🚀

@mdelapenya
Copy link
Contributor

Ok, this is working now. There are two failures that I'd recommend to investigate before merging, as they affect Debian 11:

make -C .ci setup-stack  # it will fail as the fleet-server needs a different healthcheck for Kibana + Fleet
make -C .ci recreate-fleet-server # causes the stack to restart fleet-server
make -C .ci provision-node NODE_IMAGE=ami-0c7c4e3c6b4941f0f NODE_LABEL=debian_11_amd64
make -C .ci setup-node NODE_IMAGE=ami-0c7c4e3c6b4941f0f NODE_LABEL=debian_11_amd64
make -C .ci run-tests TAGS="backend_processes" NODE_LABEL=debian_11_amd64
make -C .ci run-tests TAGS="system_integration" NODE_LABEL=debian_11_amd64

@narph
Copy link
Contributor Author

narph commented Jun 7, 2022

Ok, this is working now. There are two failures that I'd recommend to investigate before merging, as they affect Debian 11:

make -C .ci setup-stack  # it will fail as the fleet-server needs a different healthcheck for Kibana + Fleet
make -C .ci recreate-fleet-server # causes the stack to restart fleet-server
make -C .ci provision-node NODE_IMAGE=ami-0c7c4e3c6b4941f0f NODE_LABEL=debian_11_amd64
make -C .ci setup-node NODE_IMAGE=ami-0c7c4e3c6b4941f0f NODE_LABEL=debian_11_amd64
make -C .ci run-tests TAGS="backend_processes" NODE_LABEL=debian_11_amd64
make -C .ci run-tests TAGS="system_integration" NODE_LABEL=debian_11_amd64

I see there are the same flaky tests, the Debian 11 tests just passed. Can you confirm?

@mdelapenya
Copy link
Contributor

Yes, it's seems the debian/Ubuntu support is at the same level than the rest of platforms.

LGTM

Copy link
Contributor

@mdelapenya mdelapenya left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Ready!! 🚀

@narph narph added the Team:Elastic-Agent-Control-Plane Label for the Agent Control Plane team label Jun 7, 2022
@narph narph requested review from a team, aleksmaus and michalpristas and removed request for a team June 7, 2022 11:32
@narph narph merged commit cdb396e into elastic:main Jun 7, 2022
@narph narph deleted the add-debian-support branch June 7, 2022 11:33
v1v added a commit to v1v/e2e-testing that referenced this pull request Jun 7, 2022
…port

* upstream/main:
  Add support for Debian 11 and Ubuntu 22.04 platforms (elastic#2603)
  fix: retire 8.1 snapshot from upgrades (elastic#2616)
mdelapenya added a commit to mdelapenya/e2e-testing that referenced this pull request Jun 14, 2022
* main:
  Add support for Debian 11 and Ubuntu 22.04 platforms (elastic#2603)
  fix: retire 8.1 snapshot from upgrades (elastic#2616)
  bump stack version 8.4.0-42ce0eef (elastic#2613)
  docs: document AWS requirements (elastic#2589)
  chore: move elastic-agent's k8s-autodiscover scenarios from beats to elastic-agent profile (elastic#2601)
mdelapenya added a commit to mdelapenya/e2e-testing that referenced this pull request Jun 17, 2022
* main: (22 commits)
  chore(jjbb): increase build timeout to 2h (elastic#2661)
  chore: increase build timeout to 2h (elastic#2660)
  feat: run tests on windows 2019 (elastic#2468)
  Remove aws instance reaper Jenkins job (elastic#2647)
  Update k8s version to v1.24 (elastic#2644)
  chore: simplify extracting info from the supported platforms (elastic#2637)
  ci: avoid running on branches that are not available anymore (elastic#2627)
  Add support for Debian 11 and Ubuntu 22.04 platforms (elastic#2603)
  fix: retire 8.1 snapshot from upgrades (elastic#2616)
  bump stack version 8.4.0-42ce0eef (elastic#2613)
  docs: document AWS requirements (elastic#2589)
  chore: move elastic-agent's k8s-autodiscover scenarios from beats to elastic-agent profile (elastic#2601)
  Add test scenario for elastic agent tags (elastic#2552)
  bump stack version 8.4.0-3525aaf7 (elastic#2597)
  bump stack version 8.4.0-df27a645 (elastic#2591)
  fix: agent directories must belong to root (elastic#2590)
  chore: bump maintenance versions in mergify (elastic#2563)
  chore: bump kubernetes versions (elastic#2562)
  fix: use fixed, valid version for protobuffers (elastic#2569)
  chore: do not run apm-server helm chart scenarios for Beats (elastic#2564)
  ...
- suite: "fleet"
scenarios:
- name: "Fleet"
tags: "fleet_mode_agent"
platforms: ["centos8_arm64", "centos8_amd64", "debian_arm64", "debian_amd64", "sles15"]
platforms: ["centos8_arm64", "centos8_amd64", " debian_10_arm64", "debian_10_amd64", "sles15"]
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@v1v we found it! 🤦

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
area:ci Anything related to the CI backport-skip Skip notification from the automated backport with mergify Team:Elastic-Agent-Control-Plane Label for the Agent Control Plane team v8.4.0
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants