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

Configure error file for archive packages #29129

Merged
merged 3 commits into from
Mar 18, 2018
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion distribution/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -268,7 +268,7 @@ subprojects {
'error.file': [
'deb': "-XX:ErrorFile=/var/log/elasticsearch/hs_err_pid%p.log",
'rpm': "-XX:ErrorFile=/var/log/elasticsearch/hs_err_pid%p.log",
'def': "#-XX:ErrorFile=/error/file/path"
'def': "-XX:ErrorFile=logs/hs_err_pid%p.log"
],

'stopping.timeout': [
Expand Down
20 changes: 8 additions & 12 deletions docs/reference/setup/important-settings/error-file.asciidoc
Original file line number Diff line number Diff line change
@@ -1,16 +1,12 @@
[[error-file-path]]
=== JVM fatal error logs

The <<rpm,RPM>> and <<deb,Debian>> package distributions default to configuring
the JVM to write fatal error logs to `/var/lib/elasticsearch`; these are logs
produced by the JVM when it encounters a fatal error (e.g., a segmentation
fault). If this path is not suitable for receiving logs, you should modify the
entry `-XX:ErrorFile=/var/lib/elasticsearch/hs_err_pid%p.log` in
By default, Elasticsearch configures the JVM to write fatal error logs
to the default logging directory (this is `/var/log/elasticsearch` for
the <<rpm,RPM>> and <<deb,Debian>> package distributions, and the `logs`
directory under the root of the Elasticsearch installation for the
<<zip-targz,tar and zip>> archive distributions). These are logs
produced by the JVM when it encounters a fatal error (e.g., a
segmentation fault). If this path is not suitable for receiving logs,
you should modify the entry `-XX:ErrorFile=...` in
<<jvm-options,`jvm.options`>> to an alternate path.

Note that the archive distributions do not configure the error file path by
default. Instead, the JVM will default to writing to the working directory for
the Elasticsearch process. If you wish to configure an error file path, you
should modify the entry `#-XX:ErrorFile=/error/file/path` in
<<jvm-options,`jvm.options`>> to remove the comment marker `#` and to specify an
actual path.