# Filebeat locks file when logstash is not runnig

**URL:** <https://discuss.elastic.co/t/filebeat-locks-file-when-logstash-is-not-runnig/66719>\
**Category:** Beats\
**Tags:** filebeat\
**Created:** [November 21, 2016, 1:22pm UTC](https://discuss.elastic.co/t/filebeat-locks-file-when-logstash-is-not-runnig/66719 "2016-11-21T13:22:37Z")\
**Posts on this page:** 1\
**Showing post:** 8

<div class="post-metadata">

**Author:** ![ruflin](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/ruflin/32/3116_2.png) [@ruflin](https://discuss.elastic.co/u/ruflin)\
**Post date:** [November 22, 2016, 2:41pm UTC](https://discuss.elastic.co/t/filebeat-locks-file-when-logstash-is-not-runnig/66719/8 "2016-11-22T14:41:16Z")

</div>

Seems to be the day of RollingFileAppender: [Log entries gets truncated on file rotation](https://discuss.elastic.co/t/log-entries-gets-truncated-on-file-rotation/66725/6?u=ruflin) Or is this other thread somehow related / same company?

The part I still didn't understand about `RollingFileAppender` is when the initial file gets truncated / removed?

---

_[View the full topic](https://discuss.elastic.co/t/filebeat-locks-file-when-logstash-is-not-runnig/66719)._
