2018-08-07 16:59:56 +01:00
|
|
|
[[es-tmpdir]]
|
2020-10-19 12:59:44 -04:00
|
|
|
[discrete]
|
|
|
|
=== Temporary directory settings
|
2018-08-07 16:59:56 +01:00
|
|
|
|
2020-10-19 12:59:44 -04:00
|
|
|
By default, {es} uses a private temporary directory that the startup
|
2018-08-07 16:59:56 +01:00
|
|
|
script creates immediately below the system temporary directory.
|
|
|
|
|
2020-10-19 12:59:44 -04:00
|
|
|
On some Linux distributions, a system utility will clean files and directories
|
|
|
|
from `/tmp` if they have not been recently accessed. This behavior can lead to
|
|
|
|
the private temporary directory being removed while {es} is running if
|
2018-08-07 16:59:56 +01:00
|
|
|
features that require the temporary directory are not used for a long time.
|
2020-10-19 12:59:44 -04:00
|
|
|
Removing the private temporary directory causes problems if a feature that
|
|
|
|
requires this directory is subsequently used.
|
2018-08-07 16:59:56 +01:00
|
|
|
|
2020-10-19 12:59:44 -04:00
|
|
|
If you install {es} using the `.deb` or `.rpm` packages and run it
|
|
|
|
under `systemd`, the private temporary directory that {es} uses
|
2018-08-07 16:59:56 +01:00
|
|
|
is excluded from periodic cleanup.
|
|
|
|
|
2020-10-19 12:59:44 -04:00
|
|
|
If you intend to run the `.tar.gz` distribution on Linux or MacOS for
|
|
|
|
an extended period, consider creating a dedicated temporary
|
|
|
|
directory for {es} that is not under a path that will have old files
|
2018-08-07 16:59:56 +01:00
|
|
|
and directories cleaned from it. This directory should have permissions set
|
2020-10-19 12:59:44 -04:00
|
|
|
so that only the user that {es} runs as can access it. Then, set the
|
|
|
|
`$ES_TMPDIR` environment variable to point to this directory before starting
|
|
|
|
{es}.
|