Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Elastic Agent/Beats macOS ARM support strategy #21855

Open
ph opened this issue Oct 15, 2020 · 21 comments
Open

Elastic Agent/Beats macOS ARM support strategy #21855

ph opened this issue Oct 15, 2020 · 21 comments
Assignees
Labels
7.16-candidate Team:Elastic-Agent Label for the Agent team Team:Platforms Label for the Integrations - Platforms team

Comments

@ph
Copy link
Contributor

ph commented Oct 15, 2020

Apple is transitioning from x86_64 to ARM64. They say possibly by the end of 2020. This shouldn't impact Agent/Beats/Endpoint very much because ARM64 macs will be able to run x86_64 binaries. Moreover, macOS will support "fat" binaries that contain x86_64 and ARM64 code inside them.

For beats we need to investigate:

  • Fat binaries vs release specific artifacts.
  • Golang support for macOS arm.
  • Required build changes.
  • Required CI changes
  • Evaluate impacts on libraries that we depend.
  • Evaluate impacts on engineering
  • Testing
  • What happen with Code signing?
@ph ph added Team:Platforms Label for the Integrations - Platforms team Team:Ingest Management v7.11.0 labels Oct 15, 2020
@elasticmachine
Copy link
Collaborator

Pinging @elastic/integrations-platforms (Team:Platforms)

@elasticmachine
Copy link
Collaborator

Pinging @elastic/ingest-management (Team:Ingest Management)

@ph
Copy link
Contributor Author

ph commented Oct 15, 2020

@andresrc @urso We will need to find an owner for this.

@ph ph changed the title Agent/Beats/Endpoint macOS ARM support strategy Elastic Agent/Beats macOS ARM support strategy Oct 15, 2020
@ph ph added v7.12.0 and removed v7.11.0 labels Oct 29, 2020
@ph ph removed the v7.12.0 label Jan 6, 2021
@ph
Copy link
Contributor Author

ph commented Feb 9, 2021

@michalpristas is evaluating the emulation layer for the Elastic Agent.

@michalpristas
Copy link
Contributor

seems like emulation layer works ok for agent, agent installs ok and is capable of running and handling beats and endpoint.

what we need to look at is detection that we're running on macos ARM as agent logic is based on compile time variables and agent thinks it's running regular darwin. dashboards looks ok, cpu memory... populated.

running agent on m1 results in Unhealthy deployment on fleet as endpoint (at the time of testin) is failing on applying configuration and reports Degraded state back.

in progress of trying this out with universal binary of endpoint.

@michalpristas
Copy link
Contributor

talked to @ferullo about experienced behavior of Agent/Endpoint on M1 seems like everything is ok and for our purposes of install/uninstall it works.
will retry experiment once properly signed endpoint is available with universal binary

@andresrc
Copy link
Contributor

thanks!

@ph
Copy link
Contributor Author

ph commented Feb 10, 2021

@michalpristas Great news. In our discussion and comment you mentioned a few things that will need modifications. Can you create issues for them?

@urso
Copy link

urso commented Feb 10, 2021

In case any of these might become interesting:

@andresrc
Copy link
Contributor

Related:

Have we picked those changes in beats yet?
Do we need for tests / expect more changes (besides those related to building / packaging)?

@andresrc
Copy link
Contributor

/cc @fearful-symmetry

@fearful-symmetry
Copy link
Contributor

@andresrc I'm going to have a PR in today to actually pick those changes up in beats. I've been testing metricbeat and go 1.16 beta, and with the new libraries, I haven't run into any issues. One thing I haven't looked into is universal binaries

@ph
Copy link
Contributor Author

ph commented Feb 16, 2021

@michalpristas Have you followed "will retry experiment once properly signed endpoint is available with universal binary"

@EricDavisX
Copy link
Contributor

Where are we with this, can we collect a list of [ ] tasks to track? I had understood it was out of scope for Agent for 7.12 and just wanted to double check. I'd like to add a 7.13 label, if so. @ph @michalpristas

@EricDavisX
Copy link
Contributor

I have verified the signed BC4 Agent / Endpoint works seemingly well on the Mac Mini ARM M1 host PH offered.
I verified:

  • setup a policy with various integrations Windows / Linux / System / Fleet-server / Endpoint and monitor logs / errors
  • all data_streams expected seemed to be coming in.
  • spot check on a few docs to look at data
  • remove Endpoint from policy, add Endpoint back into policy - still works
  • restart the host and validate Agent comes back online

I did not cover stand-alone Metricbeat or Filebeat, note.

I'll track issues logged in a separate post.

@EricDavisX
Copy link
Contributor

So I'm not sure what else we need to do to close this out? Are we done? @michalpristas

@mostlyjason
Copy link

@bradenlpreston it looks like we made some great progress and Eric has tested M1 support and it works with Endpoint. Would you consider either of those blockers to calling it supported? https://github.com/elastic/endpoint-dev/issues/8644 #24610. The Docker one needs to be fixed, but I imagine running it on laptops is the main goal?

@EricDavisX did you also test the system package?

What else is needed to call this done?

@ferullo
Copy link

ferullo commented Apr 29, 2021

elastic/endpoint-dev#8644 should have been closed. I just did that.

@EricDavisX
Copy link
Contributor

Yes, @mostlyjason we tested System Integration, it worked in our test.

I just realized Beats team does not have CI coverage for macOS workers for Agent yet - that is a best practice, but we can take the calculated risk and cite this as done still. That is a group decision I suppose? I have linked that ticket to this.

@mostlyjason
Copy link

@ph it sounds like this is done and passing manual tests. Do you feel CI coverage is requirement? If not, could this be a beta release for 7.13?

I just checked with Braden and he is ok releasing it without docker support since endpoint security for laptops is the main business driver. Could we document that on our limitations page and schedule a fix for the next release?

@elasticmachine
Copy link
Collaborator

Pinging @elastic/agent (Team:Agent)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
7.16-candidate Team:Elastic-Agent Label for the Agent team Team:Platforms Label for the Integrations - Platforms team
Projects
None yet
Development

No branches or pull requests