path-settings.asciidoc 1.2 KB

12345678910111213141516171819202122232425262728
  1. [[path-settings]]
  2. [discrete]
  3. ==== Path settings
  4. {es} writes the data you index to indices and data streams to a `data`
  5. directory. {es} writes its own application logs, which contain information about
  6. cluster health and operations, to a `logs` directory.
  7. For <<targz,macOS `.tar.gz`>>, <<targz,Linux `.tar.gz`>>, and
  8. <<zip-windows,Windows `.zip`>> installations, `data` and `logs` are
  9. subdirectories of `$ES_HOME` by default. However, files in `$ES_HOME` risk
  10. deletion during an upgrade.
  11. In production, we strongly recommend you set the `path.data` and `path.logs` in
  12. `elasticsearch.yml` to locations outside of `$ES_HOME`. <<docker,Docker>>,
  13. <<deb,Debian>>, <<rpm,RPM>>, <<brew,macOS Homebrew>>, and <<windows,Windows
  14. `.msi`>> installations write data and log to locations outside of `$ES_HOME` by
  15. default.
  16. IMPORTANT: To avoid errors, only {es} should open files in the `path.data`
  17. directory. Exclude the `path.data` directory from other services that may open
  18. and lock its files, such as antivirus or backup programs.
  19. Supported `path.data` and `path.logs` values vary by platform:
  20. include::{es-repo-dir}/tab-widgets/code.asciidoc[]
  21. include::{es-repo-dir}/tab-widgets/customize-data-log-path-widget.asciidoc[]