On 11/20/2018 10:23 AM, Mike Schleif wrote:
On Tue, Nov 20, 2018 at 9:53 AM Jacob Steinberger via rsyslog <
[email protected]> wrote:
Try this in your config:
$template tpltext, "insert into SystemEvents (Message, Facility, FromHost,
Priority, DeviceReportedTime, ReceivedAt, InfoUnitID, SysLogTag) values
('%msg%', %syslogfacility%, '%HOSTNAME%',
%syslogpriority%,'%timereported:::date-mysql%',
'%timegenerated:::date-mysql%', %iut%,
'%syslogtag%')"
module(load="builtin:omfile" file="/var/log/rsyslog-debug.log"
template="tpltext")
What am I missing now?
What I'm giving may not be 100%, it may require you to do some work for
syntax checking. I'm basically working off memory and quick google searches.
https://www.rsyslog.com/doc/v8-stable/configuration/modules/omfile.html
138:$template tpltext, "insert into SystemEvents (Message, Facility,
FromHost, Priority, DeviceReportedTime, ReceivedAt, InfoUnitID, SysLogTag)
values ('%msg%', %syslogfacility%, '%HOSTNAME%',
%syslogpriority%,'%timereported:::date-mysql%',
'%timegenerated:::date-mysql%', %iut%, '%syslogtag%')"
139:module(load="builtin:omfile" file="/var/log/rsyslog-debug.log"
template="tpltext")
Technically the documentation says file should be "File", you could give
that a try.
Are you running Rsyslog 8.39?
_______________________________________________
rsyslog mailing list
http://lists.adiscon.net/mailman/listinfo/rsyslog
http://www.rsyslog.com/professional-services/
What's up with rsyslog? Follow https://twitter.com/rgerhards
NOTE WELL: This is a PUBLIC mailing list, posts are ARCHIVED by a myriad of
sites beyond our control. PLEASE UNSUBSCRIBE and DO NOT POST if you DON'T LIKE
THAT.