[syslog-ng] checking configuration file syntax

Fegan, Joe Joe.Fegan at hp.com
Wed Dec 10 11:39:09 CET 2008


I use the following syntax successfully on 2.0.7:

# syslog-ng --syntax-only --cfgfile=file-to-check

It returns exit code 0 if everything is ok, something else otherwise.

-----Original Message-----
From: syslog-ng-bounces at lists.balabit.hu [mailto:syslog-ng-bounces at lists.balabit.hu] On Behalf Of Pavel Shaydo
Sent: 10 December 2008 10:16
To: syslog-ng
Subject: [syslog-ng] checking configuration file syntax

Hello all!

I'm trying to automate configuration file syntax checking and can't
figure out how I can do it. According to manual -s option should perform
syntax checking. I'm trying following:

syslog-ng -s -f file-to-check

It always exits with zero status and never outputs anything, regardless
of correct configuration file or it contains errors. Is there something
I missed? I tested it on 2.0.9 and on premium edition 2.1.11a.


--
Best regards,
Pavel Shaydo

______________________________________________________________________________
Member info: https://lists.balabit.hu/mailman/listinfo/syslog-ng
Documentation: http://www.balabit.com/support/documentation/?product=syslog-ng
FAQ: http://www.campin.net/syslog-ng/faq.html



More information about the syslog-ng mailing list