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

Support for Graylog 5.x #136

Open
pschichtel opened this issue Dec 31, 2022 · 12 comments
Open

Support for Graylog 5.x #136

pschichtel opened this issue Dec 31, 2022 · 12 comments
Labels
bug Something isn't working

Comments

@pschichtel
Copy link

When upgrading the image to 5.0.1 graylog fails to start up with the following message:

Unrecognized VM option 'UseCGroupMemoryLimitForHeap'

I guess the reason for this is that fact that graylog 5 runs on Java 17.

Other significant changes in graylog 5:

  • Minimum MongoDB version is now 5, with support for 6.
  • Support for OpenSearch 2.x has been added.
@pschichtel pschichtel added the bug Something isn't working label Dec 31, 2022
@mazmar
Copy link
Contributor

mazmar commented Jan 2, 2023

I am facing the same issue, but one thing to note is that 4.3.8 already supports mongodb 5.x so I was able to upgrade mongodb and still run the 4.3.8.

as @pschichtel said it crashes on the uncrecognized option

@pschichtel
Copy link
Author

I removed the option in a local copy of the chart and graylog starts up as expected, but I'm still facing other issues while attempting to use OpenSearch (using the opensearch operator). Once I have it running I intent to open a PR.

@pschichtel
Copy link
Author

4.3.8 already supports mongodb 5.x

@mazmar do you have a source for this?

@pschichtel
Copy link
Author

pschichtel commented Jan 2, 2023

Ok found it.

The Graylog 5 upgrade documentation confirms it: https://go2docs.graylog.org/5-0/upgrading_graylog/upgrading_graylog.html#version-compatibility
The Graylog 4.x installation documentation does not list it, but I guess they haven't updated that one: https://go2docs.graylog.org/4-x/downloading_and_installing_graylog/installing_graylog.html

@mazmar
Copy link
Contributor

mazmar commented Jan 3, 2023

Sorry, yes you are correct they did not update the documentation for 4.x I did not notice that. I only checked the upgrade instructions last week.

Anyway, I've set the heap manually as it said in values.yaml and it doesn't use the option UseCGroupMemoryLimitForHeap. It started correctly after that and I didn't need to adjust anything else. I am running unsupported ES 7.14.

Only problem is that after upgrading mongo to last version 5 from bitnami the arbitter is broken :( but that is not part of this chart. I will upgrade to mongo 6 this week.

@dsiperek-vendavo
Copy link

I was able to upgrade also by just setting the heapSize in value.yaml file.

@pauronda-visma
Copy link

pauronda-visma commented Jan 16, 2023

Hi there.
I followed your steps:

  • set heapSize
  • used last bitnami mongodb (version 6.0.3) chart
  • used opensearch 2.3.0 deployed with official helm chart
  • Graylog image: graylog/graylog:5.0.2

It almost worked, but it gets stuck in this point:
/entrypoint.sh: line 56: 37 Killed "${JAVA_HOME}/bin/java" ${GRAYLOG_SERVER_JAVA_OPTS} -jar -Dlog4j.configurationFile=${GRAYLOG_HOME}/config/log4j2.xml -Djava.library.path=${GRAYLOG_HOME}/lib/sigar/ -Dgraylog2.installation_source=docker ${GRAYLOG_HOME}/graylog.jar server -f ${GRAYLOG_HOME}/config/graylog.conf

I feel that maybe is the ${GRAYLOG_SERVER_JAVA_OPTS} parameter in -jar on the entrypoint.sh

"${JAVA_HOME}/bin/java" \

Could you help me?

@pauronda-visma
Copy link

pauronda-visma commented Jan 16, 2023

Hi again,
sorry for bothering you.

It worked after modifying entrypoint.sh

I hardcoded the Java VM options from graylog 5 docker repository and worked.

-Dlog4j2.formatMsgNoLookups=true -Djdk.tls.acknowledgeCloseNotify=true -XX:+UnlockExperimentalVMOptions -XX:-OmitStackTraceInFastThrow -XX:+UseG1GC -server

More info:
https://github.com/Graylog2/graylog-docker/blob/56c630a6c43a98b49802555bea314cf132f1a86a/docker/oss/Dockerfile#L67

EDIT: I realized it can be passed as a value using greylog.javaOpts

javaOpts: "-Dlog4j2.formatMsgNoLookups=true -Djdk.tls.acknowledgeCloseNotify=true -XX:+UnlockExperimentalVMOptions -XX:NewRatio=1 -XX:MaxMetaspaceSize=256m -server -XX:+ResizeTLAB -XX:-OmitStackTraceInFastThrow"

@pschichtel
Copy link
Author

@pauronda-visma Intersting. for me it started, but the UI was unable to perform search API requests against the OpenSearch instance. I haven't been able to get back to my local setup for this.

@pauronda-visma
Copy link

Same was for me, but after removing the value graylog.elasticsearch.version on values.yaml it worked for me.
https://github.com/KongZ/charts/blob/main/charts/graylog/values.yaml#L403

More info:
#133
Graylog2/graylog2-server#14236

@luizjr
Copy link
Contributor

luizjr commented Jan 26, 2023

Error, not connecting to opensearch cluster

image

@luizjr
Copy link
Contributor

luizjr commented Jan 26, 2023

I managed to update, and I made a pull request.

#138

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

5 participants