Stackdriver代理找不到collectd端点

时间:2016-04-05 15:59:06

标签: google-cloud-platform stackdriver google-cloud-monitoring

我正在GCE实例上安装stackdriver代理,它给了我错误:

  

$ sudo / opt / stackdriver / stack-config --write-gcm

Checking platform...
Using Cloud Monitoring API
update-rc.d: warning:  start runlevel arguments (none) do not match stackdriver-extractor Default-Start values (2 3 4 5)
update-rc.d: warning:  stop runlevel arguments (none) do not match stackdriver-extractor Default-Stop values (0 1 6)
Disabling system startup links for /etc/init.d/stackdriver-extractor ...
Removing any system startup links for /etc/init.d/stackdriver-extractor ...
  /etc/rc0.d/K20stackdriver-extractor
  /etc/rc1.d/K20stackdriver-extractor
  /etc/rc2.d/K80stackdriver-extractor
  /etc/rc3.d/K80stackdriver-extractor
  /etc/rc4.d/K80stackdriver-extractor
  /etc/rc5.d/K80stackdriver-extractor
  /etc/rc6.d/K20stackdriver-extractor
Adding system startup for /etc/init.d/stackdriver-extractor ...
 /etc/rc0.d/K20stackdriver-extractor -> ../init.d/stackdriver-extractor
 /etc/rc1.d/K20stackdriver-extractor -> ../init.d/stackdriver-extractor
 /etc/rc6.d/K20stackdriver-extractor -> ../init.d/stackdriver-extractor
 /etc/rc2.d/K80stackdriver-extractor -> ../init.d/stackdriver-extractor
 /etc/rc3.d/K80stackdriver-extractor -> ../init.d/stackdriver-extractor
 /etc/rc4.d/K80stackdriver-extractor -> ../init.d/stackdriver-extractor
 /etc/rc5.d/K80stackdriver-extractor -> ../init.d/stackdriver-extractor
Restarting services
 * Restarting Stackdriver metrics collection agent stackdriver-agent
Unable to determine collectd endpoint!
 * not starting, configuration error
...fail!

我该如何解决?

1 个答案:

答案 0 :(得分:1)

我发现了我的问题,我们正在使用stackdriver帐户并从多个GCP项目中收集指标,因此我需要为该帐户使用API​​密钥(--api-key选项),而不是使用默认的GCM安装(--write-gcm选项)。