<p dir="ltr">One culprit is that this snippet is coming from the builtin scl macros. Unfortunately we don&#39;t really handle this case nicely and there&#39;s even a bug about that.</p>
<p dir="ltr">The workaround is simply to remove the cim folder from /usr/share/syslog-ng/include/scl.</p>
<div class="gmail_quote">On Feb 23, 2016 6:17 PM, &quot;Czanik, Péter&quot; &lt;<a href="mailto:peter.czanik@balabit.com">peter.czanik@balabit.com</a>&gt; wrote:<br type="attribution"><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div dir="ltr"><div><div>Hi,<br></div><br>You don&#39;t have json support enabled, but have a config with format-json. Either compile syslog-ng with json support or remove this config snippet.<br></div><br>Bye,<br></div><div class="gmail_extra"><br clear="all"><div><div>Peter Czanik (CzP) &lt;<a href="mailto:peter.czanik@balabit.com" target="_blank">peter.czanik@balabit.com</a>&gt;<br>Balabit / syslog-ng upstream<br><a href="http://czanik.blogs.balabit.com/" target="_blank">http://czanik.blogs.balabit.com/</a><br><a href="https://twitter.com/PCzanik" target="_blank">https://twitter.com/PCzanik</a></div></div>
<br><div class="gmail_quote">On Tue, Feb 23, 2016 at 6:11 PM, amey jain <span dir="ltr">&lt;<a href="mailto:amey.jain7@gmail.com" target="_blank">amey.jain7@gmail.com</a>&gt;</span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div dir="ltr"><div><div>Hi,<br></div>I was running ./syslog-ng and I got these errors. I am unable to solve them. I am copying the output here. Please tell me what to do to correct it.<br>$ sbin/syslog-ng --module-path=/home/amey/install/syslog-ng<br>Error parsing config, Error compiling template (Unknown template function &quot;format-json&quot;) in /home/amey/install/syslog-ng/share/syslog-ng/include/scl/cim/template.conf at line 23, column 32:<br>                                                                              included from /home/amey/install/syslog-ng/etc/scl.conf line 29, column 1<br>                                                                              included from /home/amey/install/syslog-ng/etc/syslog-ng.conf line 8, column 1<br><br>template-function &quot;format-cim&quot; &quot;$(format-json --pair @timestamp=&#39;${R_ISODATE}&#39; --pair @message=&#39;${MSG}&#39; --key .cim.* --shift 5 --key _* --key .* --replace-prefix .=_ --key *.*)\n&quot;;<br>                               ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^<br><br>syslog-ng documentation: <a href="http://www.balabit.com/support/documentation/?product=syslog-ng" target="_blank">http://www.balabit.com/support/documentation/?product=syslog-ng</a><br>mailing list: <a href="https://lists.balabit.hu/mailman/listinfo/syslog-ng" target="_blank">https://lists.balabit.hu/mailman/listinfo/syslog-ng</a><br></div>Regards<br></div>
<br>______________________________________________________________________________<br>
Member info: <a href="https://lists.balabit.hu/mailman/listinfo/syslog-ng" rel="noreferrer" target="_blank">https://lists.balabit.hu/mailman/listinfo/syslog-ng</a><br>
Documentation: <a href="http://www.balabit.com/support/documentation/?product=syslog-ng" rel="noreferrer" target="_blank">http://www.balabit.com/support/documentation/?product=syslog-ng</a><br>
FAQ: <a href="http://www.balabit.com/wiki/syslog-ng-faq" rel="noreferrer" target="_blank">http://www.balabit.com/wiki/syslog-ng-faq</a><br>
<br>
<br></blockquote></div><br></div>
<br>______________________________________________________________________________<br>
Member info: <a href="https://lists.balabit.hu/mailman/listinfo/syslog-ng" rel="noreferrer" target="_blank">https://lists.balabit.hu/mailman/listinfo/syslog-ng</a><br>
Documentation: <a href="http://www.balabit.com/support/documentation/?product=syslog-ng" rel="noreferrer" target="_blank">http://www.balabit.com/support/documentation/?product=syslog-ng</a><br>
FAQ: <a href="http://www.balabit.com/wiki/syslog-ng-faq" rel="noreferrer" target="_blank">http://www.balabit.com/wiki/syslog-ng-faq</a><br>
<br>
<br></blockquote></div>