asyncWriting

If turned on, the files will be written in asynchronous mode via a separate thread.

This parameter applies to omfile: File Output Module.

Name:

asyncWriting

Scope:

action

Type:

boolean

Default:

action=off

Required?:

no

Introduced:

at least 5.x, possibly earlier

Description

If turned on, the files will be written in asynchronous mode via a separate thread. In that case, double buffers will be used so that one buffer can be filled while the other buffer is being written.

The flushInterval setting is applied when asyncWriting is enabled for the action. Set asyncWriting="on" when using flushInterval to bound how long buffered data may remain unflushed.

Action usage

action(type="omfile" file="/var/log/app.log" asyncWriting="on")

YAML usage

actions:
  - type: omfile
    file: /var/log/app.log
    asyncWriting: "on"

Notes

  • Legacy documentation referred to the type as binary; this maps to boolean.

Legacy names (for reference)

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

  • $OMFileASyncWriting — maps to asyncWriting (status: legacy)

See also

See also omfile: File Output Module.


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

Contributing: Source & docs: rsyslog source project

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