小编Dan*_*ser的帖子

apt.conf "Acquire::http:Proxy "proxyserver:port" 似乎没有被使用(Win7 上的 Virtual Box 下的 Ubuntu 13.04)

这是用于在 VirtualBox VM 中安装 Ubuntu 13.04 Desktop。我在公司网络上,在 xyz251:9090 处有一个 HTTP 代理。我已经使用自动配置脚本配置了来宾操作系统,因此 Firefox 工作正常,但我无法使用代理连接“apt-get”或“Ubuntu 软件中心”。

我创建了文件“/etc/apt/apt.conf”,它现在包含一行文本:

Acquire::http:Proxy "http://x.y.z.251:9090"
Run Code Online (Sandbox Code Playgroud)

这是我在“系统设置/网络/网络代理”中指定并应用于整个系统的 proxy.pac 文件。

当我使用 Firefox 时,数据包跟踪显示 TCP 连接是通过公司代理在端口 9090 上完成的,当我运行“Ubuntu 软件中心”和“apt-get”时,数据包跟踪显示具有最终目标 IP 的 TCP SYN 数据包地址和端口 80。当然,对 SYN 数据包没有响应,因为公司防火墙阻止了端口 80 上的 TCP 连接进出。

在终端窗口中使用“sudo apt-get”,我总是看到:

Ign cdrom://Ubuntu 13.04 _Raring Ringtail_ - Release amd64 (20130424) raring/main Translation-en_US
Ign cdrom://Ubuntu 13.04 _Raring Ringtail_ - Release amd64 (20130424) raring/main Translation-en
Ign cdrom://Ubuntu 13.04 _Raring Ringtail_ - Release amd64 (20130424) raring/restricted Translation-en_US
Ign cdrom://Ubuntu 13.04 _Raring Ringtail_ …
Run Code Online (Sandbox Code Playgroud)

software-center apt networking proxy virtualbox-networking

13
推荐指数
2
解决办法
24万
查看次数