apt-get 업데이트가 서버에 연결할 수 없습니다

apt-get 업데이트가 서버에 연결할 수 없습니다

Ubuntu 15.04에서 업데이트를 받으려고 하는데 서버에 연결하지 못한 경우

me@me:~$ sudo apt-get update 
Err http://archive.ubuntu.com vivid InRelease
Err http://archive.ubuntu.com vivid-updates InRelease
Err http://archive.ubuntu.com vivid-backports InRelease
Err http://archive.ubuntu.com vivid-security InRelease
Err http://archive.ubuntu.com vivid Release.gpg
  Unable to connect to 54.86.15.42:8080:
Err http://archive.ubuntu.com vivid-updates Release.gpg
  Unable to connect to 54.86.15.42:8080:
Err http://archive.ubuntu.com vivid-backports Release.gpg
  Unable to connect to 54.86.15.42:8080:
Err http://archive.ubuntu.com vivid-security Release.gpg
  Unable to connect to 54.86.15.42:8080:
Reading package lists... Done
W: Failed to fetch http://archive.ubuntu.com/ubuntu/dists/vivid/InRelease  
W: Failed to fetch http://archive.ubuntu.com/ubuntu/dists/vivid-updates/InRelease  
W: Failed to fetch http://archive.ubuntu.com/ubuntu/dists/vivid-backports/InRelease  
W: Failed to fetch http://archive.ubuntu.com/ubuntu/dists/vivid-security/InRelease  
W: Failed to fetch http://archive.ubuntu.com/ubuntu/dists/vivid/Release.gpg  Unable to connect to 54.86.15.42:8080:
W: Failed to fetch http://archive.ubuntu.com/ubuntu/dists/vivid-updates/Release.gpg  Unable to connect to 54.86.15.42:8080:
W: Failed to fetch http://archive.ubuntu.com/ubuntu/dists/vivid-backports/Release.gpg  Unable to connect to 54.86.15.42:8080:
W: Failed to fetch http://archive.ubuntu.com/ubuntu/dists/vivid-security/Release.gpg  Unable to connect to 54.86.15.42:8080:
W: Some index files failed to download. They have been ignored, or old ones used instead

해결책을 찾으려고 노력했지만 해결할 수 없습니다. 지금까지 시도한 내용은 다음과 같습니다.

  1. 다음으로 수정 /etc/resolv.conf:

    nameserver 8.8.8.8
    nameserver 8.8.8.4
    
  2. Ubuntu 서버에 ping을 시도했습니다.

    me@me:~$ ping archive.ubuntu.com
    PING archive.ubuntu.com (91.189.91.15) 56(84) bytes of data.
    64 bytes from likho.canonical.com (91.189.91.15): icmp_seq=1 ttl=41 time=259 ms
    64 bytes from likho.canonical.com (91.189.91.15): icmp_seq=2 ttl=41 time=257 ms
    64 bytes from likho.canonical.com (91.189.91.15): icmp_seq=3 ttl=41 time=255 ms
    64 bytes from likho.canonical.com (91.189.91.15): icmp_seq=4 ttl=41 time=288 ms
    ^C
    --- archive.ubuntu.com ping statistics ---
    4 packets transmitted, 4 received, 0% packet loss, time 3003ms
    rtt min/avg/max/mdev = 255.160/265.270/288.347/13.437 ms
    
  3. 소프트웨어 및 업데이트에서 서버를 주 서버로 변경합니다.

  4. 나는 /etc/apt/apt.conf다음 줄을 찾았습니다.

    Acquire::http::proxy 54.86.15.42:8080
    

    #앞에 추가하려고 했는데 작동하지 않았습니다. 그런 다음 54.86.15.42:8080에 연결을 시도하면 아무 일도 일어나지 않습니다. 그리고 다음 주소로 ping을 보냅니다.

    me@me:~$ sudo ping 54.86.15.42
    PING 54.86.15.42 (54.86.15.42) 56(84) bytes of data.
    ^C
    --- 54.86.15.42 ping statistics ---
    16 packets transmitted, 0 received, 100% packet loss, time 14999ms
    

프록시나 방화벽과 관련된 것 같지만 저는 전혀 사용하지 않습니다. 이 문제를 해결하는 방법을 아는 사람이 있나요?

답변1

내 문제가 해결되었습니다. 무엇이 다시 작동하는지 모르겠습니다. 나는 @nilesh_101이 제안한 대로 이 명령을 시도 unset http_proxy했습니다 unset https_proxy. 내가 한 또 하나의 일은 프록시를 변경한 다음 다시 기본값으로 변경하는 것입니다. 제 질문에 답변해 주신 모든 분들께 감사드립니다!

답변2

같은 문제가 발생했습니다. 그런 다음 apt.conf 파일의 모든 내용을 지우면 완벽하게 작동합니다.

관련 정보