# Did not find expected \<document start\>

**URL:** <https://discuss.elastic.co/t/did-not-find-expected-document-start/164138>\
**Category:** Beats\
**Tags:** filebeat\
**Created:** [January 14, 2019, 12:16pm UTC](https://discuss.elastic.co/t/did-not-find-expected-document-start/164138 "2019-01-14T12:16:56Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![Urs\_Bronk](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/urs_bronk/32/44318_2.png) [@Urs\_Bronk](https://discuss.elastic.co/u/Urs_Bronk)\
**Post date:** [January 14, 2019, 12:16pm UTC](https://discuss.elastic.co/t/did-not-find-expected-document-start/164138/1 "2019-01-14T12:16:56Z")

</div>

Hi guys,

I've been at this for days, I'm still new to filebeat and have setup filebeat on a different server with the same config, but on this server doesn't matter what I try I get the following error and error after error.  
Exiting: error loading config file: yaml: line 160: did not find expected

Here is my filebeat config.

[https://pastebin.com/xdWSiTyg](https://pastebin.com/xdWSiTyg)

Thanks

---

<div class="post-metadata">

**Author:** ![shaunak](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/shaunak/32/6643_2.png) [@shaunak](https://discuss.elastic.co/u/shaunak)\
**Post date:** [January 15, 2019, 5:00am UTC](https://discuss.elastic.co/t/did-not-find-expected-document-start/164138/2 "2019-01-15T05:00:46Z")

</div>

YAML is very sensitive to indentation. I took your filebeat.yml and ran it through an online YAML validator here: [https://codebeautify.org/yaml-validator](https://codebeautify.org/yaml-validator).

There were leading spaces on line numbers 15, 21, and 161. After removing those, the YAML validates successfully. Here's the valid YAML:

[https://pastebin.com/8nFtSMTa](https://pastebin.com/8nFtSMTa)

---

<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:** [February 12, 2019, 5:00am UTC](https://discuss.elastic.co/t/did-not-find-expected-document-start/164138/3 "2019-02-12T05:00:47Z")

</div>

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