sudo apt-get update не работает. Err: 1 http://archive.ubuntu.com/ubuntu bionic InRelease

Я пытался установить пакет «httpd» в Ubuntu, но это всегда терпело неудачу. Я прочитал много руководств о том, как установить «Apache» на свой компьютер. Я обнаружил, что после выполнения этих обучающих операций мой компьютер не смог выполнить sudo apt-get update .

Я пробовал много решений из Интернета

"This is the history of command line argument"

  799  sudo ufw default deny incoming
  800  sudo ufw default allow outgoing
  801  sudo ufw allow ssh
  802  sudo ufw allow 2222
  803  sudo ufw allow http
  804  sudo ufw allow 80
  805  sudo ufw allow https
  806  sudo ufw allow 443
  807  sudo ufw deny from 203.0.123.5
  808  sudo ufw enable
  809  sudo ufw status verbose
  810  sudo ufw status
  811  sudo ufw allow 'OpenSSH'
  812  sudo ufw status
  813  sudo systemctl start apache2.service
  814  ls
  815  yum install httpd
  816  sudo yum install httpd
  817  sudo systemctl start apache2.service
  818  cat /etc/redhat-release
  819  sudo apt-get update
  820  echo "nameserver 8.8.8.8" | sudo tee /etc/resolv.conf > /dev/null
  821  sudo apt-get update
  822  sudo nano /etc/apt/sources.list
  823  #deb http://archive.ubuntu.com/ubuntu/
  824  sudo apt-get update && sudo apt-get upgrade
  825  apt-get clean
  826  sudo apt-get clean
  827  sudo apt-get update
  828  ls
  829  cd ..
  830  ls
  831  cd etc
  832  ls
  833  cat resolv.conf
  834  sudo ufw default allow incoming
  835  sudo apt-get update
  836  sudo ufw status
  837  history
  838  sudo systemctl stop apache2.service
  839  echo "nameserver 8.8.8.8" | sudo tee /etc/resolvconf/resolv.conf.d/base > /dev/null
  840  cd ~
  841  echo "nameserver 8.8.8.8" | sudo tee /etc/resolvconf/resolv.conf.d/base > /dev/null
  842  echo "nameserver 208.67.222.222" | sudo tee /etc/resolvconf/resolv.conf.d/base > /dev/null
  843  clean
  844  clear
  845  sudo apt-get update
  846  /etc/network/interfaces.d/50-cloud-init.cfg
  847  /etc/network/interfaces
  848  sudo /etc/network/interfaces
  849  sudo apt-get /etc/network/interfaces
  850  sudo rm /var/lib/apt/lists/* -vf
  851  sudo apt-get update
  852  history
Err:1 http://archive.ubuntu.com/ubuntu bionic InRelease                  
  Temporary failure resolving 'archive.ubuntu.com'
Err:2 http://security.ubuntu.com/ubuntu bionic-security InRelease        
  Temporary failure resolving 'security.ubuntu.com'
Err:3 http://archive.ubuntu.com/ubuntu bionic-updates InRelease
  Temporary failure resolving 'archive.ubuntu.com'
Err:4 http://archive.ubuntu.com/ubuntu bionic-backports InRelease
  Temporary failure resolving 'archive.ubuntu.com'
Reading package lists... Done        
W: Failed to fetch http://archive.ubuntu.com/ubuntu/dists/bionic/InRelease  Temporary failure resolving 'archive.ubuntu.com'
W: Failed to fetch http://archive.ubuntu.com/ubuntu/dists/bionic-updates/InRelease  Temporary failure resolving 'archive.ubuntu.com'
W: Failed to fetch http://archive.ubuntu.com/ubuntu/dists/bionic-backports/InRelease  Temporary failure resolving 'archive.ubuntu.com'
W: Failed to fetch http://security.ubuntu.com/ubuntu/dists/bionic-security/InRelease  Temporary failure resolving 'security.ubuntu.com'
W: Some index files failed to download. They have been ignored, or old ones used instead.
0
задан 23 March 2020 в 00:07

1 ответ

та же проблема; мое решение:

DNS Server has changed...

sudo nano /etc/netplan/50-xxxx-yyyyy.yaml

-->   addresses: [1.1.1.1,8.8.8.8,xx.xxx.xx.xxx]

sudo netplan --debug apply
-1
ответ дан 13 January 2021 в 13:56

Другие вопросы по тегам:

Похожие вопросы: