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

Set LIBFFI_TMPDIR at startup (#80651) #80699

Merged

Commits on Nov 15, 2021

  1. Set LIBFFI_TMPDIR at startup (elastic#80651)

    Today if `libffi` cannot allocate pages of memory which are both
    writeable and executable then it will attempt to write code to a
    temporary file. Elasticsearch configures itself a suitable temporary
    directory for use by JNA but by default `libffi` won't find this
    directory and will try various other places. In certain configurations,
    none of the other places that `libffi` tries are suitable. With older
    versions of JNA this would result in a `SIGSEGV`; since elastic#80617 the JVM
    will exit with an exception.
    
    With this commit we use the `LIBFFI_TMPDIR` environment variable to
    configure `libffi` to use the same directory as JNA for its temporary
    files if they are needed.
    
    Closes elastic#18272
    Closes elastic#73309
    Closes elastic#74545
    Closes elastic#77014
    Closes elastic#77053
    Relates elastic#77285
    
    Co-authored-by: Rory Hunter <roryhunter2@gmail.com>
    DaveCTurner and pugnascotia committed Nov 15, 2021
    Configuration menu
    Copy the full SHA
    ce59bd2 View commit details
    Browse the repository at this point in the history
  2. Fix incorrect SSL usage

    pugnascotia committed Nov 15, 2021
    Configuration menu
    Copy the full SHA
    f37cab6 View commit details
    Browse the repository at this point in the history