0
answers

Hi,

I'm testing out the nxlog-ce-2.10.2150 and am trying to do simple exclusion of log files, as explained should be possible here: https://nxlog.co/documentation/nxlog-user-guide-full#im_file_config_exclude

However, no matter how I try, I get this:

2019-01-09 13:31:19 ERROR invalid keyword: Exclude at /etc/nxlog/nxlog.conf:109

Is this something that simply is not included in the community edition or what gives?

Thanks for any help,

Mika

AskedJanuary 9, 2019 - 12:41pm

Comments (4)

  • camharris's picture
    (NXLog)

    This feature is included in the community edition. Could you please provide a configuration sample of your im_file module?

    January 9, 2019 - 1:26pm
  • Mika Aleksandroff's picture

    Ok, very simple sample:

    $ cat /tmp/testi.conf
    <Input syslogs>
    Module im_file
    Recursive FALSE
    File "/var/log/*.log"
    Exclude "btmp"
    Exclude "/var/log/alternatives*"
    </Input>

    $ sudo nxlog-processor -c /tmp/testi.conf
    2019-01-09 15:21:28 ERROR invalid keyword: Exclude at /tmp/testi.conf:6
    2019-01-09 15:21:28 WARNING no routes defined!
    2019-01-09 15:21:28 WARNING not starting unused module syslogs

    Same same with actual nxlog and full config.

    And also, similar weird problem with File directive. Manual says "This mandatory directive specifies the name of the input file to open. It may be given more than once in a single im_file module instance." but:

    $ cat /tmp/testi.conf
    <Input syslogs>
    Module im_file
    Recursive FALSE
    File "/var/log/*.log"
    File "/var/log/syslog"
    File "/var/log/kern.log"
    Exclude "btmp"
    Exclude "/var/log/alternatives*"
    </Input>

    securi@worker02:~$ sudo nxlog-processor -c /tmp/testi.conf
    2019-01-09 15:25:56 ERROR file is already defined at /tmp/testi.conf:5

    There MUST be some stupidly simple user error I'm having... :-D

    January 9, 2019 - 2:27pm
  • Mika Aleksandroff's picture

    Ah, yes, stupid user it was. :-)

    Thank you!

    January 9, 2019 - 3:17pm

Answers (0)