Thx .
I create another table and put data onto it using rsyslog Template , like below way :
==========================================================================================
cat /etc/rsyslog.conf
$ModLoad ommysql.so
$ModLoad imuxsock
$ModLoad ommysql
$ModLoad imtcp
$ModLoad imudp
if ($FromHost == '192.168.1.41' ) then
mmysql:127.0.0.1,Syslog,rsyslog,rsyslog; hotmpl
if ($FromHost == '192.168.0.87') then
mmysql:127.0.0.1,Syslog,rsyslog,rsyslog; hotmp2
#Templates
$template hotmp1,"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
$template hotmp2,"insert into windows (Message, Facility, FromHost, Priority, DeviceReportedTime, ReceivedAt, InfoUnitID, SysLogTag) values ('%msg%', %syslogfacility%, '%HOSTNAME%', %syslogpriority%, '%timereported:::date-mysql%', '%timegenerated:::date-mysql%', %iut%, '%syslogtag%')",SQL
================================================================
Now in this case , i get error on '/var/log/messages' :
-------Error-----------
Jun 15 18:13:35 oem rsyslogd:could not load module '/usr/lib64/rsyslog/imuxsock', dlopen: /usr/lib64/rsyslog/imuxsock: cannot open shared object file: No such file or directory
Jun 15 18:13:35 oem rsyslogd:the last error occured in /etc/rsyslog.conf, line 61
Jun 15 18:13:35 oem rsyslogd:could not load module '/usr/lib64/rsyslog/ommysql', dlopen: /usr/lib64/rsyslog/ommysql: cannot open shared object file: No such file or directory
Jun 15 18:13:35 oem rsyslogd:the last error occured in /etc/rsyslog.conf, line 62
Jun 15 18:13:35 oem rsyslogd:could not load module '/usr/lib64/rsyslog/imtcp', dlopen: /usr/lib64/rsyslog/imtcp: cannot open shared object file: No such file or directory
Jun 15 18:13:35 oem rsyslogd:the last error occured in /etc/rsyslog.conf, line 63
Jun 15 18:13:35 oem rsyslogd:could not load module '/usr/lib64/rsyslog/imudp', dlopen: /usr/lib64/rsyslog/imudp: cannot open shared object file: No such file or directory
Jun 15 18:13:35 oem rsyslogd:the last error occured in /etc/rsyslog.conf, line 64
Jun 15 18:13:35 oem rsyslogd:invalid or yet-unknown config file command - have you forgotten to load a module?
Jun 15 18:13:35 oem rsyslogd:the last error occured in /etc/rsyslog.conf, line 65
Jun 15 18:13:35 oem rsyslogd:unknown facility name "if"
Jun 15 18:13:35 oem rsyslogd:the last error occured in /etc/rsyslog.conf, line 76
Jun 15 18:13:35 oem rsyslogd:warning: selector line without actions will be discarded
Jun 15 18:13:35 oem kernel: rklogd 2.0.6, log source = /proc/kmsg started.
--------------------------------------------------------------------------------------
Would anybody please help me How I can I resolve this error .
Here I mention that I am using built-in rsyslog package for my linux server (Red Hat Enterprise Linux Server release 5.4 (Tikanga))