by Steele on Mon Aug 15, 2005 8:47 am
The system is running a Fedora Core 3.
What i had to do to get it to work was changing the directory for the mysql-client libraries from /usr/local/lib/mysql to /usr/lib/mysql.
Here is the info from the compiling and installing:
[root@scrooge linux]# pwd
/tmp/rsyslog-0.9.6/linux
[root@scrooge linux]# make
cc -O3 -DSYSV -fomit-frame-pointer -Wall -fno-strength-reduce -I/usr/local/include -DWITHDB -DSYSLOG_INET -DSYSLOG_UNIXAF -DFSSTND -DSYSLOGD_PIDNAME=\"rsyslogd.pid\" -c ../syslogd.c
cc -O3 -DSYSV -fomit-frame-pointer -Wall -fno-strength-reduce -I/usr/local/include -DWITHDB -c ../pidfile.c
cc -O3 -DSYSV -fomit-frame-pointer -Wall -fno-strength-reduce -I/usr/local/include -DWITHDB -c ../template.c
cc -O3 -DSYSV -fomit-frame-pointer -Wall -fno-strength-reduce -I/usr/local/include -DWITHDB -c ../stringbuf.c
cc -O3 -DSYSV -fomit-frame-pointer -Wall -fno-strength-reduce -I/usr/local/include -DWITHDB -c ../srUtils.c
cc -O3 -DSYSV -fomit-frame-pointer -Wall -fno-strength-reduce -I/usr/local/include -DWITHDB -c ../outchannel.c
cc -s -o syslogd syslogd.o pidfile.o template.o outchannel.o stringbuf.o srUtils.o -lmysqlclient -L/usr/lib/mysql
[root@scrooge linux]# make install
install ../rsyslogd.8 /usr/share/man/man8/rsyslogd.8
install ../rsyslog.conf.5 /usr/share/man/man5/rsyslog.conf.5
install -b -s syslogd /usr/sbin/rsyslogd
[root@scrooge linux]#
And This is the info from startup(ive anonymized the db-info):
[root@scrooge ~]# rsyslogd -r -m0 -d
Allocated parts table for 1024 file descriptors.
Starting.
Called init.
cfsysline --> template TraditionalFormat,"%timegenerated% %HOSTNAME% %syslogtag%%msg:::drop-last-lf%\n"
cfsysline --> template precise,"%syslogpriority%,%syslogfacility%,%timegenerated:::fulltime%,%HOSTNAME%,%syslogtag%,%msg%\n"
Invalid field option 'fulltime' specified - ignored.
cfsysline --> template RFC3164fmt,"<%PRI%>%TIMESTAMP% %HOSTNAME% %syslogtag%%msg%"
cfsysline --> template wallmsg,"\r\n\7Message from syslogd@%HOSTNAME% at %timegenerated% ...\r\n %syslogtag%%msg%\n\r"
cfsysline --> template WinSyslogFmt,"%HOSTNAME%,%timegenerated:1:10:date-rfc3339%,%timegenerated:12:19:date-rfc3339%,%timegenerated:1:10:date-rfc3339%,%timegenerated:12:19:date-rfc3339%,%syslogfacility%,%syslogpriority%,%syslogtag%%msg%\n"
cfsysline --> template dbFormat,"insert into SystemEvents (Message, Facility,FromHost, Priority, DeviceReportedTime, ReceivedAt, InfoUnitID, SysLogTag) values ('%msg%', %syslogfacility%, '%HOSTNAME%',%syslogpriority%, '%timereported:::date-mysql%', '%timegenerated:::date-mysql%', %iut%, '%syslogtag%')",sql
cfline(*.* /var/log/winsyslog-like.log;WinSyslogFmt)
symbolic name: * ==> 255
leading char in action: /
filename: '/var/log/winsyslog-like.log', template: 'WinSyslogFmt'
cfline(*.* /var/log/traditionalfile.log;TraditionalFormat)
symbolic name: * ==> 255
leading char in action: /
filename: '/var/log/traditionalfile.log', template: 'TraditionalFormat'
cfline(*.* /var/log/anothertraditionalfile.log)
symbolic name: * ==> 255
leading char in action: /
filename: '/var/log/anothertraditionalfile.log', template: ' TradFmt'
cfline(*.* >scrooge.allianse.no,syslog,syslogger,syslog)
symbolic name: * ==> 255
leading char in action: >
users: >scrooge.allianse.no,syslog,syslogger,syslog
Opened UNIX socket `/dev/log'.
Opened syslog UDP port.
FF FF FF FF FF FF FF FF FF FF FF FF FF FF FF FF FF FF FF FF FF FF FF FF FF FILE: /var/log/winsyslog-like.log
FF FF FF FF FF FF FF FF FF FF FF FF FF FF FF FF FF FF FF FF FF FF FF FF FF FILE: /var/log/traditionalfile.log
FF FF FF FF FF FF FF FF FF FF FF FF FF FF FF FF FF FF FF FF FF FF FF FF FF FILE: /var/log/anothertraditionalfile.log
FF FF FF FF FF FF FF FF FF FF FF FF FF FF FF FF FF FF FF FF FF FF FF FF FF USERS: >hostname, dbname, username, passwd,
Template: Name=' TradFmt'
Entry(9dfe058): type 2, (FIELD), value: 'TIMESTAMP'
Entry(9dfe130): type 1, (CONSTANT), value: ' '
Entry(9dfe158): type 2, (FIELD), value: 'HOSTNAME'
Entry(9dfe230): type 1, (CONSTANT), value: ' '
Entry(9dfe258): type 2, (FIELD), value: 'syslogtag'
Entry(9dfe308): type 2, (FIELD), value: 'msg' [drop last LF in msg]
Entry(9dfe3e0): type 1, (CONSTANT), value: '
'
Template: Name=' WallFmt'
Entry(9dfe460): type 1, (CONSTANT), value: '
Message from syslogd@'
Entry(9dfe488): type 2, (FIELD), value: 'HOSTNAME'
Entry(9dfe560): type 1, (CONSTANT), value: ' at '
Entry(9dfe588): type 2, (FIELD), value: 'timegenerated'
Entry(9dfe660): type 1, (CONSTANT), value: ' ...
'
Entry(9dfe688): type 2, (FIELD), value: 'syslogtag'
Entry(9dfe738): type 2, (FIELD), value: 'msg'
Entry(9dfe810): type 1, (CONSTANT), value: '
'
Template: Name=' StdFwdFmt'
Entry(9dfe890): type 1, (CONSTANT), value: '<'
Entry(9dfe8b8): type 2, (FIELD), value: 'PRI'
Entry(9dfe990): type 1, (CONSTANT), value: '>'
Entry(9dfe9b8): type 2, (FIELD), value: 'TIMESTAMP'
Entry(9dfea90): type 1, (CONSTANT), value: ' '
Entry(9dfeab8): type 2, (FIELD), value: 'HOSTNAME'
Entry(9dfeb90): type 1, (CONSTANT), value: ' '
Entry(9dfebb8): type 2, (FIELD), value: 'syslogtag'
Entry(9dfec68): type 2, (FIELD), value: 'msg'
Template: Name=' StdUsrMsgFmt'
Entry(9dfed78): type 1, (CONSTANT), value: ' '
Entry(9dfeda0): type 2, (FIELD), value: 'syslogtag'
Entry(9dfee50): type 2, (FIELD), value: 'msg'
Entry(9dfef28): type 1, (CONSTANT), value: '
'
Template: Name=' StdDBFmt' [SQL-Format]
Entry(9dfef80): type 1, (CONSTANT), value: 'insert into SystemEvents (Message, Facility, FromHost, Priority, DeviceReportedTime, ReceivedAt, InfoUnitID, SysLogTag) values (''
Entry(9dfeff0): type 2, (FIELD), value: 'msg'
Entry(9dff188): type 1, (CONSTANT), value: '', '
Entry(9dff1b0): type 2, (FIELD), value: 'syslogfacility'
Entry(9dff288): type 1, (CONSTANT), value: ', ''
Entry(9dff2b0): type 2, (FIELD), value: 'HOSTNAME'
Entry(9dff388): type 1, (CONSTANT), value: '', '
Entry(9dff3b0): type 2, (FIELD), value: 'syslogpriority'
Entry(9dff488): type 1, (CONSTANT), value: ', ''
Entry(9dff4b0): type 2, (FIELD), value: 'timereported' [Format as MySQL-Date]
Entry(9dff588): type 1, (CONSTANT), value: '', ''
Entry(9dff5b0): type 2, (FIELD), value: 'timegenerated' [Format as MySQL-Date]
Entry(9dff688): type 1, (CONSTANT), value: '', '
Entry(9dff6b0): type 2, (FIELD), value: 'iut'
Entry(9dff788): type 1, (CONSTANT), value: ', ''
Entry(9dff7b0): type 2, (FIELD), value: 'syslogtag'
Entry(9dff888): type 1, (CONSTANT), value: '')'
Template: Name='TraditionalFormat'
Entry(9e00e88): type 2, (FIELD), value: 'timegenerated'
Entry(9e017a0): type 1, (CONSTANT), value: ' '
Entry(9e017c8): type 2, (FIELD), value: 'HOSTNAME'
Entry(9e018a0): type 1, (CONSTANT), value: ' '
Entry(9e018c8): type 2, (FIELD), value: 'syslogtag'
Entry(9e01978): type 2, (FIELD), value: 'msg' [drop last LF in msg]
Entry(9e01a50): type 1, (CONSTANT), value: '
'
Template: Name='precise'
Entry(9e01a98): type 2, (FIELD), value: 'syslogpriority'
Entry(9e01b70): type 1, (CONSTANT), value: ','
Entry(9e01b98): type 2, (FIELD), value: 'syslogfacility'
Entry(9e01c70): type 1, (CONSTANT), value: ','
Entry(9e01c98): type 2, (FIELD), value: 'timegenerated'
Entry(9e01d70): type 1, (CONSTANT), value: ','
Entry(9e01d98): type 2, (FIELD), value: 'HOSTNAME'
Entry(9e01e70): type 1, (CONSTANT), value: ','
Entry(9e01e98): type 2, (FIELD), value: 'syslogtag'
Entry(9e01f70): type 1, (CONSTANT), value: ','
Entry(9e01f98): type 2, (FIELD), value: 'msg'
Entry(9e02070): type 1, (CONSTANT), value: '
'
Template: Name='RFC3164fmt'
Entry(9e020f0): type 1, (CONSTANT), value: '<'
Entry(9e02118): type 2, (FIELD), value: 'PRI'
Entry(9e021f0): type 1, (CONSTANT), value: '>'
Entry(9e02218): type 2, (FIELD), value: 'TIMESTAMP'
Entry(9e022f0): type 1, (CONSTANT), value: ' '
Entry(9e02318): type 2, (FIELD), value: 'HOSTNAME'
Entry(9e023f0): type 1, (CONSTANT), value: ' '
Entry(9e02418): type 2, (FIELD), value: 'syslogtag'
Entry(9e024c8): type 2, (FIELD), value: 'msg'
Template: Name='wallmsg'
Entry(9e025d0): type 1, (CONSTANT), value: '
Message from syslogd@'
Entry(9e025f8): type 2, (FIELD), value: 'HOSTNAME'
Entry(9e026d0): type 1, (CONSTANT), value: ' at '
Entry(9e026f8): type 2, (FIELD), value: 'timegenerated'
Entry(9e027d0): type 1, (CONSTANT), value: ' ...
'
Entry(9e027f8): type 2, (FIELD), value: 'syslogtag'
Entry(9e028a8): type 2, (FIELD), value: 'msg'
Entry(9e02980): type 1, (CONSTANT), value: '
'
Template: Name='WinSyslogFmt'
Entry(9e029e0): type 2, (FIELD), value: 'HOSTNAME'
Entry(9e02ab8): type 1, (CONSTANT), value: ','
Entry(9e02ae0): type 2, (FIELD), value: 'timegenerated' [Format as RFC3339-Date] [substring, from character 1 to 10]
Entry(9e02bb8): type 1, (CONSTANT), value: ','
Entry(9e02be0): type 2, (FIELD), value: 'timegenerated' [Format as RFC3339-Date] [substring, from character 12 to 19]
Entry(9e02cb8): type 1, (CONSTANT), value: ','
Entry(9e02ce0): type 2, (FIELD), value: 'timegenerated' [Format as RFC3339-Date] [substring, from character 1 to 10]
Entry(9e02db8): type 1, (CONSTANT), value: ','
Entry(9e02de0): type 2, (FIELD), value: 'timegenerated' [Format as RFC3339-Date] [substring, from character 12 to 19]
Entry(9e02eb8): type 1, (CONSTANT), value: ','
Entry(9e02ee0): type 2, (FIELD), value: 'syslogfacility'
Entry(9e02fb8): type 1, (CONSTANT), value: ','
Entry(9e02fe0): type 2, (FIELD), value: 'syslogpriority'
Entry(9e030b8): type 1, (CONSTANT), value: ','
Entry(9e030e0): type 2, (FIELD), value: 'syslogtag'
Entry(9e03190): type 2, (FIELD), value: 'msg'
Entry(9e03268): type 1, (CONSTANT), value: '
'
Template: Name='dbFormat' [SQL-Format]
Entry(9e032c0): type 1, (CONSTANT), value: 'insert into SystemEvents (Message, Facility,FromHost, Priority, DeviceReportedTime, ReceivedAt, InfoUnitID, SysLogTag) values (''
Entry(9e03330): type 2, (FIELD), value: 'msg'
Entry(9e034c8): type 1, (CONSTANT), value: '', '
Entry(9e034f0): type 2, (FIELD), value: 'syslogfacility'
Entry(9e035c8): type 1, (CONSTANT), value: ', ''
Entry(9e035f0): type 2, (FIELD), value: 'HOSTNAME'
Entry(9e036c8): type 1, (CONSTANT), value: '','
Entry(9e036f0): type 2, (FIELD), value: 'syslogpriority'
Entry(9e037c8): type 1, (CONSTANT), value: ', ''
Entry(9e037f0): type 2, (FIELD), value: 'timereported' [Format as MySQL-Date]
Entry(9e038c8): type 1, (CONSTANT), value: '', ''
Entry(9e038f0): type 2, (FIELD), value: 'timegenerated' [Format as MySQL-Date]
Entry(9e039c8): type 1, (CONSTANT), value: '', '
Entry(9e039f0): type 2, (FIELD), value: 'iut'
Entry(9e03ac8): type 1, (CONSTANT), value: ', ''
Entry(9e03af0): type 2, (FIELD), value: 'syslogtag'
Entry(9e03bc8): type 1, (CONSTANT), value: '')'
logmsg: syslog.info<46>, flags 4, from scrooge, msg rsyslogd: [origin software="rsyslogd" swVersion="0.9.6"] restart (remote reception).
Called fprintlog, logging to FILE
Called fprintlog, logging to FILE
Called fprintlog, logging to FILE
Called fprintlog, logging to USERS
rsyslogd: restarted.