# Unable to send log files where newline character is not present

**URL:** <https://discuss.elastic.co/t/unable-to-send-log-files-where-newline-character-is-not-present/249871>\
**Category:** Beats\
**Tags:** filebeat\
**Created:** [September 24, 2020, 6:59pm UTC](https://discuss.elastic.co/t/unable-to-send-log-files-where-newline-character-is-not-present/249871 "2020-09-24T18:59:16Z")\
**Posts on this page:** 4\
**Page:** 1

<div class="post-metadata">

**Author:** ![anirbansaha](https://avatars.discourse-cdn.com/v4/letter/a/839c29/32.png) [@anirbansaha](https://discuss.elastic.co/u/anirbansaha)\
**Post date:** [September 24, 2020, 6:59pm UTC](https://discuss.elastic.co/t/unable-to-send-log-files-where-newline-character-is-not-present/249871/1 "2020-09-24T18:59:16Z")

</div>

The log data which I am trying to send is a single line in file similar to the following  
[{"empid" : "1", "empname": "anirban", "location":"India"}]

It is not having newline at the end.

How to work for this? If this type of data is generated by the application

---

<div class="post-metadata">

**Author:** ![kvch](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/kvch/32/72058_2.png) [@kvch](https://discuss.elastic.co/u/kvch)\
**Post date:** [September 25, 2020, 3:23pm UTC](https://discuss.elastic.co/t/unable-to-send-log-files-where-newline-character-is-not-present/249871/2 "2020-09-25T15:23:42Z")

</div>

Unfortunately, Filebeat requires a newline at the end of each log. Otherwise, it cannot tell if a line is finished or not. I suggest you add a newline character from a script.

---

<div class="post-metadata">

**Author:** ![anirbansaha](https://avatars.discourse-cdn.com/v4/letter/a/839c29/32.png) [@anirbansaha](https://discuss.elastic.co/u/anirbansaha)\
**Post date:** [September 28, 2020, 9:13am UTC](https://discuss.elastic.co/t/unable-to-send-log-files-where-newline-character-is-not-present/249871/3 "2020-09-28T09:13:18Z")

</div>

Thanks for the response. But it would have been better if filebeat make an enhancement to read the files not having new line character at the end

---

<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 26, 2020, 11:13am UTC](https://discuss.elastic.co/t/unable-to-send-log-files-where-newline-character-is-not-present/249871/4 "2020-10-26T11:13:20Z")

</div>

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