# Logstash service outputs only a few logs from input file

**URL:** <https://discuss.elastic.co/t/logstash-service-outputs-only-a-few-logs-from-input-file/353183>\
**Category:** Logstash\
**Created:** [February 13, 2024, 2:59pm UTC](https://discuss.elastic.co/t/logstash-service-outputs-only-a-few-logs-from-input-file/353183 "2024-02-13T14:59:28Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![vuvu](https://avatars.discourse-cdn.com/v4/letter/v/8c91f0/32.png) [@vuvu](https://discuss.elastic.co/u/vuvu)\
**Post date:** [February 13, 2024, 2:59pm UTC](https://discuss.elastic.co/t/logstash-service-outputs-only-a-few-logs-from-input-file/353183/1 "2024-02-13T14:59:28Z")

</div>

hi!  
Since now, I have started Logstash by running the command:

```auto
/usr/share/logstash/bin/logstash --path.settings /etc/logstash/ --path.data sensor39 -f /etc/logstash/conf.d/logstash-config.conf

```

and it successfully sent all of the logs and I could see them on the dashboard.  
 ![input1](https://us1.discourse-cdn.com/elastic/original/3X/7/a/7a17dca3f133190c1a40dcf433c823cea6a2985d.png)

But now, I have configured the Logstash service unit file to this:

```auto
[Unit]
Description=logstash

[Service]
Type=simple
User=root
Group=root
EnvironmentFile=-/etc/default/logstash
ExecStart=/usr/share/logstash/bin/logstash --path.settings /etc/logstash --path.data sensor39 -f /etc/logstash/conf.d/logstash-config.conf 
Restart=on-failure
RestartSec=60
WorkingDirectory=/usr/share/logstash
Nice=19
LimitNOFILE=16384
SyslogIdentifier=logstash

[Install]
WantedBy=multi-user.target

```

so that I can just start the Logstash service in order to send the logs. The problem is that only a few of the logs can be seen now on the dashboard.  
 ![input2](https://us1.discourse-cdn.com/elastic/original/3X/1/f/1fb9128a7841480dcb52cb76e9b632940ad076b8.png)  
Why does this happen and how can I fix it? Please, help.

---

<div class="post-metadata">

**Author:** ![Rios](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/rios/32/95745_2.png) [@Rios](https://discuss.elastic.co/u/Rios)\
**Post date:** [February 13, 2024, 7:14pm UTC](https://discuss.elastic.co/t/logstash-service-outputs-only-a-few-logs-from-input-file/353183/2 "2024-02-13T19:14:58Z")

</div>

> --path.data sensor39

What is sensor 39? A directory?  
What is the input for logstash-config.conf? TCP?

> `path.data` - The directory that Logstash and its plugins use for any persistent needs. `LOGSTASH_HOME/data`

The logstash service is run under "logstash" user, all directory which use must be accessible to that user: path.data, path.logs, path.config

---

<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:** [March 12, 2024, 7:15pm UTC](https://discuss.elastic.co/t/logstash-service-outputs-only-a-few-logs-from-input-file/353183/3 "2024-03-12T19:15:39Z")

</div>

Closed on March 12, 2024, 7:15pm UTC

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