运行 sudo apt-get update 时出现错误

运行 sudo apt-get update 时出现错误

每当我运行时$ sudo apt-get update,都会出现以下错误。

$ sudo apt-get update
Hit:1 http://download.virtualbox.org/virtualbox/debian xenial InRelease
Hit:2 http://archive.canonical.com/ubuntu xenial InRelease                                                                                     
Hit:3 http://ppa.launchpad.net/martin-frost/thoughtbot-rcm/ubuntu xenial InRelease                                                             
Hit:4 http://in.archive.ubuntu.com/ubuntu xenial InRelease                                                                                     
Get:5 http://security.ubuntu.com/ubuntu xenial-security InRelease [94.5 kB]                                                                    
Hit:6 http://ppa.launchpad.net/ubuntu-lxc/lxd-stable/ubuntu xenial InRelease                                                                   
Hit:7 http://in.archive.ubuntu.com/ubuntu xenial-updates InRelease                                                                             
Ign:8 http://linux.dropbox.com/ubuntu wily InRelease                                                                                           
Hit:10 http://in.archive.ubuntu.com/ubuntu xenial-backports InRelease                                                                          
Get:11 http://linux.dropbox.com/ubuntu wily Release [6,596 B]                                                                                  
Hit:12 http://repository.spotify.com stable InRelease                                                                                          
Ign:9 http://toolbelt.heroku.com/ubuntu ./ InRelease                                                                                           
Hit:14 http://toolbelt.heroku.com/ubuntu ./ Release                                                               
Ign:16 http://dl.google.com/linux/chrome-remote-desktop/deb stable InRelease
Ign:17 http://dl.google.com/linux/chrome/deb stable InRelease
Hit:18 http://dl.google.com/linux/chrome-remote-desktop/deb stable Release
Hit:19 http://dl.google.com/linux/chrome/deb stable Release
Hit:22 https://apt.dockerproject.org/repo ubuntu-xenial InRelease
Fetched 101 kB in 5s (17.0 kB/s)
Reading package lists... Done
N: Skipping acquire of configured file 'main/binary-i386/Packages' as repository 'http://dl.google.com/linux/chrome-remote-desktop/deb stable InRelease' doesn't support architecture 'i386'

chrome 是这里的流氓 repo。我发现问题和这个和我遇到的问题类似

我尝试过

正如其中一个答案所建议的那样,我尝试运行

$ cd /var/lib/dpkg/updates && sudo rm * 
$ sudo apt-get update

以及检查文件/etc/apt/sources.list.d

$ cat /etc/apt/sources.list.d/google-chrome.list
### THIS FILE IS AUTOMATICALLY CONFIGURED ###
# You may comment out this entry, but any other modifications may be lost.
deb [arch=amd64] http://dl.google.com/linux/chrome/deb/ stable main

我的建筑

$ uname -a
Linux Acer 4.4.0-24-generic #43-Ubuntu SMP Wed Jun 8 19:27:37 UTC 2016 x86_64 x86_64 x86_64 GNU/Linux
$ google-chrome --version
Google Chrome 51.0.2704.106

答案1

我也遇到了同样的问题。下面是我修复它的方法:

  1. 首先,我执行了这个 shell 命令来添加[架构=amd64]回到Chrome 远程桌面存储库文件:

    sudo sed -i -e 's/deb http/deb [arch=amd64] http/' "/etc/apt/sources.list.d/chrome-remote-desktop.list"
    
  2. 然后我又对Chrome 远程桌面cron文件:

    sudo sed -i -e 's/deb http/deb [arch=amd64] http/' "/etc/cron.daily/chrome-remote-desktop"
    
  3. 完成此操作后,我再次执行了 APT,以确保一切恢复正常:

    sudo apt-get update ; sudo apt-get check
    

答案2

我必须手动从文件中删除谷歌源,/etc/apt/sources.list.d然后卸载谷歌浏览器

$ sudo apt-get purge chromium-browser

从他们的网站再次下载了谷歌浏览器,一切恢复正常。

答案3

您可以尝试:1. 重启计算机,然后重试。2. 卸载 chrome,运行更新,重新安装 chrome。为确保万无一失,我会按以下方式操作:

 sudo apt-get remove google-chrome-stable
 sudo apt-get update
 sudo apt-get upgrade
 sudo apt-get autoremove
 sudo apt-get update
 sudo apt-get install google-chrome-stable

如果您想保留您的设置,您只需在浏览器上登录您的谷歌帐户即可。

相关内容