Greetings!! I have installed Sentinel 7 and initialized event source
for mysql to get data from general_log table. JDBC connector is unable
to read the logging table general_log. When I analyzed, I found that
sentinel's JDBC event source trying to run to get log from table with
following query (as mentioned in general_log):
+---------------------+---------------------------------------+-----------+-----------+--------------+----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
| event_time | user_host |
thread_id | server_id | command_type | argument


|
+---------------------+---------------------------------------+-----------+-----------+--------------+----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
| 2012-12-27 17:09:22 | root[root] @ [192.168.1.109] | 1 |
0 | Query | SELECT event_time , user_host host , thread_id tID
, server_id sID , command_type commandType, argument argument FROM
general_log WHERE cast(event_time as datetime) >= 'null' order by
event_time limit 200 | | 2012-12-27 17:18:21 | sentinel[sentinel] @
[192.168.1.109] | 5 | 0 | Query | SELECT
event_time , user_host host , thread_id tID , server_id sID ,
command_type commandType, argument argument FROM general_log WHERE
cast(event_time as datetime) >= 'null' order by event_time limit 200 |
But when I run this command from console, I get Empty Set with 1 warning
as follows: mysql> SELECT event_time , user_host host , thread_id tID ,
server_id sID , command_type commandType, argument argument FROM
general_log WHERE cast(event_time as datetime) >= 'null' order by
event_time limit 200 ; Empty set, 1 warning (0.25 sec) When I looked at
warning, it shows: mysql> SHOW WARNINGS;
+---------+------+--------------------------------------------+ | Level
| Code | Message |
+---------+------+--------------------------------------------+ |
Warning | 1292 | Truncated incorrect datetime value: 'null' |
+---------+------+--------------------------------------------+ 1 row in
set (0.00 sec) I have tried two users, root & sentinel, but getting no
event into the sentinel. I suspect issue in the WHERE clause in
statement used by JDBC connector. Please suggest the solution.


--
rajeshemailto
------------------------------------------------------------------------
rajeshemailto's Profile: https://forums.netiq.com/member.php?userid=196
View this thread: https://forums.netiq.com/showthread.php?t=46449