nebula-stats-exporter.log 日志太大了 几天就几十G,如何关闭这个日志

提问参考模版:

  • nebula 版本:v3.6.0

  • 部署方式: 分布式

  • 安装方式: Docker

  • 是否上生产环境:Y

  • 问题的具体描述

  • nebula-stats-exporter.log 日志太大了 几天就几十G,如何关闭这个日志

您好,可以看下是什么样的日志内容吗,正常不会有这么多日志。exporter目前还不支持关闭日志或者减少日志输出,可以给我们提一个issue GitHub - vesoft-inc/nebula-stats-exporter: Data exporter of Nebula Graph

1 个赞
[root@localhost logs]# more  nebula-stats-exporter.log
I1115 14:34:55.262336   20680 main.go:121] Providing metrics at :19200/metrics
I1115 14:35:04.351046   20680 exporter.go:91] Start collect
I1115 14:35:04.351112   20680 exporter.go:157] Collect default:METAD metad0:19559 Metrics 
I1115 14:35:04.351170   20680 exporter.go:157] Collect default:METAD metad1:19559 Metrics 
I1115 14:35:04.351191   20680 exporter.go:157] Collect default:METAD metad2:19559 Metrics 
I1115 14:35:04.351210   20680 exporter.go:157] Collect default:STORAGED storaged0:19779 Metrics 
I1115 14:35:04.351228   20680 exporter.go:157] Collect default:STORAGED storaged0:19779 Metrics 
I1115 14:35:04.351278   20680 exporter.go:157] Collect default:STORAGED storaged0:19779 Metrics 
I1115 14:35:04.351502   20680 exporter.go:157] Collect default:STORAGED storaged0:19779 Metrics 
I1115 14:35:04.351541   20680 exporter.go:157] Collect default:STORAGED storaged1:19779 Metrics 
I1115 14:35:04.351789   20680 exporter.go:157] Collect default:GRAPHD graphd0:19669 Metrics 
I1115 14:35:04.351814   20680 exporter.go:157] Collect default:GRAPHD graphd1:19669 Metrics 
I1115 14:35:04.351829   20680 exporter.go:157] Collect default:GRAPHD graphd2:19669 Metrics 
I1115 14:35:04.351844   20680 exporter.go:157] Collect default:GRAPHD graphd3:19669 Metrics 
I1115 14:35:04.354160   20680 exporter.go:157] Collect default:GRAPHD graphd4:19669 Metrics 
I1115 14:35:04.503055   20680 exporter.go:93] Complete collect, time elapse 152.072469ms
time="2023-11-15T14:35:04+08:00" level=error msg="error gathering metrics: 2139 error(s) occurred:\n* [from Gatherer #1] collected metric \"nebula_storaged_count\" { label:<name:\"componentType\" value:\"storaged\" > label:<name:\"ins
tanceName\" value:\"storaged0\" > label:<name:\"nebula_cluster\" value:\"default\" > gauge:<value:1 > } was collected before with the same name and label values\n* [from Gatherer #1] collected metric \"nebula_storaged_count\" { label:
<name:\"componentType\" value:\"storaged\" > label:<name:\"instanceName\" value:\"storaged0\" > label:<name:\"nebula_cluster\" value:\"default\" > gauge:<value:1 > } was collected before with the same name and label values\n* [from Ga
therer #1] collected metric \"nebula_storaged_count\" { label:<name:\"componentType\" value:\"storaged\" > label:<name:\"instanceName\" value:\"storaged0\" > label:<name:\"nebula_cluster\" value:\"default\" > gauge:<value:1 > } was co
llected before with the same name and label values\n* [from Gatherer #1] collected metric \"nebula_storaged_kv_remove_latency_us_avg_5\" { label:<name:\"componentType\" value:\"storaged\" > label:<name:\"instanceName\" value:\"storage
d0\" > label:<name:\"nebula_cluster\" value:\"default\" > gauge:<value:0 > } was collected before with the same name and label values\n* [from Gatherer #1] collected metric \"nebula_storaged_kv_remove_latency_us_avg_60\" { label:<name
:\"componentType\" value:\"storaged\" > label:<name:\"instanceName\" value:\"storaged0\" > label:<name:\"nebula_cluster\" value:\"default\" > gauge:<value:0 > } was collected before with the same name and label values\n* [from Gathere
r #1] collected metric \"nebula_storaged_kv_remove_latency_us_avg_600\" { label:<name:\"componentType\" value:\"storaged\" > label:<name:\"instanceName\" value:\"storaged0\" > label:<name:\"nebula_cluster\" value:\"default\" > gauge:<
value:0 > } was collected before with the same name and label values\n* [from Gatherer #1] collected metric \"nebula_storaged_kv_remove_latency_us_avg_3600\" { label:<name:\"componentType\" value:\"storaged\" > label:<name:\"instanceN
ame\" value:\"storaged0\" > label:<name:\"nebula_cluster\" value:\"default\" > gauge:<value:0 > } was collected before with the same name and label values\n* [from Gatherer #1] collected metric \"nebula_storaged_kv_remove_latency_us_p
75_5\" { label:<name:\"componentType\" value:\"storaged\" > label:<name:\"instanceName\" value:\"storaged0\" > label:<name:\"nebula_cluster\" value:\"default\" > gauge:<value:0 > } was collected before with the same name and label val
ues\n* [from Gatherer #1] collected metric \"nebula_storaged_kv_remove_latency_us_p75_60\" { label:<name:\"componentType\" value:\"storaged\" > label:<name:\"instanceName\" value:\"storaged0\" > label:<name:\"nebula_cluster\" value:\"
default\" > gauge:<value:0 > } was collected before with the same name and label values\n* [from Gatherer #1] collected metric \"nebula_storaged_kv_remove_latency_us_p75_600\" { label:<name:\"componentType\" value:\"storaged\" > label
:<name:\"instanceName\" value:\"storaged0\" > label:<name:\"nebula_cluster\" value:\"default\" > gauge:<value:0 > } was collected before with the same name and label values\n* [from Gatherer #1] collected metric \"nebula_storaged_kv_r
emove_latency_us_p75_3600\" { label:<name:\"componentType\" value:\"storaged\" > label:<name:\"instanceName\" value:\"storaged0\" > label:<name:\"nebula_cluster\" value:\"default\" > gauge:<value:0 > } was collected before with the sa
me name and label values\n* [from Gatherer #1] collected metric \"nebula_storaged_kv_remove_latency_us_p95_5\" { label:<name:\"componentType\" value:\"storaged\" > label:<name:\"instanceName\" value:\"storaged0\" > label:<name:\"nebul
a_cluster\" value:\"default\" > gauge:<value:0 > } was collected before with the same name and label values\n* [from Gatherer #1] collected metric \"nebula_storaged_kv_remove_latency_us_p95_60\" { label:<name:\"componentType\" value:\
"storaged\" > label:<name:\"instanceName\" value:\"storaged0\" > label:<name:\"nebula_cluster\" value:\"default\" > gauge:<value:0 > } was collected before with the same name and label values\n* [from Gatherer #1] collected metric \"n
ebula_storaged_kv_remove_latency_us_p95_600\" { label:<name:\"componentType\" value:\"storaged\" > label:<name:\"instanceName\" value:\"storaged0\" > label:<name:\"nebula_cluster\" value:\"default\" > gauge:<value:0 > } was collected 
before with the same name and label values\n* [from Gatherer #1] collected metric \"nebula_storaged_kv_remove_latency_us_p95_3600\" { label:<name:\"componentType\" value:\"storaged\" > label:<name:\"instanceName\" value:\"storaged0\" 
> label:<name:\"nebula_cluster\" value:\"default\" > gauge:<value:0 > } was collected before with the same name and label values\n* [from Gatherer #1] collected metric \"nebula_storaged_kv_remove_latency_us_p99_5\" { label:<name:\"com
ponentType\" value:\"storaged\" > label:<name:\"instanceName\" value:\"storaged0\" > label:<name:\"nebula_cluster\" value:\"default\" > gauge:<value:0 > } was collected before with the same name and label values\n* [from Gatherer #1] 
collected metric \"nebula_storaged_kv_remove_latency_us_p99_60\" { label:<name:\"componentType\" value:\"storaged\" > label:<name:\"instanceName\" value:\"storaged0\" > label:<name:\"nebula_cluster\" value:\"default\" > gauge:<value:0
 > } was collected before with the same name and label values\n* [from Gatherer #1] collected metric \"nebula_storaged_kv_remove_latency_us_p99_600\" { label:<name:\"componentType\" value:\"storaged\" > label:<name:\"instanceName\" va
lue:\"storaged0\" > label:<name:\"nebula_cluster\" value:\"default\" > gauge:<value:0 > } was collected before with the same name and label values\n* [from Gatherer #1] collected metric \"nebula_storaged_kv_remove_latency_us_p99_3600\
" { label:<name:\"componentType\" value:\"storaged\" > label:<name:\"instanceName\" value:\"storaged0\" > label:<name:\"nebula_cluster\" value:\"default\" > gauge:<value:0 > } was collected before with the same name and label values\n
* [from Gatherer #1] collected metric \"nebula_storaged_num_kv_remove_rate_5\" { label:<name:\"componentType\" value:\"storaged\" > label:<name:\"instanceName\" value:\"storaged0\" > label:<name:\"nebula_cluster\" value:\"default\" > 
gauge:<value:0 > } was collected before with the same name and label values\n* [from Gatherer #1] collected metric \"nebula_storaged_num_kv_remove_rate_60\" { label:<name:\"componentType\" value:\"storaged\" > label:<name:\"instanceNa
me\" value:\"storaged0\" > label:<name:\"nebula_cluster\" value:\"default\" > gauge:<value:0 > } was collected before with the same name and label values\n* [from Gatherer #1] collected metric \"nebula_storaged_num_kv_remove_rate_600\
" { label:<name:\"componentType\" value:\"storaged\" > label:<name:\"instanceName\" value:\"storaged0\" > label:<name:\"nebula_cluster\" value:\"default\" > gauge:<value:0 > } was collected before with the same name and label values\n
* [from Gatherer #1] collected metric \"nebula_storaged_num_kv_remove_rate_3600\" { label:<name:\"componentType\" value:\"storaged\" > label:<name:\"instanceName\" value:\"storaged0\" > label:<name:\"nebula_cluster\" value:\"default\"
 > gauge:<value:0 > } was collected before with the same name and label values\n* [from Gatherer #1] collected metric \"nebula_storaged_num_kv_remove_sum_5\" { label:<name:\"componentType\" value:\"storaged\" > label:<name:\"instanceN

使用more 命令 copy 了 开头的日志

看起来是重复采集指标产生的报错,导致日志增长的很快,请问您是bare-metal启动的exporter吗,可以看下配置对应的文件

可以用logrotate来做

此话题已在最后回复的 30 天后被自动关闭。不再允许新回复。