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

Introduce aarch64 packaging #53914

Merged
merged 7 commits into from
Mar 21, 2020
Merged

Introduce aarch64 packaging #53914

merged 7 commits into from
Mar 21, 2020

Conversation

jasontedor
Copy link
Member

@jasontedor jasontedor commented Mar 21, 2020

This commit introduces aarch64 packaging, including bundling an aarch64 JDK distribution. We had to make some interesting choices here:

  • ML binaries are not compiled for aarch64, so for now we disable ML on aarch64
  • depending on underlying page sizes, we have to disable class data sharing

This commit introduces aarch64 packaging, including bundling an aarch64
JDK distribution. We had to make some interesting choices here:
 - ML binaries are not compiled for aarch64, so for now we disable ML on
   aarch64 by default
 - depending on underlying page sizes, we have to disable class data
   sharing
@jasontedor jasontedor added release highlight :Delivery/Packaging RPM and deb packaging, tar and zip archives, shell and batch scripts v8.0.0 v7.7.0 labels Mar 21, 2020
Copy link
Contributor

@mark-vieira mark-vieira left a comment

Choose a reason for hiding this comment

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

Boy, just shows how much boilerplate is involved here. There's probably room for improvement there but luckily we don't add new distribution types very often. LGTM 👍

FYI, we'll need to adapt the DistributionDownloadPlugin to the notion of an architecture as well once we want to start testing.

@jasontedor jasontedor merged commit 13f5631 into elastic:master Mar 21, 2020
jasontedor added a commit to jasontedor/elasticsearch that referenced this pull request Mar 21, 2020
This commit introduces aarch64 packaging, including bundling an aarch64
JDK distribution. We had to make some interesting choices here:
 - ML binaries are not compiled for aarch64, so for now we disable ML on
   aarch64
 - depending on underlying page sizes, we have to disable class data
   sharing
jasontedor added a commit that referenced this pull request Mar 22, 2020
This commit introduces aarch64 packaging, including bundling an aarch64
JDK distribution. We had to make some interesting choices here:
 - ML binaries are not compiled for aarch64, so for now we disable ML on
   aarch64
 - depending on underlying page sizes, we have to disable class data
   sharing
@jasontedor jasontedor deleted the aarch64 branch March 22, 2020 15:58
Comment on lines +191 to +192
archiveClassifier = 'linux-x86_64'
with archiveFiles(modulesFiles(true, 'linux'), 'tar', 'linux', 'x64', true, true)
Copy link
Contributor

Choose a reason for hiding this comment

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

Copy/paste error? I think these should be aarch64.

Copy link
Member Author

Choose a reason for hiding this comment

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

I pushed 80c24a0 directly to address this. Thanks for noticing.

Copy link
Contributor

Choose a reason for hiding this comment

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

Does the archiveClassifier also need to be updated? I thought it would be linux-aarch64.

Copy link
Member Author

Choose a reason for hiding this comment

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

Thanks again. 🤦‍♀

I pushed ba431a0.

@davidkyle
Copy link
Member

There is also the native controller to consider.

void spawnNativeControllers(final Environment environment) throws IOException {

It looks like the process is launched then dies immediately. There will be no sign of this in the logs as no code will try to connect to the controller because xpack.ml.enabled: false and the process failure is not logged.

Perhaps extend the property in plugin.descriptor.properties to has.native.controller.x64 and has.native.controller. aarch64 or simply don't don't spawn the controller on aarch64

@jasontedor
Copy link
Member Author

@davidkyle The spawner today has support for architectures, and skips trying to fork the native controller when it doesn't exist:

return plugin
.resolve("platform")
.resolve(PLATFORM_NAME)
.resolve("bin")
.resolve(PROGRAM_NAME);

return normalizedOs + "-" + normalizedArch;

final Path spawnPath = Platforms.nativeControllerPath(modules);
if (!Files.isRegularFile(spawnPath)) {
continue;
}

This means that when run on aarch64, since there is not an ML native controller at x-pack-ml/platform/linux-aarch64/bin/controller, the spawner will not even attempt to fork a native controller.

@davidkyle
Copy link
Member

👍 thanks for the explanation @jasontedor

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
:Delivery/Packaging RPM and deb packaging, tar and zip archives, shell and batch scripts release highlight Team:Delivery Meta label for Delivery team v7.7.0 v8.0.0-alpha1
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants