Erro 404 não encontrado ao usar 'sudo apt-get update'

1

Eu sou novo no Ubuntu. Estou usando o Ubuntu 14.04.02 LTS dentro do VMware. Como estou atrás de um firewall de rede, editei o arquivo apt.conf para que o apt-get funcione atrás de um servidor proxy, e tudo bem. Mas quando eu faço

sudo apt-get update

Eu recebo o seguinte:

Ign http://security.ubuntu.com trusty-security InRelease
Ign http://us.archive.ubuntu.com trusty InRelease                              
Ign http://extras.ubuntu.com trusty InRelease                                  
Ign http://files.ettus.com trusty InRelease                                    
Ign http://security.ubuntu.com trusty-security Release.gpg                     
Ign http://us.archive.ubuntu.com trusty-updates InRelease                      
Ign http://archive.ubuntu.com trusty InRelease                                 
Ign http://extras.ubuntu.com trusty Release.gpg                                
Ign http://files.ettus.com trusty Release.gpg                                  
Ign http://us.archive.ubuntu.com trusty-backports InRelease                    
Ign http://security.ubuntu.com trusty-security Release                         
Ign http://us.archive.ubuntu.com trusty Release.gpg                            
Ign http://extras.ubuntu.com trusty Release                                    
Ign http://files.ettus.com trusty Release                                      
Ign http://us.archive.ubuntu.com trusty-updates Release.gpg                    
Ign http://us.archive.ubuntu.com trusty-backports Release.gpg                  
Ign http://archive.ubuntu.com trusty Release.gpg                               
Ign http://us.archive.ubuntu.com trusty Release                                
Ign http://us.archive.ubuntu.com trusty-updates Release                        
Ign http://archive.ubuntu.com trusty Release                                   
Ign http://us.archive.ubuntu.com trusty-backports Release                      
Err http://archive.ubuntu.com trusty/main Sources                              
  404  Not Found
Err http://archive.ubuntu.com trusty/restricted Sources                        
  404  Not Found
Err http://archive.ubuntu.com trusty/multiverse Sources                        
  404  Not Found
Err http://files.ettus.com trusty/main amd64 Packages                          
  404  Not Found
Err http://files.ettus.com trusty/main i386 Packages                           
  404  Not Found
Err http://extras.ubuntu.com trusty/main Sources                               
  404  Not Found
Ign http://files.ettus.com trusty/main Translation-en_US                       
Ign http://files.ettus.com trusty/main Translation-en                          
Err http://extras.ubuntu.com trusty/main amd64 Packages                        
  404  Not Found
Err http://extras.ubuntu.com trusty/main i386 Packages               
  404  Not Found

... muito mais aqui ...

W: Failed to fetch http://security.ubuntu.com/ubuntu/dists/trusty-security/universe/source/Sources  404  Not Found

W: Failed to fetch http://security.ubuntu.com/ubuntu/dists/trusty-security/main/source/Sources  404  Not Found

W: Failed to fetch http://security.ubuntu.com/ubuntu/dists/trusty-security/restricted/source/Sources  404  Not Found

W: Failed to fetch http://security.ubuntu.com/ubuntu/dists/trusty-security/multiverse/source/Sources  404  Not Found

W: Failed to fetch http://security.ubuntu.com/ubuntu/dists/trusty-security/main/binary-amd64/Packages  404  Not Found

W: Failed to fetch http://security.ubuntu.com/ubuntu/dists/trusty-security/restricted/binary-amd64/Packages  404  Not Found

... e muito mais ...

Eu pesquisei on-line e descobri que alguns dos caminhos não tinham a extensão de arquivo no final. Isso é parte do problema? Como eu disse, eu sou totalmente novo no Ubuntu e ainda estou descobrindo as coisas. Como posso resolver este problema?

Eu fiz etc / apt / sources.list e recebo o seguinte:

# deb cdrom:[Ubuntu 14.04.2 LTS _Trusty Tahr_ - Release amd64 (20150218.1)]/ trusty main restricted
deb-src http://archive.ubuntu.com/ubuntu trusty main restricted multiverse #Added by software-properties

# See http://help.ubuntu.com/community/UpgradeNotes for how to upgrade to
# newer versions of the distribution.
deb http://us.archive.ubuntu.com/ubuntu/ trusty main restricted multiverse
deb-src http://us.archive.ubuntu.com/ubuntu/ trusty universe main restricted #Added by software-properties

## Major bug fix updates produced after the final release of the
## distribution.
deb http://us.archive.ubuntu.com/ubuntu/ trusty-updates main restricted multiverse
deb-src http://us.archive.ubuntu.com/ubuntu/ trusty-updates universe main restricted multiverse #Added by software-properties

## N.B. software from this repository is ENTIRELY UNSUPPORTED by the Ubuntu
## team. Also, please note that software in universe WILL NOT receive any
## review or updates from the Ubuntu security team.
deb http://us.archive.ubuntu.com/ubuntu/ trusty universe
deb http://us.archive.ubuntu.com/ubuntu/ trusty-updates universe

## N.B. software from this repository is ENTIRELY UNSUPPORTED by the Ubuntu 
## team, and may not be under a free licence. Please satisfy yourself as to 
## your rights to use the software. Also, please note that software in 
## multiverse WILL NOT receive any review or updates from the Ubuntu
## security team.

## N.B. software from this repository may not have been tested as
## extensively as that contained in the main release, although it includes
## newer versions of some applications which may provide useful features.
## Also, please note that software in backports WILL NOT receive any review
## or updates from the Ubuntu security team.
deb http://us.archive.ubuntu.com/ubuntu/ trusty-backports main restricted universe multiverse
deb-src http://us.archive.ubuntu.com/ubuntu/ trusty-backports main restricted universe multiverse #Added by software-properties

deb http://security.ubuntu.com/ubuntu trusty-security main restricted multiverse
deb-src http://security.ubuntu.com/ubuntu trusty-security universe main restricted multiverse #Added by software-properties
deb http://security.ubuntu.com/ubuntu trusty-security universe

## Uncomment the following two lines to add software from Canonical's
## 'partner' repository.
## This software is not part of Ubuntu, but is offered by Canonical and the
## respective vendors as a service to Ubuntu users.
# deb http://archive.canonical.com/ubuntu trusty partner
# deb-src http://archive.canonical.com/ubuntu trusty partner

## This software is not part of Ubuntu, but is offered by third-party
## developers who want to ship their latest software.
deb http://extras.ubuntu.com/ubuntu trusty main
deb-src http://extras.ubuntu.com/ubuntu trusty main

Eu encontrei isso resposta, mas meu arquivo sources.list nem contém a linha que precisava ser excluída, de modo que não ajudou. Eu também procurei aqui , mas isso não resolveu o meu problema. Estou perplexo com isso. Alguma sugestão? Esta é uma pergunta duplicada que não encontrei? Obrigado pela sua ajuda.

Atenciosamente, Marshall

    
por Marshall Garey 02.06.2015 / 19:52

1 resposta

0

Bem, com a ajuda de um colega, consegui que funcionasse. Houve duas coisas principais que fizemos:

(1) Definimos as configurações de proxy no arquivo de ambiente, em vez de no apt.conf (para que as configurações de proxy sejam definidas para cada aplicativo). Além disso, nós encontramos minhas configurações de proxy foram definidas errado (graças steeldriver por me pedir para checar isso).

http_proxy=<correct proxy setting>
https_proxy=<correct proxy setting>
no_proxy=<internal work website url>

A configuração no_proxy é para o site interno do meu trabalho, já que não usamos um proxy para acessá-lo, portanto, sem a variável de ambiente no_proxy, eu não conseguiria acessar o site.

(2) Eu tinha ido para o arquivo / etc / sudoers e adicionei Padrões para cada variável de ambiente após Defaults env_reset (então havia 3 linhas que eu adicionei). Acontece que isso foi quebrado; em vez disso, apenas adicionamos as 3 variáveis de ambiente na mesma linha que Defaults env_reset com env_keep, da seguinte forma:

Defaults env_reset, env_keep+=no_proxy, env_keep+=http_proxy, env_keep+=https_proxy

Com isso, essas variáveis de ambiente não desaparecem toda vez que eu usaria o sudo. Agora estou funcionando bem.

    
por Marshall Garey 16.06.2015 / 17:42