# statefile

Specifies the absolute path to the JSON file where omsendertrack persists sender statistics.

This parameter applies to omsendertrack: Sender Tracking Output Module.

Name:

  statefile

Scope:

  input

Type:

  string

Default:

  input=none

Required?:

  yes

Introduced:

  8.2506.0 (Proof-of-Concept)

## Description

This mandatory parameter specifies the absolute path to the JSON file where sender information is stored. The module updates this file periodically based on the configured interval and also upon rsyslog shutdown to preserve the latest statistics.

Important: Ensure that the rsyslog user has appropriate write permissions to the directory where this `statefile` is located. Failure to do so will prevent the module from saving its state.

## Input usage

    module(load="omsendertrack")
    action(type="omsendertrack"
           senderId="%hostname%"
           stateFile="/var/lib/rsyslog/senderstats.json")

## See also

See also omsendertrack: Sender Tracking Output Module.

Support: rsyslog Assistant | GitHub Discussions | GitHub Issues: rsyslog source project

Contributing: Source & docs: rsyslog source project

© 2008–2025 Rainer Gerhards and others. Licensed under the Apache License 2.0.