當您需要監控部署在Container Service Kubernetes 版ACK或Container Compute ServiceACS中的Go應用時,通過安裝ARMS應用監控組件ack-onepilot並編譯Go二進位檔案,即可在應用即時監控服務ARMS中查看對應應用的應用拓撲、介面調用、資料庫分析等相關監控資料。本文將介紹如何為部署在Container Service Kubernetes 版ACK或Container Compute ServiceACS中的Go應用安裝探針。
Container Service Kubernetes 版ACK和Container Compute ServiceACS安裝探針的操作相同,本文以Container Service Kubernetes 版ACK為例示範安裝探針的操作。
如果您在使用Golang探針過程中有任何問題,歡迎通過DingTalk答疑群(群號:35568145)與我們聯絡。
前提條件
建立ACK叢集或ACS叢集。
ACK叢集:建立ACK託管叢集、建立註冊叢集、建立ACK專有叢集、建立ACK Serverless叢集。
ACS叢集:建立ACS叢集。
建立命名空間,具體操作,請參見管理命名空間與配額。本文樣本中的命名空間名稱為default。
檢查您的編譯環境作業系統和架構,以及Go版本和架構版本。具體要求,請參見ARMS應用監控支援的Golang組件和架構。
應用監控目前只支援使用Go mod的倉庫編譯,如果沒有Go mod檔案,可以使用Go mod init建立Go mod。
步驟一:安裝ARMS探針接入助手(ack-onepilot)
登入Container Service管理主控台,在叢集列表頁面單擊目的地組群名稱。
在左側導覽列選擇營運管理 > 組件管理,然後在右上方通過關鍵字搜尋ack-onepilot。
重要請確保ack-onepilot的版本在3.2.0或以上。
在ack-onepilot卡片上單擊安裝。
說明ack-onepilot組件預設支援1000個pod規模,叢集pod每超過1000個,ack-onepilot資源對應的CPU請增加0.5核、記憶體請增加512 MB。
在彈出的頁面中可以配置相關的參數,建議使用預設值,單擊確定。
說明安裝完成後,您可以在組件管理頁面升級、配置或卸載ack-onepilot組件。
步驟二:編譯Go二進位檔案
使用
wget
命令下載編譯工具instgo,請根據編譯環境和編譯機器所在地區,選擇對應的下載地址。需要注意,instgo 在編譯時間會觸發自動更新,請將 instgo 儲存在編譯使用者具有修改許可權的目錄下。
說明Instgo 是 ARMS 提供的 Golang 應用編譯工具,使用 instgo 編譯您的 Golang 專案後,ARMS 即可開始監控您的 Golang 應用。
各地區下載的編譯工具是相同的,如果您的公網環境可以訪問OSS地址,可以直接使用對應作業系統和架構的杭州公網地址擷取編譯工具。
展開查看各地區對應的下載命令
Linux(AMD64)
地區
公網地址
VPC地址
華東1(杭州)
wget "http://arms-apm-cn-hangzhou.oss-cn-hangzhou.aliyuncs.com/instgo/instgo-linux-amd64" -O instgo
wget "http://arms-apm-cn-hangzhou.oss-cn-hangzhou-internal.aliyuncs.com/instgo/instgo-linux-amd64" -O instgo
華東2(上海)
wget "http://arms-apm-cn-shanghai.oss-cn-shanghai.aliyuncs.com/instgo/instgo-linux-amd64" -O instgo
wget "http://arms-apm-cn-shanghai.oss-cn-shanghai-internal.aliyuncs.com/instgo/instgo-linux-amd64" -O instgo
華北1(青島)
wget "http://arms-apm-cn-qingdao.oss-cn-qingdao.aliyuncs.com/instgo/instgo-linux-amd64" -O instgo
wget "http://arms-apm-cn-qingdao.oss-cn-qingdao-internal.aliyuncs.com/instgo/instgo-linux-amd64" -O instgo
華北2(北京)
wget "http://arms-apm-cn-beijing.oss-cn-beijing.aliyuncs.com/instgo/instgo-linux-amd64" -O instgo
wget "http://arms-apm-cn-beijing.oss-cn-beijing-internal.aliyuncs.com/instgo/instgo-linux-amd64" -O instgo
華北3(張家口)
wget "http://arms-apm-cn-zhangjiakou.oss-cn-zhangjiakou.aliyuncs.com/instgo/instgo-linux-amd64" -O instgo
wget "http://arms-apm-cn-zhangjiakou.oss-cn-zhangjiakou-internal.aliyuncs.com/instgo/instgo-linux-amd64" -O instgo
華北5(呼和浩特)
wget "http://arms-apm-cn-huhehaote.oss-cn-huhehaote.aliyuncs.com/instgo/instgo-linux-amd64" -O instgo
wget "http://arms-apm-cn-huhehaote.oss-cn-huhehaote-internal.aliyuncs.com/instgo/instgo-linux-amd64" -O instgo
華北6(烏蘭察布)
wget "http://arms-apm-cn-wulanchabu.oss-cn-wulanchabu.aliyuncs.com/instgo/instgo-linux-amd64" -O instgo
wget "http://arms-apm-cn-wulanchabu.oss-cn-wulanchabu-internal.aliyuncs.com/instgo/instgo-linux-amd64" -O instgo
華南1(深圳)
wget "http://arms-apm-cn-shenzhen.oss-cn-shenzhen.aliyuncs.com/instgo/instgo-linux-amd64" -O instgo
wget "http://arms-apm-cn-shenzhen.oss-cn-shenzhen-internal.aliyuncs.com/instgo/instgo-linux-amd64" -O instgo
華南2(河源)
wget "http://arms-apm-cn-heyuan.oss-cn-heyuan.aliyuncs.com/instgo/instgo-linux-amd64" -O instgo
wget "http://arms-apm-cn-heyuan.oss-cn-heyuan-internal.aliyuncs.com/instgo/instgo-linux-amd64" -O instgo
華南3(廣州)
wget "http://arms-apm-cn-guangzhou.oss-cn-guangzhou.aliyuncs.com/instgo/instgo-linux-amd64" -O instgo
wget "http://arms-apm-cn-guangzhou.oss-cn-guangzhou-internal.aliyuncs.com/instgo/instgo-linux-amd64" -O instgo
西南1(成都)
wget "http://arms-apm-cn-chengdu.oss-cn-chengdu.aliyuncs.com/instgo/instgo-linux-amd64" -O instgo
wget "http://arms-apm-cn-chengdu.oss-cn-chengdu-internal.aliyuncs.com/instgo/instgo-linux-amd64" -O instgo
中國(香港)
wget "http://arms-apm-cn-hongkong.oss-cn-hongkong.aliyuncs.com/instgo/instgo-linux-amd64" -O instgo
wget "http://arms-apm-cn-hongkong.oss-cn-hongkong-internal.aliyuncs.com/instgo/instgo-linux-amd64" -O instgo
新加坡
wget "http://arms-apm-ap-southeast-1.oss-ap-southeast-1.aliyuncs.com/instgo/instgo-linux-amd64" -O instgo
wget "http://arms-apm-ap-southeast-1.oss-ap-southeast-1-internal.aliyuncs.com/instgo/instgo-linux-amd64" -O instgo
亞太地區東南3(吉隆坡)
wget "http://arms-apm-ap-southeast-3.oss-ap-southeast-3.aliyuncs.com/instgo/instgo-linux-amd64" -O instgo
wget "http://arms-apm-ap-southeast-3.oss-ap-southeast-3-internal.aliyuncs.com/instgo/instgo-linux-amd64" -O instgo
亞太地區東南5(雅加達)
wget "http://arms-apm-ap-southeast-5.oss-ap-southeast-5.aliyuncs.com/instgo/instgo-linux-amd64" -O instgo
wget "http://arms-apm-ap-southeast-5.oss-ap-southeast-5-internal.aliyuncs.com/instgo/instgo-linux-amd64" -O instgo
亞太地區東北1(東京)
wget "http://arms-apm-ap-northeast-1.oss-ap-northeast-1.aliyuncs.com/instgo/instgo-linux-amd64" -O instgo
wget "http://arms-apm-ap-northeast-1.oss-ap-northeast-1-internal.aliyuncs.com/instgo/instgo-linux-amd64" -O instgo
歐洲中部1(法蘭克福)
wget "http://arms-apm-eu-central-1.oss-eu-central-1.aliyuncs.com/instgo/instgo-linux-amd64" -O instgo
wget "http://arms-apm-eu-central-1.oss-eu-central-1-internal.aliyuncs.com/instgo/instgo-linux-amd64" -O instgo
歐洲西部1(倫敦)
wget "http://arms-apm-eu-west-1.oss-eu-west-1.aliyuncs.com/instgo/instgo-linux-amd64" -O instgo
wget "http://arms-apm-eu-west-1.oss-eu-west-1-internal.aliyuncs.com/instgo/instgo-linux-amd64" -O instgo
美國東部1(維吉尼亞)
wget "http://arms-apm-us-east-1.oss-us-east-1.aliyuncs.com/instgo/instgo-linux-amd64" -O instgo
wget "http://arms-apm-us-east-1.oss-us-east-1-internal.aliyuncs.com/instgo/instgo-linux-amd64" -O instgo
美國西部1(矽谷)
wget "http://arms-apm-us-west-1.oss-us-west-1.aliyuncs.com/instgo/instgo-linux-amd64" -O instgo
wget "http://arms-apm-us-west-1.oss-us-west-1-internal.aliyuncs.com/instgo/instgo-linux-amd64" -O instgo
華東1金融雲
無
wget "http://arms-apm-cn-hangzhou-finance.oss-cn-hzjbp-b-internal.aliyuncs.com/instgo/instgo-linux-amd64" -O instgo
華東2金融雲
無
wget "http://arms-apm-cn-shanghai-finance-1.oss-cn-shanghai-finance-1-internal.aliyuncs.com/instgo/instgo-linux-amd64" -O instgo
華南1金融雲
無
wget "http://arms-apm-cn-shenzhen-finance-1.oss-cn-shenzhen-finance-1-internal.aliyuncs.com/instgo/instgo-linux-amd64" -O instgo
政務雲
wget "http://arms-apm-cn-north-2-gov-1.oss-cn-north-2-gov-1.aliyuncs.com/instgo/instgo-linux-amd64" -O instgo
wget "http://arms-apm-cn-north-2-gov-1.oss-cn-north-2-gov-1-internal.aliyuncs.com/instgo/instgo-linux-amd64" -O instgo
Linux(ARM64)
地區
公網地址
VPC地址
華東1(杭州)
wget "http://arms-apm-cn-hangzhou.oss-cn-hangzhou.aliyuncs.com/instgo/instgo-linux-arm64" -O instgo
wget "http://arms-apm-cn-hangzhou.oss-cn-hangzhou-internal.aliyuncs.com/instgo/instgo-linux-arm64" -O instgo
華東2(上海)
wget "http://arms-apm-cn-shanghai.oss-cn-shanghai.aliyuncs.com/instgo/instgo-linux-arm64" -O instgo
wget "http://arms-apm-cn-shanghai.oss-cn-shanghai-internal.aliyuncs.com/instgo/instgo-linux-arm64" -O instgo
華北1(青島)
wget "http://arms-apm-cn-qingdao.oss-cn-qingdao.aliyuncs.com/instgo/instgo-linux-arm64" -O instgo
wget "http://arms-apm-cn-qingdao.oss-cn-qingdao-internal.aliyuncs.com/instgo/instgo-linux-arm64" -O instgo
華北2(北京)
wget "http://arms-apm-cn-beijing.oss-cn-beijing.aliyuncs.com/instgo/instgo-linux-arm64" -O instgo
wget "http://arms-apm-cn-beijing.oss-cn-beijing-internal.aliyuncs.com/instgo/instgo-linux-arm64" -O instgo
華北3(張家口)
wget "http://arms-apm-cn-zhangjiakou.oss-cn-zhangjiakou.aliyuncs.com/instgo/instgo-linux-arm64" -O instgo
wget "http://arms-apm-cn-zhangjiakou.oss-cn-zhangjiakou-internal.aliyuncs.com/instgo/instgo-linux-arm64" -O instgo
華北5(呼和浩特)
wget "http://arms-apm-cn-huhehaote.oss-cn-huhehaote.aliyuncs.com/instgo/instgo-linux-arm64" -O instgo
wget "http://arms-apm-cn-huhehaote.oss-cn-huhehaote-internal.aliyuncs.com/instgo/instgo-linux-arm64" -O instgo
華北6(烏蘭察布)
wget "http://arms-apm-cn-wulanchabu.oss-cn-wulanchabu.aliyuncs.com/instgo/instgo-linux-arm64" -O instgo
wget "http://arms-apm-cn-wulanchabu.oss-cn-wulanchabu-internal.aliyuncs.com/instgo/instgo-linux-arm64" -O instgo
華南1(深圳)
wget "http://arms-apm-cn-shenzhen.oss-cn-shenzhen.aliyuncs.com/instgo/instgo-linux-arm64" -O instgo
wget "http://arms-apm-cn-shenzhen.oss-cn-shenzhen-internal.aliyuncs.com/instgo/instgo-linux-arm64" -O instgo
華南2(河源)
wget "http://arms-apm-cn-heyuan.oss-cn-heyuan.aliyuncs.com/instgo/instgo-linux-arm64" -O instgo
wget "http://arms-apm-cn-heyuan.oss-cn-heyuan-internal.aliyuncs.com/instgo/instgo-linux-arm64" -O instgo
華南3(廣州)
wget "http://arms-apm-cn-guangzhou.oss-cn-guangzhou.aliyuncs.com/instgo/instgo-linux-arm64" -O instgo
wget "http://arms-apm-cn-guangzhou.oss-cn-guangzhou-internal.aliyuncs.com/instgo/instgo-linux-arm64" -O instgo
西南1(成都)
wget "http://arms-apm-cn-chengdu.oss-cn-chengdu.aliyuncs.com/instgo/instgo-linux-arm64" -O instgo
wget "http://arms-apm-cn-chengdu.oss-cn-chengdu-internal.aliyuncs.com/instgo/instgo-linux-arm64" -O instgo
中國(香港)
wget "http://arms-apm-cn-hongkong.oss-cn-hongkong.aliyuncs.com/instgo/instgo-linux-arm64" -O instgo
wget "http://arms-apm-cn-hongkong.oss-cn-hongkong-internal.aliyuncs.com/instgo/instgo-linux-arm64" -O instgo
新加坡
wget "http://arms-apm-ap-southeast-1.oss-ap-southeast-1.aliyuncs.com/instgo/instgo-linux-arm64" -O instgo
wget "http://arms-apm-ap-southeast-1.oss-ap-southeast-1-internal.aliyuncs.com/instgo/instgo-linux-arm64" -O instgo
亞太地區東南3(吉隆坡)
wget "http://arms-apm-ap-southeast-3.oss-ap-southeast-3.aliyuncs.com/instgo/instgo-linux-arm64" -O instgo
wget "http://arms-apm-ap-southeast-3.oss-ap-southeast-3-internal.aliyuncs.com/instgo/instgo-linux-arm64" -O instgo
亞太地區東南5(雅加達)
wget "http://arms-apm-ap-southeast-5.oss-ap-southeast-5.aliyuncs.com/instgo/instgo-linux-arm64" -O instgo
wget "http://arms-apm-ap-southeast-5.oss-ap-southeast-5-internal.aliyuncs.com/instgo/instgo-linux-arm64" -O instgo
亞太地區東北1(東京)
wget "http://arms-apm-ap-northeast-1.oss-ap-northeast-1.aliyuncs.com/instgo/instgo-linux-arm64" -O instgo
wget "http://arms-apm-ap-northeast-1.oss-ap-northeast-1-internal.aliyuncs.com/instgo/instgo-linux-arm64" -O instgo
歐洲中部1(法蘭克福)
wget "http://arms-apm-eu-central-1.oss-eu-central-1.aliyuncs.com/instgo/instgo-linux-arm64" -O instgo
wget "http://arms-apm-eu-central-1.oss-eu-central-1-internal.aliyuncs.com/instgo/instgo-linux-arm64" -O instgo
歐洲西部1(倫敦)
wget "http://arms-apm-eu-west-1.oss-eu-west-1.aliyuncs.com/instgo/instgo-linux-arm64" -O instgo
wget "http://arms-apm-eu-west-1.oss-eu-west-1-internal.aliyuncs.com/instgo/instgo-linux-arm64" -O instgo
美國東部1(維吉尼亞)
wget "http://arms-apm-us-east-1.oss-us-east-1.aliyuncs.com/instgo/instgo-linux-arm64" -O instgo
wget "http://arms-apm-us-east-1.oss-us-east-1-internal.aliyuncs.com/instgo/instgo-linux-arm64" -O instgo
美國西部1(矽谷)
wget "http://arms-apm-us-west-1.oss-us-west-1.aliyuncs.com/instgo/instgo-linux-arm64" -O instgo
wget "http://arms-apm-us-west-1.oss-us-west-1-internal.aliyuncs.com/instgo/instgo-linux-arm64" -O instgo
華東1金融雲
無
wget "http://arms-apm-cn-hangzhou-finance.oss-cn-hzjbp-b-internal.aliyuncs.com/instgo/instgo-linux-arm64" -O instgo
華東2金融雲
無
wget "http://arms-apm-cn-shanghai-finance-1.oss-cn-shanghai-finance-1-internal.aliyuncs.com/instgo/instgo-linux-arm64" -O instgo
華南1金融雲
無
wget "http://arms-apm-cn-shenzhen-finance-1.oss-cn-shenzhen-finance-1-internal.aliyuncs.com/instgo/instgo-linux-arm64" -O instgo
政務雲
wget "http://arms-apm-cn-north-2-gov-1.oss-cn-north-2-gov-1.aliyuncs.com/instgo/instgo-linux-arm64" -O instgo
wget "http://arms-apm-cn-north-2-gov-1.oss-cn-north-2-gov-1-internal.aliyuncs.com/instgo/instgo-linux-arm64" -O instgo
Darwin(ARM64)
地區
公網地址
VPC地址
華東1(杭州)
wget "http://arms-apm-cn-hangzhou.oss-cn-hangzhou.aliyuncs.com/instgo/instgo-darwin-arm64" -O instgo
wget "http://arms-apm-cn-hangzhou.oss-cn-hangzhou-internal.aliyuncs.com/instgo/instgo-darwin-arm64" -O instgo
華東2(上海)
wget "http://arms-apm-cn-shanghai.oss-cn-shanghai.aliyuncs.com/instgo/instgo-darwin-arm64" -O instgo
wget "http://arms-apm-cn-shanghai.oss-cn-shanghai-internal.aliyuncs.com/instgo/instgo-darwin-arm64" -O instgo
華北1(青島)
wget "http://arms-apm-cn-qingdao.oss-cn-qingdao.aliyuncs.com/instgo/instgo-darwin-arm64" -O instgo
wget "http://arms-apm-cn-qingdao.oss-cn-qingdao-internal.aliyuncs.com/instgo/instgo-darwin-arm64" -O instgo
華北2(北京)
wget "http://arms-apm-cn-beijing.oss-cn-beijing.aliyuncs.com/instgo/instgo-darwin-arm64" -O instgo
wget "http://arms-apm-cn-beijing.oss-cn-beijing-internal.aliyuncs.com/instgo/instgo-darwin-arm64" -O instgo
華北3(張家口)
wget "http://arms-apm-cn-zhangjiakou.oss-cn-zhangjiakou.aliyuncs.com/instgo/instgo-darwin-arm64" -O instgo
wget "http://arms-apm-cn-zhangjiakou.oss-cn-zhangjiakou-internal.aliyuncs.com/instgo/instgo-darwin-arm64" -O instgo
華北5(呼和浩特)
wget "http://arms-apm-cn-huhehaote.oss-cn-huhehaote.aliyuncs.com/instgo/instgo-darwin-arm64" -O instgo
wget "http://arms-apm-cn-huhehaote.oss-cn-huhehaote-internal.aliyuncs.com/instgo/instgo-darwin-arm64" -O instgo
華北6(烏蘭察布)
wget "http://arms-apm-cn-wulanchabu.oss-cn-wulanchabu.aliyuncs.com/instgo/instgo-darwin-arm64" -O instgo
wget "http://arms-apm-cn-wulanchabu.oss-cn-wulanchabu-internal.aliyuncs.com/instgo/instgo-darwin-arm64" -O instgo
華南1(深圳)
wget "http://arms-apm-cn-shenzhen.oss-cn-shenzhen.aliyuncs.com/instgo/instgo-darwin-arm64" -O instgo
wget "http://arms-apm-cn-shenzhen.oss-cn-shenzhen-internal.aliyuncs.com/instgo/instgo-darwin-arm64" -O instgo
華南2(河源)
wget "http://arms-apm-cn-heyuan.oss-cn-heyuan.aliyuncs.com/instgo/instgo-darwin-arm64" -O instgo
wget "http://arms-apm-cn-heyuan.oss-cn-heyuan-internal.aliyuncs.com/instgo/instgo-darwin-arm64" -O instgo
華南3(廣州)
wget "http://arms-apm-cn-guangzhou.oss-cn-guangzhou.aliyuncs.com/instgo/instgo-darwin-arm64" -O instgo
wget "http://arms-apm-cn-guangzhou.oss-cn-guangzhou-internal.aliyuncs.com/instgo/instgo-darwin-arm64" -O instgo
西南1(成都)
wget "http://arms-apm-cn-chengdu.oss-cn-chengdu.aliyuncs.com/instgo/instgo-darwin-arm64" -O instgo
wget "http://arms-apm-cn-chengdu.oss-cn-chengdu-internal.aliyuncs.com/instgo/instgo-darwin-arm64" -O instgo
中國(香港)
wget "http://arms-apm-cn-hongkong.oss-cn-hongkong.aliyuncs.com/instgo/instgo-darwin-arm64" -O instgo
wget "http://arms-apm-cn-hongkong.oss-cn-hongkong-internal.aliyuncs.com/instgo/instgo-darwin-arm64" -O instgo
新加坡
wget "http://arms-apm-ap-southeast-1.oss-ap-southeast-1.aliyuncs.com/instgo/instgo-darwin-arm64" -O instgo
wget "http://arms-apm-ap-southeast-1.oss-ap-southeast-1-internal.aliyuncs.com/instgo/instgo-darwin-arm64" -O instgo
亞太地區東南3(吉隆坡)
wget "http://arms-apm-ap-southeast-3.oss-ap-southeast-3.aliyuncs.com/instgo/instgo-darwin-arm64" -O instgo
wget "http://arms-apm-ap-southeast-3.oss-ap-southeast-3-internal.aliyuncs.com/instgo/instgo-darwin-arm64" -O instgo
亞太地區東南5(雅加達)
wget "http://arms-apm-ap-southeast-5.oss-ap-southeast-5.aliyuncs.com/instgo/instgo-darwin-arm64" -O instgo
wget "http://arms-apm-ap-southeast-5.oss-ap-southeast-5-internal.aliyuncs.com/instgo/instgo-darwin-arm64" -O instgo
亞太地區東北1(東京)
wget "http://arms-apm-ap-northeast-1.oss-ap-northeast-1.aliyuncs.com/instgo/instgo-darwin-arm64" -O instgo
wget "http://arms-apm-ap-northeast-1.oss-ap-northeast-1-internal.aliyuncs.com/instgo/instgo-darwin-arm64" -O instgo
歐洲中部1(法蘭克福)
wget "http://arms-apm-eu-central-1.oss-eu-central-1.aliyuncs.com/instgo/instgo-darwin-arm64" -O instgo
wget "http://arms-apm-eu-central-1.oss-eu-central-1-internal.aliyuncs.com/instgo/instgo-darwin-arm64" -O instgo
歐洲西部1(倫敦)
wget "http://arms-apm-eu-west-1.oss-eu-west-1.aliyuncs.com/instgo/instgo-darwin-arm64" -O instgo
wget "http://arms-apm-eu-west-1.oss-eu-west-1-internal.aliyuncs.com/instgo/instgo-darwin-arm64" -O instgo
美國東部1(維吉尼亞)
wget "http://arms-apm-us-east-1.oss-us-east-1.aliyuncs.com/instgo/instgo-darwin-arm64" -O instgo
wget "http://arms-apm-us-east-1.oss-us-east-1-internal.aliyuncs.com/instgo/instgo-darwin-arm64" -O instgo
美國西部1(矽谷)
wget "http://arms-apm-us-west-1.oss-us-west-1.aliyuncs.com/instgo/instgo-darwin-arm64" -O instgo
wget "http://arms-apm-us-west-1.oss-us-west-1-internal.aliyuncs.com/instgo/instgo-darwin-arm64" -O instgo
華東1金融雲
無
wget "http://arms-apm-cn-hangzhou-finance.oss-cn-hzjbp-b-internal.aliyuncs.com/instgo/instgo-darwin-arm64" -O instgo
華東2金融雲
無
wget "http://arms-apm-cn-shanghai-finance-1.oss-cn-shanghai-finance-1-internal.aliyuncs.com/instgo/instgo-darwin-arm64" -O instgo
華南1金融雲
無
wget "http://arms-apm-cn-shenzhen-finance-1.oss-cn-shenzhen-finance-1-internal.aliyuncs.com/instgo/instgo-darwin-arm64" -O instgo
政務雲
wget "http://arms-apm-cn-north-2-gov-1.oss-cn-north-2-gov-1.aliyuncs.com/instgo/instgo-darwin-arm64" -O instgo
wget "http://arms-apm-cn-north-2-gov-1.oss-cn-north-2-gov-1-internal.aliyuncs.com/instgo/instgo-darwin-arm64" -O instgo
Darwin(AMD64)
地區
公網地址
VPC地址
華東1(杭州)
wget "http://arms-apm-cn-hangzhou.oss-cn-hangzhou.aliyuncs.com/instgo/instgo-darwin-amd64" -O instgo
wget "http://arms-apm-cn-hangzhou.oss-cn-hangzhou-internal.aliyuncs.com/instgo/instgo-darwin-amd64" -O instgo
華東2(上海)
wget "http://arms-apm-cn-shanghai.oss-cn-shanghai.aliyuncs.com/instgo/instgo-darwin-amd64" -O instgo
wget "http://arms-apm-cn-shanghai.oss-cn-shanghai-internal.aliyuncs.com/instgo/instgo-darwin-amd64" -O instgo
華北1(青島)
wget "http://arms-apm-cn-qingdao.oss-cn-qingdao.aliyuncs.com/instgo/instgo-darwin-amd64" -O instgo
wget "http://arms-apm-cn-qingdao.oss-cn-qingdao-internal.aliyuncs.com/instgo/instgo-darwin-amd64" -O instgo
華北2(北京)
wget "http://arms-apm-cn-beijing.oss-cn-beijing.aliyuncs.com/instgo/instgo-darwin-amd64" -O instgo
wget "http://arms-apm-cn-beijing.oss-cn-beijing-internal.aliyuncs.com/instgo/instgo-darwin-amd64" -O instgo
華北3(張家口)
wget "http://arms-apm-cn-zhangjiakou.oss-cn-zhangjiakou.aliyuncs.com/instgo/instgo-darwin-amd64" -O instgo
wget "http://arms-apm-cn-zhangjiakou.oss-cn-zhangjiakou-internal.aliyuncs.com/instgo/instgo-darwin-amd64" -O instgo
華北5(呼和浩特)
wget "http://arms-apm-cn-huhehaote.oss-cn-huhehaote.aliyuncs.com/instgo/instgo-darwin-amd64" -O instgo
wget "http://arms-apm-cn-huhehaote.oss-cn-huhehaote-internal.aliyuncs.com/instgo/instgo-darwin-amd64" -O instgo
華北6(烏蘭察布)
wget "http://arms-apm-cn-wulanchabu.oss-cn-wulanchabu.aliyuncs.com/instgo/instgo-darwin-amd64" -O instgo
wget "http://arms-apm-cn-wulanchabu.oss-cn-wulanchabu-internal.aliyuncs.com/instgo/instgo-darwin-amd64" -O instgo
華南1(深圳)
wget "http://arms-apm-cn-shenzhen.oss-cn-shenzhen.aliyuncs.com/instgo/instgo-darwin-amd64" -O instgo
wget "http://arms-apm-cn-shenzhen.oss-cn-shenzhen-internal.aliyuncs.com/instgo/instgo-darwin-amd64" -O instgo
華南2(河源)
wget "http://arms-apm-cn-heyuan.oss-cn-heyuan.aliyuncs.com/instgo/instgo-darwin-amd64" -O instgo
wget "http://arms-apm-cn-heyuan.oss-cn-heyuan-internal.aliyuncs.com/instgo/instgo-darwin-amd64" -O instgo
華南3(廣州)
wget "http://arms-apm-cn-guangzhou.oss-cn-guangzhou.aliyuncs.com/instgo/instgo-darwin-amd64" -O instgo
wget "http://arms-apm-cn-guangzhou.oss-cn-guangzhou-internal.aliyuncs.com/instgo/instgo-darwin-amd64" -O instgo
西南1(成都)
wget "http://arms-apm-cn-chengdu.oss-cn-chengdu.aliyuncs.com/instgo/instgo-darwin-amd64" -O instgo
wget "http://arms-apm-cn-chengdu.oss-cn-chengdu-internal.aliyuncs.com/instgo/instgo-darwin-amd64" -O instgo
中國(香港)
wget "http://arms-apm-cn-hongkong.oss-cn-hongkong.aliyuncs.com/instgo/instgo-darwin-amd64" -O instgo
wget "http://arms-apm-cn-hongkong.oss-cn-hongkong-internal.aliyuncs.com/instgo/instgo-darwin-amd64" -O instgo
新加坡
wget "http://arms-apm-ap-southeast-1.oss-ap-southeast-1.aliyuncs.com/instgo/instgo-darwin-amd64" -O instgo
wget "http://arms-apm-ap-southeast-1.oss-ap-southeast-1-internal.aliyuncs.com/instgo/instgo-darwin-amd64" -O instgo
亞太地區東南3(吉隆坡)
wget "http://arms-apm-ap-southeast-3.oss-ap-southeast-3.aliyuncs.com/instgo/instgo-darwin-amd64" -O instgo
wget "http://arms-apm-ap-southeast-3.oss-ap-southeast-3-internal.aliyuncs.com/instgo/instgo-darwin-amd64" -O instgo
亞太地區東南5(雅加達)
wget "http://arms-apm-ap-southeast-5.oss-ap-southeast-5.aliyuncs.com/instgo/instgo-darwin-amd64" -O instgo
wget "http://arms-apm-ap-southeast-5.oss-ap-southeast-5-internal.aliyuncs.com/instgo/instgo-darwin-amd64" -O instgo
亞太地區東北1(東京)
wget "http://arms-apm-ap-northeast-1.oss-ap-northeast-1.aliyuncs.com/instgo/instgo-darwin-amd64" -O instgo
wget "http://arms-apm-ap-northeast-1.oss-ap-northeast-1-internal.aliyuncs.com/instgo/instgo-darwin-amd64" -O instgo
歐洲中部1(法蘭克福)
wget "http://arms-apm-eu-central-1.oss-eu-central-1.aliyuncs.com/instgo/instgo-darwin-amd64" -O instgo
wget "http://arms-apm-eu-central-1.oss-eu-central-1-internal.aliyuncs.com/instgo/instgo-darwin-amd64" -O instgo
歐洲西部1(倫敦)
wget "http://arms-apm-eu-west-1.oss-eu-west-1.aliyuncs.com/instgo/instgo-darwin-amd64" -O instgo
wget "http://arms-apm-eu-west-1.oss-eu-west-1-internal.aliyuncs.com/instgo/instgo-darwin-amd64" -O instgo
美國東部1(維吉尼亞)
wget "http://arms-apm-us-east-1.oss-us-east-1.aliyuncs.com/instgo/instgo-darwin-amd64" -O instgo
wget "http://arms-apm-us-east-1.oss-us-east-1-internal.aliyuncs.com/instgo/instgo-darwin-amd64" -O instgo
美國西部1(矽谷)
wget "http://arms-apm-us-west-1.oss-us-west-1.aliyuncs.com/instgo/instgo-darwin-amd64" -O instgo
wget "http://arms-apm-us-west-1.oss-us-west-1-internal.aliyuncs.com/instgo/instgo-darwin-amd64" -O instgo
華東1金融雲
無
wget "http://arms-apm-cn-hangzhou-finance.oss-cn-hzjbp-b-internal.aliyuncs.com/instgo/instgo-darwin-amd64" -O instgo
華東2金融雲
無
wget "http://arms-apm-cn-shanghai-finance-1.oss-cn-shanghai-finance-1-internal.aliyuncs.com/instgo/instgo-darwin-amd64" -O instgo
華南1金融雲
無
wget "http://arms-apm-cn-shenzhen-finance-1.oss-cn-shenzhen-finance-1-internal.aliyuncs.com/instgo/instgo-darwin-amd64" -O instgo
政務雲
wget "http://arms-apm-cn-north-2-gov-1.oss-cn-north-2-gov-1.aliyuncs.com/instgo/instgo-darwin-amd64" -O instgo
wget "http://arms-apm-cn-north-2-gov-1.oss-cn-north-2-gov-1-internal.aliyuncs.com/instgo/instgo-darwin-amd64" -O instgo
Windows(AMD64)
地區
公網地址
VPC地址
華東1(杭州)
wget "http://arms-apm-cn-hangzhou.oss-cn-hangzhou.aliyuncs.com/instgo/instgo-windows-amd64.exe" -O instgo.exe
wget "http://arms-apm-cn-hangzhou.oss-cn-hangzhou-internal.aliyuncs.com/instgo/instgo-windows-amd64.exe" -O instgo.exe
華東2(上海)
wget "http://arms-apm-cn-shanghai.oss-cn-shanghai.aliyuncs.com/instgo/instgo-windows-amd64.exe" -O instgo.exe
wget "http://arms-apm-cn-shanghai.oss-cn-shanghai-internal.aliyuncs.com/instgo/instgo-windows-amd64.exe" -O instgo.exe
華北1(青島)
wget "http://arms-apm-cn-qingdao.oss-cn-qingdao.aliyuncs.com/instgo/instgo-windows-amd64.exe" -O instgo.exe
wget "http://arms-apm-cn-qingdao.oss-cn-qingdao-internal.aliyuncs.com/instgo/instgo-windows-amd64.exe" -O instgo.exe
華北2(北京)
wget "http://arms-apm-cn-beijing.oss-cn-beijing.aliyuncs.com/instgo/instgo-windows-amd64.exe" -O instgo.exe
wget "http://arms-apm-cn-beijing.oss-cn-beijing-internal.aliyuncs.com/instgo/instgo-windows-amd64.exe" -O instgo.exe
華北3(張家口)
wget "http://arms-apm-cn-zhangjiakou.oss-cn-zhangjiakou.aliyuncs.com/instgo/instgo-windows-amd64.exe" -O instgo.exe
wget "http://arms-apm-cn-zhangjiakou.oss-cn-zhangjiakou-internal.aliyuncs.com/instgo/instgo-windows-amd64.exe" -O instgo.exe
華北5(呼和浩特)
wget "http://arms-apm-cn-huhehaote.oss-cn-huhehaote.aliyuncs.com/instgo/instgo-windows-amd64.exe" -O instgo.exe
wget "http://arms-apm-cn-huhehaote.oss-cn-huhehaote-internal.aliyuncs.com/instgo/instgo-windows-amd64.exe" -O instgo.exe
華北6(烏蘭察布)
wget "http://arms-apm-cn-wulanchabu.oss-cn-wulanchabu.aliyuncs.com/instgo/instgo-windows-amd64.exe" -O instgo.exe
wget "http://arms-apm-cn-wulanchabu.oss-cn-wulanchabu-internal.aliyuncs.com/instgo/instgo-windows-amd64.exe" -O instgo.exe
華南1(深圳)
wget "http://arms-apm-cn-shenzhen.oss-cn-shenzhen.aliyuncs.com/instgo/instgo-windows-amd64.exe" -O instgo.exe
wget "http://arms-apm-cn-shenzhen.oss-cn-shenzhen-internal.aliyuncs.com/instgo/instgo-windows-amd64.exe" -O instgo.exe
華南2(河源)
wget "http://arms-apm-cn-heyuan.oss-cn-heyuan.aliyuncs.com/instgo/instgo-windows-amd64.exe" -O instgo.exe
wget "http://arms-apm-cn-heyuan.oss-cn-heyuan-internal.aliyuncs.com/instgo/instgo-windows-amd64.exe" -O instgo.exe
華南3(廣州)
wget "http://arms-apm-cn-guangzhou.oss-cn-guangzhou.aliyuncs.com/instgo/instgo-windows-amd64.exe" -O instgo.exe
wget "http://arms-apm-cn-guangzhou.oss-cn-guangzhou-internal.aliyuncs.com/instgo/instgo-windows-amd64.exe" -O instgo.exe
西南1(成都)
wget "http://arms-apm-cn-chengdu.oss-cn-chengdu.aliyuncs.com/instgo/instgo-windows-amd64.exe" -O instgo.exe
wget "http://arms-apm-cn-chengdu.oss-cn-chengdu-internal.aliyuncs.com/instgo/instgo-windows-amd64.exe" -O instgo.exe
中國(香港)
wget "http://arms-apm-cn-hongkong.oss-cn-hongkong.aliyuncs.com/instgo/instgo-windows-amd64.exe" -O instgo.exe
wget "http://arms-apm-cn-hongkong.oss-cn-hongkong-internal.aliyuncs.com/instgo/instgo-windows-amd64.exe" -O instgo.exe
新加坡
wget "http://arms-apm-ap-southeast-1.oss-ap-southeast-1.aliyuncs.com/instgo/instgo-windows-amd64.exe" -O instgo.exe
wget "http://arms-apm-ap-southeast-1.oss-ap-southeast-1-internal.aliyuncs.com/instgo/instgo-windows-amd64.exe" -O instgo.exe
亞太地區東南3(吉隆坡)
wget "http://arms-apm-ap-southeast-3.oss-ap-southeast-3.aliyuncs.com/instgo/instgo-windows-amd64.exe" -O instgo.exe
wget "http://arms-apm-ap-southeast-3.oss-ap-southeast-3-internal.aliyuncs.com/instgo/instgo-windows-amd64.exe" -O instgo.exe
亞太地區東南5(雅加達)
wget "http://arms-apm-ap-southeast-5.oss-ap-southeast-5.aliyuncs.com/instgo/instgo-windows-amd64.exe" -O instgo.exe
wget "http://arms-apm-ap-southeast-5.oss-ap-southeast-5-internal.aliyuncs.com/instgo/instgo-windows-amd64.exe" -O instgo.exe
亞太地區東北1(東京)
wget "http://arms-apm-ap-northeast-1.oss-ap-northeast-1.aliyuncs.com/instgo/instgo-windows-amd64.exe" -O instgo.exe
wget "http://arms-apm-ap-northeast-1.oss-ap-northeast-1-internal.aliyuncs.com/instgo/instgo-windows-amd64.exe" -O instgo.exe
歐洲中部1(法蘭克福)
wget "http://arms-apm-eu-central-1.oss-eu-central-1.aliyuncs.com/instgo/instgo-windows-amd64.exe" -O instgo.exe
wget "http://arms-apm-eu-central-1.oss-eu-central-1-internal.aliyuncs.com/instgo/instgo-windows-amd64.exe" -O instgo.exe
歐洲西部1(倫敦)
wget "http://arms-apm-eu-west-1.oss-eu-west-1.aliyuncs.com/instgo/instgo-windows-amd64.exe" -O instgo.exe
wget "http://arms-apm-eu-west-1.oss-eu-west-1-internal.aliyuncs.com/instgo/instgo-windows-amd64.exe" -O instgo.exe
美國東部1(維吉尼亞)
wget "http://arms-apm-us-east-1.oss-us-east-1.aliyuncs.com/instgo/instgo-windows-amd64.exe" -O instgo.exe
wget "http://arms-apm-us-east-1.oss-us-east-1-internal.aliyuncs.com/instgo/instgo-windows-amd64.exe" -O instgo.exe
美國西部1(矽谷)
wget "http://arms-apm-us-west-1.oss-us-west-1.aliyuncs.com/instgo/instgo-windows-amd64.exe" -O instgo.exe
wget "http://arms-apm-us-west-1.oss-us-west-1-internal.aliyuncs.com/instgo/instgo-windows-amd64.exe" -O instgo.exe
華東1金融雲
無
wget "http://arms-apm-cn-hangzhou-finance.oss-cn-hzjbp-b-internal.aliyuncs.com/instgo/instgo-windows-amd64.exe" -O instgo.exe
華東2金融雲
無
wget "http://arms-apm-cn-shanghai-finance-1.oss-cn-shanghai-finance-1-internal.aliyuncs.com/instgo/instgo-windows-amd64.exe" -O instgo.exe
華南1金融雲
無
wget "http://arms-apm-cn-shenzhen-finance-1.oss-cn-shenzhen-finance-1-internal.aliyuncs.com/instgo/instgo-windows-amd64.exe" -O instgo.exe
政務雲
wget "http://arms-apm-cn-north-2-gov-1.oss-cn-north-2-gov-1.aliyuncs.com/instgo/instgo-windows-amd64.exe" -O instgo.exe
wget "http://arms-apm-cn-north-2-gov-1.oss-cn-north-2-gov-1-internal.aliyuncs.com/instgo/instgo-windows-amd64.exe" -O instgo.exe
為編譯工具賦予可執行許可權。
Linux/Darwin
# 賦予可執行許可權 chmod +x instgo
Windows
Windows中無需賦予可執行許可權。
(可選)擷取LicenseKey並配置編譯參數。
重要如果您跳過該步,instgo會進入dev模式,並預設為您安裝最新版本的ARMS探針。如果您需要在生產環境中部署,建議配置以下參數。
您可以通過OpenAPI擷取LicenseKey,具體方法,參見DescribeTraceLicenseKey - 列出LicenseKey。
擷取LicenseKey後使用
set
命令配置編譯參數。instgo set --licenseKey=${YourLicenseKey} --regionId=${YourRegionId} --dev=false
將instgo作為首碼添加到您原有的編譯命令前並執行編譯。
instgo go build {arg1} {arg2} {arg3}
使用上一步編譯的二進位檔案構建鏡像。
相關資訊
初次編譯時間,探針會預設被下載到
/opt
目錄下(Windows為C:\ProgramData
),如果該目錄沒有許可權,可以使用--cacheDir
flag指定緩衝目錄,或使用sudo -E
命令執行編譯(Windows請使用管理員權限執行編譯命令)。編譯過程中如果強制退出或出現異常退出,可能會存在編譯殘留。清理Golang探針編譯殘留的方法,請參見清理Golang探針編譯殘留。
步驟三:授予ARMS資源的存取權限
ACK託管叢集
如果ACK託管叢集中不存在ARMS Addon Token,請執行以下操作手動為叢集授予ARMS資源的存取權限。如果已經存在ARMS Addon Token,請跳轉至步驟四。
查看叢集是否存在ARMS Addon Token。
登入Container Service管理主控台,在叢集列表頁面,單擊目的地組群名稱進入叢集詳情頁。
在左側導覽列選擇組態管理 > 保密字典,然後在頂部選擇命名空間為kube-system,查看addon.arms.token是否存在。
叢集存在ARMS Addon Token時,ARMS會進行免密授權。Kubernetes託管版叢集預設存在ARMS Addon Token,但對於部分早期建立的Kubernetes託管版叢集,可能會存在沒有ARMS Addon Token的情況,因此,對於Kubernetes託管版叢集,建議首先檢查ARMS Addon Token是否存在。若不存在,需進行手動授權。
手動添加權限原則。
登入Container Service管理主控台,在叢集列表頁面單擊目的地組群名稱。
在叢集資訊 > 基本資料頁簽的叢集資源地區,單擊Worker RAM角色右側的連結。
在許可權管理頁簽單擊新增授權。
在新增授權面板添加以下兩個權限原則,然後單擊確認新增授權。
AliyunTracingAnalysisFullAccess:Managed Service for OpenTelemetry的完整許可權。
AliyunARMSFullAccess:ARMS的完整許可權。
專有版叢集/註冊叢集
如果需要監控ACK專有版叢集和ACK One註冊叢集應用,請確認對應的阿里雲帳號已包含AliyunARMSFullAccess和AliyunSTSAssumeRoleAccess許可權。添加許可權的操作,請參見為RAM使用者授權。
安裝ack-onepilot組件後,還需要在ack-onepilot中填寫有ARMS許可權的阿里雲帳號AK/SK。
在左側導覽列選擇應用 > Helm頁面,單擊ack-onepilot組件右側的更新。
將
accessKey
和accessKeySecret
替換為當前帳號的AccessKey,然後單擊確定。說明擷取AccessKey的操作,請參見建立AccessKey。
為降低AccessKey泄露的風險,阿里雲帳號(主帳號)的AccessKey Secret只在建立時顯示,後續不支援查看,請妥善保管。
重啟應用Deployment。
ASK/ECI叢集
如果需監控ACK Serverless叢集或對接了ECI的叢集應用,請在雲資源訪問授權頁面完成授權,然後重啟ack-onepilot組件下的所有Pod。
步驟四:為Go應用開啟ARMS應用監控
建立一個無狀態(Deployment)應用並開啟ARMS應用監控的完整YAML樣本模板如下:
展開查看完整樣本YAML檔案(Golang)
apiVersion: apps/v1
kind: Deployment
metadata:
labels:
app: otel-go-client
name: otel-go-client
namespace: default
spec:
progressDeadlineSeconds: 600
replicas: 1
revisionHistoryLimit: 10
selector:
matchLabels:
app: otel-go-client
strategy:
rollingUpdate:
maxSurge: 25%
maxUnavailable: 25%
type: RollingUpdate
template:
metadata:
labels:
aliyun.com/app-language: golang
armsPilotAutoEnable: 'on'
armsPilotCreateAppName: otel-go-client
app: otel-go-client
spec:
containers:
- image: registry.cn-hangzhou.aliyuncs.com/private-mesh/hellob:otel-client-arms-go-test-0.0.1
imagePullPolicy: Always
name: client
resources:
requests:
cpu: 250m
memory: 300Mi
terminationMessagePath: /dev/termination-log
terminationMessagePolicy: File
dnsPolicy: ClusterFirst
restartPolicy: Always
schedulerName: default-scheduler
securityContext: {}
terminationGracePeriodSeconds: 30
---
apiVersion: apps/v1
kind: Deployment
metadata:
labels:
app: otel-go-server
name: otel-go-server
namespace: default
spec:
progressDeadlineSeconds: 600
replicas: 1
revisionHistoryLimit: 10
selector:
matchLabels:
app: otel-go-server
strategy:
rollingUpdate:
maxSurge: 25%
maxUnavailable: 25%
type: RollingUpdate
template:
metadata:
labels:
app: otel-go-server
aliyun.com/app-language: golang
armsPilotAutoEnable: 'on'
armsPilotCreateAppName: otel-go-server
spec:
containers:
- image: registry.cn-hangzhou.aliyuncs.com/private-mesh/hellob:otel-server-arms-go-test-0.0.1
imagePullPolicy: Always
name: server
resources:
requests:
cpu: 250m
memory: 300Mi
terminationMessagePath: /dev/termination-log
terminationMessagePolicy: File
dnsPolicy: ClusterFirst
restartPolicy: Always
schedulerName: default-scheduler
securityContext: {}
terminationGracePeriodSeconds: 30
---
apiVersion: v1
kind: Service
metadata:
labels:
app: otel-go-server
name: otel-server
namespace: default
spec:
internalTrafficPolicy: Cluster
ipFamilies:
- IPv4
ipFamilyPolicy: SingleStack
ports:
- name: http
port: 9000
protocol: TCP
targetPort: 9000
selector:
app: otel-go-server
sessionAffinity: None
type: ClusterIP
登入Container Service管理主控台,在左側導覽列選擇叢集列表。
在叢集列表頁面左側頂部,選擇目的地組群所在的資源群組和地區,單擊目的地組群名稱,然後在左側導覽列,單擊工作負載,然後選擇無狀態、有狀態或守護進程集。
在目標應用右側選擇更多 > 查看Yaml。
如需建立一個新應用,單擊使用YAML建立資源。
在YAML檔案中將以下
labels
添加到spec.template.metadata層級下。labels: aliyun.com/app-language: golang # Go應用必填,標明此應用是Go應用。 armsPilotAutoEnable: 'on' armsPilotCreateAppName: "<your-deployment-name>" #請將<your-deployment-name>替換為您的應用程式名稱。
執行結果
約一分鐘後,若Golang應用出現在ARMS控制台的應用監控 > 應用列表頁面中且有資料上報,則說明接入成功。