What's the cause and the solution of this error

ubuntu 22.04 VM
elasticsearch,kibana,filebeat8.4.1 ,elastalert,suricata
i have this error in the log of elasticsearch when i try to start elasticsearch it failed to start

Failed to get the temporary directory; falling back to: /tmp
[2022-09-23T20:38:58,847][ERROR][o.e.b.Elasticsearch      ] [elastic] fatal exception while booting Elasticsearch
java.security.AccessControlException: access denied ("java.io.FilePermission" "/tmp" "read")

According to the error the user you are running elasticsearch as can not read (and probably write) to the /tmp directly.

Elasticsearch like mini programs need to be able to read and write from the /tmp directory.

You need to fix the permissions on that directory

1 Like

You need to fix the permissions on that directory
How can I?

Google is your friend :slight_smile:

$ sudo chmod 1777 /tmp

1 Like

Oh yea i google it now and i find it thanks @stephenb for help :smiley: