# Logstash Scheduled Task

**URL:** <https://discuss.elastic.co/t/logstash-scheduled-task/319822>\
**Category:** Logstash\
**Created:** [November 25, 2022, 1:09pm UTC](https://discuss.elastic.co/t/logstash-scheduled-task/319822 "2022-11-25T13:09:12Z")\
**Posts on this page:** 4\
**Page:** 1

<div class="post-metadata">

**Author:** ![smam](https://avatars.discourse-cdn.com/v4/letter/s/46a35a/32.png) [@smam](https://discuss.elastic.co/u/smam)\
**Post date:** [November 25, 2022, 1:09pm UTC](https://discuss.elastic.co/t/logstash-scheduled-task/319822/1 "2022-11-25T13:09:12Z")

</div>

I read this post: [Running Logstash on Windows | Logstash Reference [8.5] | Elastic](https://www.elastic.co/guide/en/logstash/current/running-logstash-windows.html)

And configured my Server to run Logstash every day.  
First question:  
I know that you can run logstash once and then just wait for new data. In our case, I use the file input plugin and the file is freshly generated each day. Thus I run logstash after creating this file

Second question:  
I encounter rights problems and logstash is not able to start due to another, old logstash proccess that couldnt be killed

How did you handle logstash automation?

---

<div class="post-metadata">

**Author:** ![willemdh](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/willemdh/32/16922_2.png) [@willemdh](https://discuss.elastic.co/u/willemdh)\
**Post date:** [November 26, 2022, 1:11pm UTC](https://discuss.elastic.co/t/logstash-scheduled-task/319822/2 "2022-11-26T13:11:56Z")

</div>

@smam Not sure what exactly you want to do, but some things to consider:

1. In my experience running Logstash on Windows, is sometimes less ideal for all kinds of reasons.
2. You might be better off using the Filebeat filestream module =\> [filestream input | Filebeat Reference [8.5] | Elastic](https://www.elastic.co/guide/en/beats/filebeat/current/filebeat-input-filestream.html)
3. If you absolutely need to use Logstash, I would let it run continuously as a Windows service.

Grtz

Willem

---

<div class="post-metadata">

**Author:** ![smam](https://avatars.discourse-cdn.com/v4/letter/s/46a35a/32.png) [@smam](https://discuss.elastic.co/u/smam)\
**Post date:** [November 30, 2022, 11:04am UTC](https://discuss.elastic.co/t/logstash-scheduled-task/319822/3 "2022-11-30T11:04:33Z")

</div>

Hello,  
I did not have a general question. I just wanted to know if running logstash as a windows service is just not working for us or if it is a general problem. I will try to implement your suggestions. Thank you!

---

<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:** [December 28, 2022, 11:05am UTC](https://discuss.elastic.co/t/logstash-scheduled-task/319822/4 "2022-12-28T11:05:02Z")

</div>

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