Note:
This topic has been translated from a Chinese forum by GPT and might contain errors.Original topic: CLUSTER_LOG 表是实时读的服务器上的日志吗?
|
username: 我是咖啡哥
Just casually checked the system table, and an error occurred when opening CLUSTER_LOG.
select * from INFORMATION_SCHEMA.CLUSTER_LOG limit 1;
ERROR 1105 (HY000): denied to scan logs, please specify the start time, such as `time > '2020-01-01 00:00:00'`
You must specify the time and more fields to query. For example:
SELECT * FROM INFORMATION_SCHEMA.CLUSTER_LOG t WHERE time > '2022-08-09 00:00:00'
AND time < '2022-08-10 00:00:00'
and TYPE in ('tikv')
AND `LEVEL` = 'ERROR'
ORDER BY time desc;
Looking at the results, it is consistent with the log search on the dashboard.
One question, is this log table not stored in the database, and when searching, it directly pulls the logs from the corresponding node servers?