# ServerInputName

Overrides the `inputname` property for the diagnostic TCP listener’s own log messages.

This parameter applies to imdiag: Diagnostic instrumentation.

Name:

  ServerInputName

Scope:

  input

Type:

  string

Default:

  input=imdiag

Required?:

  no

Introduced:

  at least 5.x, possibly earlier

## Description

Sets the `inputname` metadata assigned to log messages originating from the imdiag TCP listener itself (for example, connection warnings). This does not affect the `inputname` of messages injected via the control channel, which always remains `imdiag`. This parameter must be configured before using ServerRun. This ensures the listener logs use the desired identifier from startup onward.

## Input usage

    module(load="imdiag")
    input(type="imdiag"
          listenPortFileName="/var/run/rsyslog/imdiag.port"
          serverInputName="diag-main"
          serverRun="19998")

### Legacy names (for reference)

Historic names/directives for compatibility. Do not use in new configs.

- $IMDiagServerInputName — maps to ServerInputName (status: legacy)

## See also

See also imdiag: Diagnostic instrumentation.

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.