---
title: "Edge collection rules"
product: "Axoflow 0.90"
url: "https://axoflow.com/docs/axoflow/0.90/data-sources/collection-rules/"
description: "Create, modify, and extend the collection rules that tell edge hosts which files, journals, and Windows event channels to collect."
last_modified: "2026-10-13T12:04:26+02:00"
---

> For the complete documentation index, see [llms.txt](https://axoflow.com/docs/axoflow/0.90/llms.txt).

# Edge collection rules

Create, modify, and extend the collection rules that tell edge hosts which files, journals, and Windows event channels to collect.

Collection rules define how edge hosts collect their local data. To collect data from non-edge sources, see [AxoRouter connector rules](https://axoflow.com/docs/axoflow/0.90/data-sources/connector-rules/index.md).

- Sources are hosts that are sending data to a data aggregator, like AxoRouter.
- Edges are source hosts that are running a collector agent managed by AxoConsole, or have an Axolet agent reporting metrics from the host.

Collection rules are high-level policies that determine how data should be collected on a set of edge hosts based on dynamic host labels.

![Collection rules on edge hosts](https://axoflow.com/docs/axoflow/0.90/img/figure-collection-data-forwarding-rules.svg)

To see every collection rule configured in AxoConsole, select **Sources > Collection Rules** from the main menu.

![Collection rules list](https://axoflow.com/docs/axoflow/0.90/img/data-management/collection-rules-list_hu_9576329ae8b5b04f.webp)

Collection rules have the following main elements:

- the way they collect data (for example, from files, or Windows Event Logs), and other specific parameters (for example, the path and filename)
- the edge selector, which determines the list of edge hosts that will create a collector based on that rule.

  You can use any labels and metadata of the edge hosts in the edge selectors, for example, the hostname, or any [custom labels](https://axoflow.com/docs/axoflow/0.90/onboard-hosts/hosts/add-host-metadata/index.md)
  . For example, using the `label.product = windows` selector will create a collector only on Windows hosts.

To show the details of a collection rule, select more_vert
> **Details** on its card. The details include:

- The list of **Matched edges**: the edge hosts that will have a collector based on that rule. If you select the name of a matched edge host, the **Connectors** page of that host opens, showing you the collectors configured for that host.

  ![Details of a collection rule](https://axoflow.com/docs/axoflow/0.90/data-sources/collection-rules/collection-rule-details_hu_54f8c7651c2fee1e.webp)

- The **Status** of the rule:

  - **Idle**: The rule doesn’t match any hosts currently.
  - **Provisioned**: Connectors based on this rule were successfully provisioned for every matching host.
  - **Error**: Some error(s) occurred while provisioning connectors based on this rule. See the **Status message** field for details.
  - **Unknown**: The rule is in an unknown state.
- **Attributes**: Various significant attributes of connectors provisioned based on this rule.

## Create data collection rule

To create a new collection rule, complete the following steps.

1. Select **Sources > Collection Rules > Add Collection Rule**. (Alternatively, you can select **Add Connector > Add a data collection rule** on the **Connectors** page of an edge host.)

   ![Collection rules list](https://axoflow.com/docs/axoflow/0.90/img/data-management/collection-rules-list_hu_9576329ae8b5b04f.webp)
2. Select the type of collector you want to create. For example, **File Collector**. The following collector types are available:

   - [File Collector](https://axoflow.com/docs/axoflow/0.90/data-sources/collection-rules/file-collector/index.md)
     (OpenTelemetry)
   - [Journald Collector](https://axoflow.com/docs/axoflow/0.90/data-sources/collection-rules/journald/index.md)
     (OpenTelemetry)
   - [Windows Event Log](https://axoflow.com/docs/axoflow/0.90/data-sources/collection-rules/windows-event-log/index.md)
   - [Windows Event Tracing (ETW)](https://axoflow.com/docs/axoflow/0.90/data-sources/collection-rules/windows-event-tracing/index.md)
3. Configure the collection rule.

   1. Enter a name for the collection rule into the **Collection rule name** field.

      ![Generic collection rule parameters](https://axoflow.com/docs/axoflow/0.90/img/collection-rule-generic_hu_3ae64d70f2d3073f.webp)
   2. (Optional) Add labels to the collection rule.

      AxoConsole automatically adds the following selectors based on the collector type:

      - **File Collector**: `vendor = opentelemetry` `product = otel-file`
      - **Journald Collector**: `vendor = opentelemetry` `product = otel-journald`
      - **Windows Event Log**: `vendor = microsoft` `product = windows-event-log`
      - **Windows Event Tracing**: `vendor = microsoft` `product = windows-event-tracing`

      You can use these metrics labels as:

      - labels in **Customize Graph** on the [Analytics page](https://axoflow.com/docs/axoflow/0.90/metrics/analytics/index.md)
      - in the **Filter labels** field during [log tapping](https://axoflow.com/docs/axoflow/0.90/onboard-hosts/log-tapping/index.md)
      - in [Flow Processing steps](https://axoflow.com/docs/axoflow/0.90/data-management/processing/index.md)
        , for example, in the **Query** field of **Select Messages** steps.

      For edge-related metrics, see the metrics beginning with [`edge_connector`](https://axoflow.com/docs/axoflow/0.90/reference/message-schema/reference/index.md#meta.edge.connector.labels)
   3. Set the **Edge selector** for the collection rule. The selector determines which edge hosts will have a collector based on this collection rule.

      ![Edge selectors](https://axoflow.com/docs/axoflow/0.90/img/collection-rule-edge-selector_hu_9519da000ca5a8ae.webp)

      - Only edge hosts will match the rule.
      - If you leave the edge selector empty, the rule matches every edge host.
      - To select only a specific host, set the `name` field to the name of the host as selector.
      - If you set multiple fields in the selector, the collection rule will apply only to edge hosts that match all elements of the selector. (There in an AND relationship between the fields.) For example, `label.location = us-east-1 AND label.product = windows`
      - AxoConsole automatically adds the following selectors based on the collector type:

        - **Journald Collector**: `label.platform = linux`
        - **Windows Event Log**: `label.platform = windows`
        - **Windows Event Tracing**: `label.platform = windows`
   4. (Optional) Enter a **Suffix** for the collection rule. AxoConsole adds the suffix to the name of the collector instances that it creates on the edge hosts. For example, if the name of a matching edge host is `edge-host-1`, and the suffix of the rule is `otel-file-collector`, the name of the collector on that host is `edge-host-1-otel-file-collector`.

      If the **Suffix** field is empty, AxoConsole uses the name of the collection rule instead.
   5. (Optional) Enter a description for the rule.
4. Configure the options specific to the collector type. For details, see the specific pages:

   - [File Collector](https://axoflow.com/docs/axoflow/0.90/data-sources/collection-rules/file-collector/index.md)
     (OpenTelemetry)
   - [Journald Collector](https://axoflow.com/docs/axoflow/0.90/data-sources/collection-rules/journald/index.md)
     (OpenTelemetry)
   - [Windows Event Log](https://axoflow.com/docs/axoflow/0.90/data-sources/collection-rules/windows-event-log/index.md)
   - [Windows Event Tracing (ETW)](https://axoflow.com/docs/axoflow/0.90/data-sources/collection-rules/windows-event-tracing/index.md)
5. Select **Add**. Based on the collection rule, Axoflow automatically creates collectors on the edge hosts that match the **Edge selector**.

   **CAUTION:**

   Make sure to configure [data forwarding rules](https://axoflow.com/docs/axoflow/0.90/data-sources/data-forwarding/index.md) for your edge hosts to transfer the collected data to the OpenTelemetry connector of an AxoRouter.

## Modify collection rule

To modify an existing collection rule, complete the following steps.

> **Note:**
>
> - You cannot directly modify the collector of an edge host, only via modifying a collection rule.
> - Modifying a collection rule affects every edge host that matches the **Edge selector** of the rule.
> - To apply an existing collection rule to a new edge host, you can:
>   - [Add a label to the edge host](https://axoflow.com/docs/axoflow/0.90/onboard-hosts/hosts/add-host-metadata/index.md)
>     so the **Edge selector** of the collection rule matches the new host, and/or
>   - Change the **Edge selector** of the collection rule to match the new host.

1. Find the collection rule you want to modify:

   - Select **Sources > Collection Rules** from the main menu, then select more_vert
     > **Edit** on the card of the collection rule you want to modify.
   - Alternatively, find the edge host whose collector you want to modify on the **Topology** page, then select **Connectors**. Find the collector you want to modify, then select more_vert
     > **Edit connector rule**.
2. Modify the configuration of the collection rule as needed.

   **CAUTION:**

   The changes are applied immediately after you click **Update**. Double-check your changes to avoid losing data.
3. Select **Update**.

## Add edge host to existing collection rule

To add an edge host to an existing collection rule, you have two options, depending on the **Edge selector** of the collection rule:

- [Modify the **Edge selector** field](https://axoflow.com/docs/axoflow/0.90/data-sources/collection-rules/index.md#modify-collection-rule)
  of the collection rule to include the new edge host.
- [Modify the labels](https://axoflow.com/docs/axoflow/0.90/onboard-hosts/hosts/add-host-metadata/index.md)
  of the edge host so it matches the edge selector of the collection rule.

---

[File Collector](https://axoflow.com/docs/axoflow/0.90/data-sources/collection-rules/file-collector/index.md)

Collect log files from Linux and Windows edge hosts, and look up the labels, metrics, and advanced options of the File Collector.

[Journald Collector](https://axoflow.com/docs/axoflow/0.90/data-sources/collection-rules/journald/index.md)

Collect systemd journal entries from Linux edge hosts, and look up the labels, metrics, and advanced options of the Journald Collector.

[Windows Event Log](https://axoflow.com/docs/axoflow/0.90/data-sources/collection-rules/windows-event-log/index.md)

Collect Windows Event Log channels from Windows edge hosts, and look up the labels, metrics, and advanced options of the collector.

[Windows Event Tracing](https://axoflow.com/docs/axoflow/0.90/data-sources/collection-rules/windows-event-tracing/index.md)

Collect Event Tracing for Windows (ETW) events from Windows edge hosts, and look up the labels, metrics, and advanced options.
