NXLog Community edition not finding modules

Tags:

#1 cmarsura
NXLog Community edition not finding modules Hello, I am getting an error loading modules with a trivial configuration. The nxlog.conf configuration file: ``` # ############ BEGIN nxlog.conf Panic Soft #NoFreeOnExit TRUE define ROOT C:\Program Files\nxlog #define CERTDIR %ROOT%\cert #define CONFDIR %ROOT%\conf\nxlog.d define LOGDIR %ROOT%\data define LOGFILE %LOGDIR%\nxlog.log LogFile %LOGFILE% Module im_null # Module im_file #  Module om_tcp #  Module om_file   Module om_null # Connect input 'in' to output 'out' Path in => out # ############ END nxlog.conf ``` The error: ``` 2022-03-22 15:05:24 ERROR Module missing at c:\Program Files\nxlog\conf\nxlog.conf:21 2022-03-22 15:05:24 ERROR module 'out' is not declared at c:\Program Files\nxlog\conf\nxlog.conf:27 2022-03-22 15:05:24 ERROR route DefaultRoute is not functional without output modules, ignored at c:\Program Files\nxlog\conf\nxlog.conf:27 2022-03-22 15:05:24 WARNING no routes defined! 2022-03-22 15:05:24 WARNING not starting unused module in ``` If I try to load more modules with following configuration, things gets more worse: ``` # ############ BEGIN nxlog.conf Panic Soft #NoFreeOnExit TRUE define ROOT C:\Program Files\nxlog #define CERTDIR %ROOT%\cert #define CONFDIR %ROOT%\conf\nxlog.d define LOGDIR %ROOT%\data define LOGFILE %LOGDIR%\nxlog.log LogFile %LOGFILE% #Moduledir %ROOT%\modules #CacheDir %ROOT%\data #Pidfile %ROOT%\data\nxlog.pid #SpoolDir %ROOT%\data # Following processors give error "...ERROR Module missing at ..."   Module pm_buffer   Module pm_evcorr   Module pm_norepeat   Module pm_null   Module pm_pattern>   Module pm_transformer> # Following inputs give error "...ERROR Module missing at ..."   exec im_exec   Module im_module   file im_file   internal im_internal   kernel im_kernel # Following outputs give error "...ERROR Module missing at ..."   Module om_exec   Module om_file   Module om_http   Module om_null   Module om_ssl   Module om_tcp   Module om_udp Module im_null # Module im_file #  Module om_tcp #  Module om_file   Module om_null # Connect input 'in' to output 'out' Path in => out # ############ END nxlog.conf ``` The errors: ``` 2022-03-22 15:07:55 ERROR Module missing at c:\Program Files\nxlog\conf\nxlog.conf:21 2022-03-22 15:07:55 ERROR Module missing at c:\Program Files\nxlog\conf\nxlog.conf:24 2022-03-22 15:07:55 ERROR Module missing at c:\Program Files\nxlog\conf\nxlog.conf:27 2022-03-22 15:07:55 ERROR Module missing at c:\Program Files\nxlog\conf\nxlog.conf:30 2022-03-22 15:07:55 ERROR Module missing at c:\Program Files\nxlog\conf\nxlog.conf:33 2022-03-22 15:07:55 ERROR Module missing at c:\Program Files\nxlog\conf\nxlog.conf:36 2022-03-22 15:07:55 ERROR Module missing at c:\Program Files\nxlog\conf\nxlog.conf:42 2022-03-22 15:07:55 ERROR Module missing at c:\Program Files\nxlog\conf\nxlog.conf:45 2022-03-22 15:07:55 ERROR Module missing at c:\Program Files\nxlog\conf\nxlog.conf:48 2022-03-22 15:07:55 ERROR Module missing at c:\Program Files\nxlog\conf\nxlog.conf:51 2022-03-22 15:07:55 ERROR Module missing at c:\Program Files\nxlog\conf\nxlog.conf:54 2022-03-22 15:07:55 ERROR Module missing at c:\Program Files\nxlog\conf\nxlog.conf:59 2022-03-22 15:07:55 ERROR Module missing at c:\Program Files\nxlog\conf\nxlog.conf:62 2022-03-22 15:07:55 ERROR Module missing at c:\Program Files\nxlog\conf\nxlog.conf:65 2022-03-22 15:07:55 ERROR Module missing at c:\Program Files\nxlog\conf\nxlog.conf:68 2022-03-22 15:07:55 ERROR Module missing at c:\Program Files\nxlog\conf\nxlog.conf:71 2022-03-22 15:07:55 ERROR Module missing at c:\Program Files\nxlog\conf\nxlog.conf:74 2022-03-22 15:07:55 ERROR Module missing at c:\Program Files\nxlog\conf\nxlog.conf:77 2022-03-22 15:07:55 ERROR Module missing at c:\Program Files\nxlog\conf\nxlog.conf:87 2022-03-22 15:07:55 ERROR module 'out' is not declared at c:\Program Files\nxlog\conf\nxlog.conf:93 2022-03-22 15:07:55 ERROR route DefaultRoute is not functional without output modules, ignored at c:\Program Files\nxlog\conf\nxlog.conf:93 2022-03-22 15:07:55 WARNING no routes defined! 2022-03-22 15:07:55 WARNING not starting unused module in ``` I get same errors on two 64 bit machines (Windows 10 and Windows Server 2012R2) Tried with **processmonitor.exe** to see if **nxlog-processor.exe** fail to load the dll module but I do not see any load attempt. I suspect that I must missing a macroscopic thing but am unable to spot it. Using nxlog-ce-3.0.2272.msi Community Edition for Windows 64 bit. Any hint will be appreciated. Regards. Carlo
#2 cmarsura
#1 cmarsura
NXLog Community edition not finding modules Hello, I am getting an error loading modules with a trivial configuration. The nxlog.conf configuration file: ``` # ############ BEGIN nxlog.conf Panic Soft #NoFreeOnExit TRUE define ROOT C:\Program Files\nxlog #define CERTDIR %ROOT%\cert #define CONFDIR %ROOT%\conf\nxlog.d define LOGDIR %ROOT%\data define LOGFILE %LOGDIR%\nxlog.log LogFile %LOGFILE% Module im_null # Module im_file #  Module om_tcp #  Module om_file   Module om_null # Connect input 'in' to output 'out' Path in => out # ############ END nxlog.conf ``` The error: ``` 2022-03-22 15:05:24 ERROR Module missing at c:\Program Files\nxlog\conf\nxlog.conf:21 2022-03-22 15:05:24 ERROR module 'out' is not declared at c:\Program Files\nxlog\conf\nxlog.conf:27 2022-03-22 15:05:24 ERROR route DefaultRoute is not functional without output modules, ignored at c:\Program Files\nxlog\conf\nxlog.conf:27 2022-03-22 15:05:24 WARNING no routes defined! 2022-03-22 15:05:24 WARNING not starting unused module in ``` If I try to load more modules with following configuration, things gets more worse: ``` # ############ BEGIN nxlog.conf Panic Soft #NoFreeOnExit TRUE define ROOT C:\Program Files\nxlog #define CERTDIR %ROOT%\cert #define CONFDIR %ROOT%\conf\nxlog.d define LOGDIR %ROOT%\data define LOGFILE %LOGDIR%\nxlog.log LogFile %LOGFILE% #Moduledir %ROOT%\modules #CacheDir %ROOT%\data #Pidfile %ROOT%\data\nxlog.pid #SpoolDir %ROOT%\data # Following processors give error "...ERROR Module missing at ..."   Module pm_buffer   Module pm_evcorr   Module pm_norepeat   Module pm_null   Module pm_pattern>   Module pm_transformer> # Following inputs give error "...ERROR Module missing at ..."   exec im_exec   Module im_module   file im_file   internal im_internal   kernel im_kernel # Following outputs give error "...ERROR Module missing at ..."   Module om_exec   Module om_file   Module om_http   Module om_null   Module om_ssl   Module om_tcp   Module om_udp Module im_null # Module im_file #  Module om_tcp #  Module om_file   Module om_null # Connect input 'in' to output 'out' Path in => out # ############ END nxlog.conf ``` The errors: ``` 2022-03-22 15:07:55 ERROR Module missing at c:\Program Files\nxlog\conf\nxlog.conf:21 2022-03-22 15:07:55 ERROR Module missing at c:\Program Files\nxlog\conf\nxlog.conf:24 2022-03-22 15:07:55 ERROR Module missing at c:\Program Files\nxlog\conf\nxlog.conf:27 2022-03-22 15:07:55 ERROR Module missing at c:\Program Files\nxlog\conf\nxlog.conf:30 2022-03-22 15:07:55 ERROR Module missing at c:\Program Files\nxlog\conf\nxlog.conf:33 2022-03-22 15:07:55 ERROR Module missing at c:\Program Files\nxlog\conf\nxlog.conf:36 2022-03-22 15:07:55 ERROR Module missing at c:\Program Files\nxlog\conf\nxlog.conf:42 2022-03-22 15:07:55 ERROR Module missing at c:\Program Files\nxlog\conf\nxlog.conf:45 2022-03-22 15:07:55 ERROR Module missing at c:\Program Files\nxlog\conf\nxlog.conf:48 2022-03-22 15:07:55 ERROR Module missing at c:\Program Files\nxlog\conf\nxlog.conf:51 2022-03-22 15:07:55 ERROR Module missing at c:\Program Files\nxlog\conf\nxlog.conf:54 2022-03-22 15:07:55 ERROR Module missing at c:\Program Files\nxlog\conf\nxlog.conf:59 2022-03-22 15:07:55 ERROR Module missing at c:\Program Files\nxlog\conf\nxlog.conf:62 2022-03-22 15:07:55 ERROR Module missing at c:\Program Files\nxlog\conf\nxlog.conf:65 2022-03-22 15:07:55 ERROR Module missing at c:\Program Files\nxlog\conf\nxlog.conf:68 2022-03-22 15:07:55 ERROR Module missing at c:\Program Files\nxlog\conf\nxlog.conf:71 2022-03-22 15:07:55 ERROR Module missing at c:\Program Files\nxlog\conf\nxlog.conf:74 2022-03-22 15:07:55 ERROR Module missing at c:\Program Files\nxlog\conf\nxlog.conf:77 2022-03-22 15:07:55 ERROR Module missing at c:\Program Files\nxlog\conf\nxlog.conf:87 2022-03-22 15:07:55 ERROR module 'out' is not declared at c:\Program Files\nxlog\conf\nxlog.conf:93 2022-03-22 15:07:55 ERROR route DefaultRoute is not functional without output modules, ignored at c:\Program Files\nxlog\conf\nxlog.conf:93 2022-03-22 15:07:55 WARNING no routes defined! 2022-03-22 15:07:55 WARNING not starting unused module in ``` I get same errors on two 64 bit machines (Windows 10 and Windows Server 2012R2) Tried with **processmonitor.exe** to see if **nxlog-processor.exe** fail to load the dll module but I do not see any load attempt. I suspect that I must missing a macroscopic thing but am unable to spot it. Using nxlog-ce-3.0.2272.msi Community Edition for Windows 64 bit. Any hint will be appreciated. Regards. Carlo

Spotted the problem: while copying the code snippet from the pdf manual to the .conf file, I copied an invisible character (0xA0) present in the beginning of the 'module' directive. That character was cocking silently the NXLog parser. Duplicating that row to use it with other modules spreaded the error.

Fortunately, using the Notepad2 with 'Show Withespaces' enabled to edit the config file permitted me to find the character appearing as an innocently blank char.

Good luck. Carlo