首页 > 代码库 > ubuntu 更显列表 [Connecting to archive.ubuntu.com (2001:67c:1360:8001::21)] 超时的解决方法

ubuntu 更显列表 [Connecting to archive.ubuntu.com (2001:67c:1360:8001::21)] 超时的解决方法

问题描述:

   在使用apt-get update 时更行列表,显示[Connecting to archive.ubuntu.com (2001:67c:1360:8001::21)]超时

分析: 

  我已更改为ubuntu的阿里云,不应该出现访问不了的情况,通过搜索,得知原因如下
ubuntu默认走ipv6,但是我更改的阿里源应该不支持ipv6.

解决方法:

 打开/etc/gai.conf(地址信息的配置文件),找到#precedence ::ffff:0:0/96  100, 将"#" 去掉保存,就行了。

ubuntu 更显列表 [Connecting to archive.ubuntu.com (2001:67c:1360:8001::21)] 超时的解决方法