# Metricbeat: Filtering processes based on Command Line parameters

**URL:** <https://discuss.elastic.co/t/metricbeat-filtering-processes-based-on-command-line-parameters/245433>\
**Category:** Beats\
**Tags:** metricbeat\
**Created:** [August 18, 2020, 1:47pm UTC](https://discuss.elastic.co/t/metricbeat-filtering-processes-based-on-command-line-parameters/245433 "2020-08-18T13:47:02Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![musician](https://avatars.discourse-cdn.com/v4/letter/m/dc4da7/32.png) [@musician](https://discuss.elastic.co/u/musician)\
**Post date:** [August 18, 2020, 1:47pm UTC](https://discuss.elastic.co/t/metricbeat-filtering-processes-based-on-command-line-parameters/245433/1 "2020-08-18T13:47:02Z")

</div>

Hello,  
I have two questions:

1. We have multiple java processes that we would like to connect metrics for. Each of these processes has a custom name as a part of the command line. Since the process name for each of them is "java.exe", it is hard to know which metrics are for which process. Is there any way we can tag the collected metrics to have a specific parameter we specify in the command line?
2. Would the following enable the collection of metrics for all java processes?  
metricbeat.modules:

- name: system  
metricsets: [process]  
processes: ['^java.exe$']

---

<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:** [September 15, 2020, 3:47pm UTC](https://discuss.elastic.co/t/metricbeat-filtering-processes-based-on-command-line-parameters/245433/2 "2020-09-15T15:47:08Z")

</div>

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