# Filebeat not picking up the data and logs path from config file

**URL:** https://discuss.elastic.co/t/filebeat-not-picking-up-the-data-and-logs-path-from-config-file/320168
**Category:** Beats
**Tags:** filebeat
**Created:** [November 30, 2022, 3:33pm UTC](https://discuss.elastic.co/t/filebeat-not-picking-up-the-data-and-logs-path-from-config-file/320168 "2022-11-30T15:33:10Z")
**Posts on this page:** 3
**Page:** 1

<div class="post-metadata">

### Author: ![Arjun\_Meena](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/arjun_meena/32/109270_2.png) [@Arjun\_Meena](https://discuss.elastic.co/u/Arjun_Meena)
#### Post date: [November 30, 2022, 3:33pm UTC](https://discuss.elastic.co/t/filebeat-not-picking-up-the-data-and-logs-path-from-config-file/320168/1 "2022-11-30T15:33:10Z")

</div>

We are running the filebeat as a service on our ec2 machine. Below is the configuration file.

```auto
# ============================== Filebeat inputs ===============================

filebeat.inputs:

- type: log
  enabled: true
  paths:
    - /hybris/hybris/log/hybris.log
  ignore_older: 1h

  exclude_lines: ['.*ELB-HealthChecker', '.*healthcheck.jsp']
  exclude_files: ['.gz$']

  fields:
        env: ******
        application: ********
        topic: commerce-logs

  multiline.type: pattern
  multiline.pattern: '(\d{4}\-\d{2}\-\d{2})'
  multiline.negate: true
  multiline.match: after

- type: log
  enabled: true
  paths:
    - /hybris/hybris/log/tomcat/access*.log
  ignore_older: 1h

  exclude_lines: ['.*ELB-HealthChecker', '.*healthcheck.jsp']
  exclude_files: ['.gz$']

  fields:
        env: *****
        application: ******
        topic: commerceaccess-logs

- type: log

  enabled: true
  paths:
    - /hybris/hybris/log/tomcat/console*.log
  ignore_older: 1h

  exclude_lines: ['.*ELB-HealthChecker', '.*healthcheck.jsp']
  exclude_files: ['.gz$']

  fields:
        env: ****
        application: *****
        topic: commerceconsole-logs

path.data: /var/lib/filebeat-new
path.config: /etc/filebeat
path.logs: /var/log/filebeat-new

#------------------------------Kafka Output-------------------------------------
output.kafka:
  # initial brokers for reading cluster metadata
  hosts: [" ***** :9092"]

  # message topic selection + partitioning
  topic: '%{[fields.topic]}'
  codec.json:
    pretty: true
  partition.round_robin:
    reachable_only: true

  required_acks: 1
  compression: gzip
  max_message_bytes: 1000000

```

We are mentioning the data path and the log path in the configuration file but when we are starting it, it is picking up a different data and log path. Below is the attached screenshot.

 ![image](https://us1.discourse-cdn.com/elastic/original/3X/1/5/15155b1ab0eb1f8d271b40226248c1558c737da0.png)

---

<div class="post-metadata">

### Author: ![Arjun\_Meena](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/arjun_meena/32/109270_2.png) [@Arjun\_Meena](https://discuss.elastic.co/u/Arjun_Meena)
#### Post date: [November 30, 2022, 5:09pm UTC](https://discuss.elastic.co/t/filebeat-not-picking-up-the-data-and-logs-path-from-config-file/320168/2 "2022-11-30T17:09:03Z")

</div>

Can anybody help out on this please. Really need to get this done by today. Any help would be really appreciated.

---

<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, 7:09pm UTC](https://discuss.elastic.co/t/filebeat-not-picking-up-the-data-and-logs-path-from-config-file/320168/3 "2022-12-28T19:09:51Z")

</div>

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