Skip to content

#248 (base: rainerscript replacement for $IncludeConfig) incorrectly assumes that include directive is supported #250

@bschonec

Description

@bschonec

Affected Puppet, Ruby, OS and module versions/distributions

  • Puppet: puppet-agent-7.33.0-1.el7.x86_64
  • Distribution: Red Hat Enterprise Linux Server release 7.9 (Maipo)
  • Module version: Commit 40440a8

What are you seeing

The module incorrectly assumes that the include() object is supported on rsyslog without first checking (or providing an override) for an appropriate version of rsyslog.

What behaviour did you expect instead

This module uses the new syntax of include() instead of the older $IncludeConfig. The include() syntax is supported only on rsyslog > 8.33.0.

Output log

syslogd[39175]: action 'include' treated as ':omusrmsg:include' - please use ':omusrmsg:include' syntax instead, 'include' will not be supported in the future [v8.24.0-57.el7_9.3 try http://www.rsyslog.com/e/2184 ]
syslogd[39175]: error during parsing file /etc/rsyslog.conf, on or before line 5: warnings occured in file '/etc/rsyslog.conf' around line 5 [v8.24.0-57.el7_9.3 try http://www.rsyslog.com/e/2207 ]
syslogd[39175]: error during parsing file /etc/rsyslog.conf, on or before line 5: invalid character '(' - is there an invalid escape sequence somewhere? [v8.24.0-57.el7_9.3 try http://www.rsyslog.com/e/2207 ]
syslogd[39175]: action 'file' treated as ':omusrmsg:file' - please use ':omusrmsg:file' syntax instead, 'file' will not be supported in the future [v8.24.0-57.el7_9.3 try http://www.rsyslog.com/e/2184 ]
syslogd[39175]: error during parsing file /etc/rsyslog.conf, on or before line 5: warnings occured in file '/etc/rsyslog.conf' around line 5 [v8.24.0-57.el7_9.3 try http://www.rsyslog.com/e/2207 ]
syslogd[39175]: error during parsing file /etc/rsyslog.conf, on or before line 5: invalid character '=' - is there an invalid escape sequence somewhere? [v8.24.0-57.el7_9.3 try http://www.rsyslog.com/e/2207 ]
syslogd[39175]: error during parsing file /etc/rsyslog.conf, on or before line 5: invalid character '"' - is there an invalid escape sequence somewhere? [v8.24.0-57.el7_9.3 try http://www.rsyslog.com/e/2207 ]
syslogd[39175]: invalid character in selector line - ';template' expected [v8.24.0-57.el7_9.3]
syslogd[39175]: error during parsing file /etc/rsyslog.conf, on or before line 5: errors occured in file '/etc/rsyslog.conf' around line 5 [v8.24.0-57.el7_9.3 try http://www.rsyslog.com/e/2207 ]

Any additional information you'd like to impart

The module should do one of the following:

  1. check for the version of rsyslog RPM that's currently installed
  2. provide a way to override the (current) default syntax of include().
  3. leverage hiera data to grab the major os version of the operating system and apply appropriate "include" directives.

The latest version of rsyslog available for RHEL7 is rsyslog-8.24.0-57.el7_9.3.x86_64.rpm.

@m8t

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't working

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions