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

[BUG] Windows package doesn't contain a logs folder and doesn't start #1463

Closed
dblock opened this issue Oct 28, 2021 · 0 comments · Fixed by #4305
Closed

[BUG] Windows package doesn't contain a logs folder and doesn't start #1463

dblock opened this issue Oct 28, 2021 · 0 comments · Fixed by #4305
Labels
bug Something isn't working Build Libraries & Interfaces v2.3.0 'Issues and PRs related to version v2.3.0' windows

Comments

@dblock
Copy link
Member

dblock commented Oct 28, 2021

Describe the bug

If logs directory doesn't exist, startup will fail with Error opening log file 'logs/gc.log': No such file or directory.

To Reproduce

Coming from opensearch-project/opensearch-build#33 I assembled an OpenSearch Windows distribution, extracted it, created a demo certificate, then ran bin\opensearch.bat.

C:\Users\ADMINI~1\AppData\Local\Temp\2\OpenSearch>bin\opensearch.bat
Picked up _JAVA_OPTIONS: -Xmx4096M
Exception in thread "main" java.lang.RuntimeException: starting java failed with [1]
output:
[0.002s][error][logging] Error opening log file 'logs/gc.log': No such file or directory
[0.002s][error][logging] Initialization of output 'file=logs/gc.log' using options 'filecount=32,filesize=64m' failed.
error:
Picked up _JAVA_OPTIONS: -Xmx4096M
Invalid -Xlog option '-Xlog:gc*,gc+age=trace,safepoint:file=logs/gc.log:utctime,pid,tags:filecount=32,filesize=64m', see error log for details.
Error: Could not create the Java Virtual Machine.
Error: A fatal exception has occurred. Program will exit.
        at org.opensearch.tools.launchers.JvmErgonomics.flagsFinal(JvmErgonomics.java:139)
        at org.opensearch.tools.launchers.JvmErgonomics.finalJvmOptions(JvmErgonomics.java:101)
        at org.opensearch.tools.launchers.JvmErgonomics.choose(JvmErgonomics.java:72)
        at org.opensearch.tools.launchers.JvmOptionsParser.jvmOptions(JvmOptionsParser.java:152)
        at org.opensearch.tools.launchers.JvmOptionsParser.main(JvmOptionsParser.java:110)

Expected behavior
The windows distribution to just work.

Probably the windows-zip target needs to create an empty logs folder.

Host/Environment (please complete the following information):

  • Windows
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working Build Libraries & Interfaces v2.3.0 'Issues and PRs related to version v2.3.0' windows
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants