root@ecs-:/home/workspaces/tx# git pull

ssh: Could not resolve hostname **.com: Temporary failure in name resolution

fatal: Could not read from remote repository.


Please make sure you have the correct access rights

and the repository exists.


安装了华为云服务器之后,发现ddos攻击不少,凌晨磁盘读写几兆每秒,于是设立了安全组。

后来发现git pull命令出现了如上的异常。

最后试了一下,error描述,ssh could not resolve hostname了,所以要开放ssh的tcp端口,不仅出方向要设立,入方向也要放开。