# Logstash permission issue and need help on this

**URL:** <https://discuss.elastic.co/t/logstash-permission-issue-and-need-help-on-this/201515>\
**Category:** Logstash\
**Created:** [September 29, 2019, 4:08am UTC](https://discuss.elastic.co/t/logstash-permission-issue-and-need-help-on-this/201515 "2019-09-29T04:08:01Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![Blason](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/blason/32/42284_2.png) [@Blason](https://discuss.elastic.co/u/Blason)\
**Post date:** [September 29, 2019, 4:08am UTC](https://discuss.elastic.co/t/logstash-permission-issue-and-need-help-on-this/201515/1 "2019-09-29T04:08:02Z")

</div>

Hi Folks,

I have directory /var/log/data where my files are being written and those are the docker volumes.

drwxrwxr-x 25 pbdocker pbdocker 4096 Sep 29 02:49 data

When I am trying to run the logstash to read the files inside data folder I am getting below error. Wondering what permission would be appropriate to make it work?

```auto
[2019-09-29T04:03:03,563][INFO][logstash.agent] Pipelines running {:count=>1, :running_pipelines=>[:main], :non_running_pipelines=>[]}
[2019-09-29T04:03:03,594][WARN][filewatch.tailmode.handlers.createinitial] failed to open /var/log/data/p0f/log/p0f.json: #<Errno::EACCES: Permission denied - /var/log/data/p0f/log/p0f.json>, ["org/jruby/RubyIO.java:1236:in `sysopen'", "org/jruby/RubyFile.java:367:in `initialize'", "org/jruby/RubyIO.java:1155:in `open'"]
[2019-09-29T04:03:03,820][INFO][logstash.agent] Successfully started Logstash API endpoint {:port=>9601}

```

---

<div class="post-metadata">

**Author:** ![Badger](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/badger/32/25190_2.png) [@Badger](https://discuss.elastic.co/u/Badger)\
**Post date:** [September 29, 2019, 12:48pm UTC](https://discuss.elastic.co/t/logstash-permission-issue-and-need-help-on-this/201515/2 "2019-09-29T12:48:22Z")

</div>

It is able to find the file, so the permissions on /var/log/data, /var/log/data/p0f, and /var/log/data/p0f/log must be OK. The problem is the permissions on the file itself. logstash needs read access to it.

---

<div class="post-metadata">

**Author:** ![system](https://us1.discourse-cdn.com/elastic/original/3X/1/a/1ac57faf039f6b580b3f104ef42a2a89e41014de.png) [@system](https://discuss.elastic.co/u/system)\
**Post date:** [October 27, 2019, 12:48pm UTC](https://discuss.elastic.co/t/logstash-permission-issue-and-need-help-on-this/201515/3 "2019-10-27T12:48:24Z")

</div>

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