0

我正在尝试使用 Debian 9 在我的 f1-micro 实例上安装监控代理并运行 dockerised 应用程序。我正在关注https://cloud.google.com/monitoring/agent/install-agent#linux-install教程。当我执行时,sudo bash install-monitoring-agent.sh我收到一条消息Unidentifiable or unsupported platform.

我做错什么了吗?

4

1 回答 1

0

在 bash 脚本中,您会看到他正在查看 [/etc/os-release] 上的 os-release,如下所示:

==================================================== ===========================

# Fallback for systems lacking /etc/os-release.
      if [[ -f /etc/debian_version ]]; then
        echo 'Installing agent for Debian.'
        install_for_debian
      elif [[ -f /etc/redhat-release ]]; then
        echo 'Installing agent for Red Hat.'
        install_for_redhat
      else
        echo >&2 'Unidentifiable or unsupported platform.'
        echo >&2 "See ${MONITORING_AGENT_SUPPORTED_URL} for a list of supported platforms."
        exit 1

检查 [/etc/os-release]。通常支持 Debian,我确实用 Debian 安装了 {f1-micro} 机器,它运行良好,输出应该如下所示:

~$ sudo cat /etc/os-release
PRETTY_NAME="Debian GNU/Linux 9 (stretch)"
NAME="Debian GNU/Linux"
VERSION_ID="9"
VERSION="9 (stretch)"
ID=debian
HOME_URL="https://www.debian.org/"
SUPPORT_URL="https://www.debian.org/support"
BUG_REPORT_URL="https://bugs.debian.org/"
于 2018-06-26T15:32:53.093 回答