【问题标题】:apt update error: The repository 'http://us.archive.ubuntu.com/ubuntu saucy Release' does not have a Release fileapt update 错误:存储库“http://us.archive.ubuntu.com/ubuntu saucy Release”没有发布文件
【发布时间】:2018-04-18 16:23:05
【问题描述】:

我在 Ubuntu 16.04 服务器上运行“sudo apt -y update”,但出现以下错误:

# apt -y update                    
Reading package lists... Done                                                                                                       
E: The repository 'http://us.archive.ubuntu.com/ubuntu saucy Release' does not have a Release file.
N: Updating from such a repository can't be done securely, and is therefore disabled by default.
N: See apt-secure(8) manpage for repository creation and user configuration details.
E: The repository 'http://us.archive.ubuntu.com/ubuntu saucy-updates Release' does not have a Release file.
N: Updating from such a repository can't be done securely, and is therefore disabled by default.
N: See apt-secure(8) manpage for repository creation and user configuration details.
root@yuyue-HP-Pro-3380-MT:/var/lib/apt# apt -y update
Get:1 http://cn.archive.ubuntu.com/ubuntu xenial InRelease [132 B]
Err:1 http://cn.archive.ubuntu.com/ubuntu xenial InRelease                                                                          
  Clearsigned file isn't valid, got 'NOSPLIT' (does the network require authentication?)
Get:2 http://cn.archive.ubuntu.com/ubuntu xenial-updates InRelease [132 B]                                                          
Err:2 http://cn.archive.ubuntu.com/ubuntu xenial-updates InRelease                                                                  
  Clearsigned file isn't valid, got 'NOSPLIT' (does the network require authentication?)
Get:3 http://cn.archive.ubuntu.com/ubuntu xenial-backports InRelease [132 B]                                                        
Err:3 http://cn.archive.ubuntu.com/ubuntu xenial-backports InRelease                                                                
  Clearsigned file isn't valid, got 'NOSPLIT' (does the network require authentication?)
Ign:4 http://us.archive.ubuntu.com/ubuntu saucy InRelease                                                                           
Hit:5 http://security.ubuntu.com/ubuntu xenial-security InRelease
Ign:6 http://us.archive.ubuntu.com/ubuntu saucy-updates InRelease
Err:7 http://us.archive.ubuntu.com/ubuntu saucy Release
  404  Not Found [IP: 2001:67c:1562::16 80]
Err:8 http://us.archive.ubuntu.com/ubuntu saucy-updates Release
  404  Not Found [IP: 2001:67c:1562::16 80]
Reading package lists... Done
E: The repository 'http://us.archive.ubuntu.com/ubuntu saucy Release' does not have a Release file.
N: Updating from such a repository can't be done securely, and is therefore disabled by default.
N: See apt-secure(8) manpage for repository creation and user configuration details.
E: The repository 'http://us.archive.ubuntu.com/ubuntu saucy-updates Release' does not have a Release file.
N: Updating from such a repository can't be done securely, and is therefore disabled by default.
N: See apt-secure(8) manpage for repository creation and user configuration details.

可能是什么原因?我该如何解决这个问题?谢谢!

【问题讨论】:

    标签: ubuntu upgrade ubuntu-16.04 apt-get apt


    【解决方案1】:

    感谢 AskUbuntu 中的@Videonauth。我在his answer 的帮助下解决了这个问题。这是我使用的命令:

    sudo -i
    
    cat > /etc/apt/sources.list << EOF
    deb http://archive.ubuntu.com/ubuntu xenial main restricted universe multiverse
    deb-src http://archive.ubuntu.com/ubuntu xenial main restricted universe multiverse
    deb http://archive.ubuntu.com/ubuntu xenial-updates main restricted universe multiverse
    deb-src http://archive.ubuntu.com/ubuntu xenial-updates main restricted universe multiverse
    deb http://archive.ubuntu.com/ubuntu xenial-backports main restricted universe multiverse
    deb-src http://archive.ubuntu.com/ubuntu xenial-backports main restricted universe multiverse
    deb http://archive.ubuntu.com/ubuntu xenial-security main restricted universe multiverse
    deb-src http://archive.ubuntu.com/ubuntu xenial-security main restricted universe multiverse
    #deb http://archive.ubuntu.com/ubuntu xenial-proposed restricted main universe multiverse
    #deb-src http://archive.ubuntu.com/ubuntu xenial-proposed restricted main universe multiverse
    deb http://archive.canonical.com/ubuntu xenial partner
    deb-src http://archive.canonical.com/ubuntu xenial partner
    EOF
    
    sudo apt clean
    sudo apt update
    sudo apt dist-upgrade
    

    【讨论】:

    • 警告所有人:在执行此命令之前备份您的/etc/apt/sources.list 的副本。它将破坏该文件中之前的所有内容。
    • 这对我不起作用,因为 sources.list 实际上只有原始安装的 cdrom 映像。 @Fithe_Xanki 上面的解决方案确实适用。
    【解决方案2】:

    我在 Ubuntu 18.04 上执行命令 'sudo apt update' 并遇到同样的错误。 使用这些实验性软件包,滚动发布构建可能仍会失败,因为它取决于您计算机的当前配置。

    • 转到:“软件和更新”>“其他软件”并禁用添加到列表 ppa 存储库的符号。

    • 然后运行这些命令;最后一个重启电脑:

       sudo rm -vf /var/lib/apt/lists/*
       sudo apt clean
       sudo apt update
       sudo reboot 0
      

    【讨论】:

    • 整个网站张贴了如此多的迂回方法。这是唯一有意义的。删除损坏的数据并重建它
    • 对我来说,在软件更新中禁用错误​​的 repo > 其他操作系统然后显示一条关于过时的消息。完成此操作后,当我运行 sudo apt update 时问题就消失了。无需重新启动,也无需删除 apt 列表。
    【解决方案3】:

    对于可能仍然面临同样问题的任何人,上述解决方案对我不起作用。就我而言,根目录分区已满(100% 用完),我使用了

    df -h
    cd /
    du -sch * --exclude=home
    

    检查磁盘空间的使用情况。就我而言,根目录中有一个mysql数据文件夹的备份,在9.1GB的空间中占用了大约3.7GB。 我所做的只是删除了 mysql 文件夹。但要小心你删除的内容。

    【讨论】:

      猜你喜欢
      • 1970-01-01
      • 2020-01-09
      • 2017-04-29
      • 2022-11-14
      • 2021-10-18
      • 1970-01-01
      • 1970-01-01
      • 2020-05-31
      • 2023-02-19
      相关资源
      最近更新 更多