fileCreateMode

Specifies the file system permissions for newly created log files.

This parameter applies to omfile: File Output Module.

Name:

fileCreateMode

Scope:

module, action

Type:

string (octal)

Default:

module=0644; action=inherits module

Required?:

no

Introduced:

at least 5.x, possibly earlier

Description

Specifies the file system permissions for log files newly created by omfile. The value must be a 4-digit octal number (e.g., 0640).

When set at the module level, it defines the default mode for all omfile actions. When set at the action level, it overrides the module default for that specific action.

Please note that the actual permissions depend on rsyslogd’s process umask. If in doubt, use $umask 0000 at the beginning of the configuration file to remove any restrictions.

Module usage

module(load="builtin:omfile" fileCreateMode="0644")

Action usage

action(type="omfile" fileCreateMode="...")

Legacy names (for reference)

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

  • $FileCreateMode — maps to fileCreateMode (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–2025 Rainer Gerhards and others. Licensed under the Apache License 2.0.