1.下载安装程序
最新连接地址:https://go.dev/dl/

wget https://go.dev/dl/go1.21.3.linux-arm64.tar.gz
wget https://go.dev/dl/go1.21.4.linux-arm64.tar.gz

2.安装程序

 rm -rf /usr/local/go && tar -C /usr/local -xzf go1.21.3.linux-arm64.tar.gz

3.Add /usr/local/go/bin to the PATH environment variable.

You can do this by adding the following line to your $HOME/.profile or /etc/profile (for a system-wide installation):

export PATH=$PATH:/usr/local/go/bin

4.检测安装版本

go version

go version go1.21.3 linux/arm64

go version

go version go1.21.4 linux/arm64
5.新机完整操作命令
wget https://go.dev/dl/go1.21.4.linux-arm64.tar.gz
tar -C /usr/local -xzf go1.21.4.linux-arm64.tar.gz
export PATH=$PATH:/usr/local/go/bin
go version

本文链接地址:https://const.net.cn/774.html

标签: none

添加新评论