Exception in thread "main" java.nio.file.AccessDeniedException

I'm getting the following error when running elasticsearch.bat

C:\Program Files\Elastic\Elasticsearch\7.7.0\bin> .\elasticsearch.bat
Exception in thread "main" java.nio.file.AccessDeniedException: C:\ProgramData\Elastic\Elasticsearch\config\jvm.options
at java.base/sun.nio.fs.WindowsException.translateToIOException(WindowsException.java:89)
at java.base/sun.nio.fs.WindowsException.rethrowAsIOException(WindowsException.java:103)
at java.base/sun.nio.fs.WindowsException.rethrowAsIOException(WindowsException.java:108)
at java.base/sun.nio.fs.WindowsFileSystemProvider.newByteChannel(WindowsFileSystemProvider.java:235)
at java.base/java.nio.file.Files.newByteChannel(Files.java:370)
at java.base/java.nio.file.Files.newByteChannel(Files.java:421)
at java.base/java.nio.file.spi.FileSystemProvider.newInputStream(FileSystemProvider.java:420)
at java.base/java.nio.file.Files.newInputStream(Files.java:155)
at org.elasticsearch.tools.launchers.JvmOptionsParser.readJvmOptionsFiles(JvmOptionsParser.java:169)
at org.elasticsearch.tools.launchers.JvmOptionsParser.jvmOptions(JvmOptionsParser.java:130)
at org.elasticsearch.tools.launchers.JvmOptionsParser.main(JvmOptionsParser.java:95)

Welcome to our community! :D@

Does your user have the right permissions on that file?

Yes, I do. I even given Everyone to READ and EXECUTE, but still same exception error.

This topic was automatically closed 28 days after the last reply. New replies are no longer allowed.