问题1:
执行“SELECT
TO_CHAR(ts, 'yyyy-mm-dd hh24:mi:ss') AS time,
labels->'instance' AS instance,
IRATE(AVG(v)) AS irate_value
FROM prometheus_data_sit.metrics
WHERE labels->'name' = 'container_cpu_usage_seconds_total'
AND ts > '2023-12-19 00:00:00'
AND ts < '2023-12-19 23:59:59'
AND labels->'instance' = '***'
GROUP BY TO_CHAR(ts, 'yyyy-mm-dd hh24:mi:ss'), labels->'instance'
ORDER BY time; ” 这个sql 数据库会重启,根文件下面core文件生成多个 。这个sql的意思是算出 container_cpu_usage_seconds_total 容器cpu 5分钟内增长率。
问题2:
Prometheus数据接入的时候 taosdata 报错:0x219 sql statement too long
接入1个指标的时候 报错很少 ,接入30个的时候 权限 sql statement too long
问题1: 执行“SELECT TO_CHAR(ts, 'yyyy-mm-dd hh24:mi:ss') AS time, labels->'instance' AS instance, IRATE(AVG(v)) AS irate_value FROM prometheus_data_sit.metrics WHERE labels->'name' = 'container_cpu_usage_seconds_total' AND ts > '2023-12-19 00:00:00' AND ts < '2023-12-19 23:59:59' AND labels->'instance' = '***' GROUP BY TO_CHAR(ts, 'yyyy-mm-dd hh24:mi:ss'), labels->'instance' ORDER BY time; ” 这个sql 数据库会重启,根文件下面core文件生成多个 。这个sql的意思是算出 container_cpu_usage_seconds_total 容器cpu 5分钟内增长率。 问题2: Prometheus数据接入的时候 taosdata 报错:0x219 sql statement too long 接入1个指标的时候 报错很少 ,接入30个的时候 权限 sql statement too long