# Count total files

**URL:** https://discuss.elastic.co/t/count-total-files/227125
**Category:** Beats
**Tags:** filebeat
**Created:** [April 8, 2020, 12:39pm UTC](https://discuss.elastic.co/t/count-total-files/227125 "2020-04-08T12:39:24Z")
**Posts on this page:** 2
**Page:** 1

<div class="post-metadata">

### Author: ![Guerreiro\_Sousa](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/guerreiro_sousa/32/46074_2.png) [@Guerreiro\_Sousa](https://discuss.elastic.co/u/Guerreiro_Sousa)
#### Post date: [April 8, 2020, 12:39pm UTC](https://discuss.elastic.co/t/count-total-files/227125/1 "2020-04-08T12:39:25Z")

</div>

I have to count the total number of "xpto \* .log" files in a given directory, I imagine Filebeat does not do that.

Alternatively, can I just look at new files and not modified files? What are my alternatives to solve the file accounting problem?

---

<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: [May 6, 2020, 12:39pm UTC](https://discuss.elastic.co/t/count-total-files/227125/2 "2020-05-06T12:39:28Z")

</div>

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