# Logstash is complaining about the path of the certificates

**URL:** <https://discuss.elastic.co/t/logstash-is-complaining-about-the-path-of-the-certificates/38788>\
**Category:** Logstash\
**Created:** [January 9, 2016, 1:06pm UTC](https://discuss.elastic.co/t/logstash-is-complaining-about-the-path-of-the-certificates/38788 "2016-01-09T13:06:50Z")\
**Posts on this page:** 4\
**Page:** 1

<div class="post-metadata">

**Author:** ![zozo6015](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/zozo6015/32/12117_2.png) [@zozo6015](https://discuss.elastic.co/u/zozo6015)\
**Post date:** [January 9, 2016, 1:06pm UTC](https://discuss.elastic.co/t/logstash-is-complaining-about-the-path-of-the-certificates/38788/1 "2016-01-09T13:06:50Z")

</div>

Hello, I am running the latest version of logstash 2.1 and I have configured the certificates as it:

```
beats {
    port => 5044
    type => "logs"
    ssl => "true"
    ssl_certificate => "/etc/letsencrypt/live/core.z0z0.tk/cert.pem"
    ssl_key => "/etc/letsencrypt/live/core.z0z0.tk/privkey.pem"
}

```

I have run the logstash with test-check option and it was all good but when I start the logstash I get the following in the logstash.log

```
{:timestamp=>"2016-01-09T11:05:31.913000+0000", :message=>"Invalid setting for beats input plugin:\n\n input {\n beats {\n # This setting must be a path\n # File does not exist or cannot be opened /etc/letsencrypt/live/core.z0z0.tk/cert.pem\n ssl_certificate => \"/etc/letsencrypt/live/core.z0z0.tk/cert.pem\"\n ...\n }\n }", :level=>:error}
{:timestamp=>"2016-01-09T11:05:31.939000+0000", :message=>"Invalid setting for beats input plugin:\n\n input {\n beats {\n # This setting must be a path\n # File does not exist or cannot be opened /etc/letsencrypt/live/core.z0z0.tk/privkey.pem\n ssl_key => \"/etc/letsencrypt/live/core.z0z0.tk/privkey.pem\"\n ...\n }\n }", :level=>:error}
{:timestamp=>"2016-01-09T11:05:32.000000+0000", :message=>"Error: Something is wrong with your configuration."}
{:timestamp=>"2016-01-09T11:05:32.007000+0000", :message=>"You may be interested in the '--configtest' flag which you can\nuse to validate logstash's configuration before you choose\nto restart a running system."}

```

If I run the startup command as root from cli then logstash starts without any issue.

Anyone can suggest me a solution for this issue?

Regards,  
Peter

---

<div class="post-metadata">

**Author:** ![magnusbaeck](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/magnusbaeck/32/44943_2.png) [@magnusbaeck](https://discuss.elastic.co/u/magnusbaeck)\
**Post date:** [January 9, 2016, 3:34pm UTC](https://discuss.elastic.co/t/logstash-is-complaining-about-the-path-of-the-certificates/38788/2 "2016-01-09T15:34:10Z")

</div>

Apparently the logstash user (or whatever user you normally run Logstash as) doesn't have permissions to read the certificate and key files.

---

<div class="post-metadata">

**Author:** ![zozo6015](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/zozo6015/32/12117_2.png) [@zozo6015](https://discuss.elastic.co/u/zozo6015)\
**Post date:** [January 9, 2016, 3:43pm UTC](https://discuss.elastic.co/t/logstash-is-complaining-about-the-path-of-the-certificates/38788/3 "2016-01-09T15:43:41Z")

</div>

Copied the certificate to the logstash config folder and it works. Thanks for the help.

---

<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:** [July 6, 2017, 5:16am UTC](https://discuss.elastic.co/t/logstash-is-complaining-about-the-path-of-the-certificates/38788/4 "2017-07-06T05:16:15Z")

</div>


