Ubuntu E: Sub-process /usr/bin/dpkg returned an error code (1)

转载地址:https://blog.csdn.net/zy1049677338/article/details/86005806

 

解决办法,更新源

1.备份

sudo cp /etc/apt/sources.list /etc/apt/sources.list.old

2.修改替换

sudo vim /etc/apt/source.list

3/复制源

把下面的任意一下复制到source.list中去,并覆盖原来的文件内容。

东北大学源

  1.  
    deb-src http://mirror.neu.edu.cn/ubuntu/ xenial main restricted #Added by software-properties
  2.  
    deb http://mirror.neu.edu.cn/ubuntu/ xenial main restricted
  3.  
    deb-src http://mirror.neu.edu.cn/ubuntu/ xenial restricted multiverse universe #Added by software-properties
  4.  
    deb http://mirror.neu.edu.cn/ubuntu/ xenial-updates main restricted
  5.  
    deb-src http://mirror.neu.edu.cn/ubuntu/ xenial-updates main restricted multiverse universe #Added by software-properties
  6.  
    deb http://mirror.neu.edu.cn/ubuntu/ xenial universe
  7.  
    deb http://mirror.neu.edu.cn/ubuntu/ xenial-updates universe
  8.  
    deb http://mirror.neu.edu.cn/ubuntu/ xenial multiverse
  9.  
    deb http://mirror.neu.edu.cn/ubuntu/ xenial-updates multiverse
  10.  
    deb http://mirror.neu.edu.cn/ubuntu/ xenial-backports main restricted universe multiverse
  11.  
    deb-src http://mirror.neu.edu.cn/ubuntu/ xenial-backports main restricted universe multiverse #Added by software-properties
  12.  
    deb http://archive.canonical.com/ubuntu xenial partner
  13.  
    deb-src http://archive.canonical.com/ubuntu xenial partner
  14.  
    deb http://mirror.neu.edu.cn/ubuntu/ xenial-security main restricted
  15.  
    deb-src http://mirror.neu.edu.cn/ubuntu/ xenial-security main restricted multiverse universe #Added by software-properties
  16.  
    deb http://mirror.neu.edu.cn/ubuntu/ xenial-security universe
  17.  
    deb http://mirror.neu.edu.cn/ubuntu/ xenial-security multiverse

清华大学

  1.  
    # deb cdrom:[Ubuntu 16.04 LTS _Xenial Xerus_ - Release amd64 (20160420.1)]/ xenial main restricted
  2.  
    deb http://mirrors.tuna.tsinghua.edu.cn/ubuntu/ xenial main restricted
  3.  
    deb http://mirrors.tuna.tsinghua.edu.cn/ubuntu/ xenial-updates main restricted
  4.  
    deb http://mirrors.tuna.tsinghua.edu.cn/ubuntu/ xenial universe
  5.  
    deb http://mirrors.tuna.tsinghua.edu.cn/ubuntu/ xenial-updates universe
  6.  
    deb http://mirrors.tuna.tsinghua.edu.cn/ubuntu/ xenial multiverse
  7.  
    deb http://mirrors.tuna.tsinghua.edu.cn/ubuntu/ xenial-updates multiverse
  8.  
    deb http://mirrors.tuna.tsinghua.edu.cn/ubuntu/ xenial-backports main restricted universe multiverse
  9.  
    deb http://mirrors.tuna.tsinghua.edu.cn/ubuntu/ xenial-security main restricted
  10.  
    deb http://mirrors.tuna.tsinghua.edu.cn/ubuntu/ xenial-security universe
  11.  
    deb http://mirrors.tuna.tsinghua.edu.cn/ubuntu/ xenial-security multiverse

阿里云源

  1.  
    # deb cdrom:[Ubuntu 16.04 LTS _Xenial Xerus_ - Release amd64 (20160420.1)]/ xenial main restricted
  2.  
    deb-src http://archive.ubuntu.com/ubuntu xenial main restricted #Added by software-properties
  3.  
    deb http://mirrors.aliyun.com/ubuntu/ xenial main restricted
  4.  
    deb-src http://mirrors.aliyun.com/ubuntu/ xenial main restricted multiverse universe #Added by software-properties
  5.  
    deb http://mirrors.aliyun.com/ubuntu/ xenial-updates main restricted
  6.  
    deb-src http://mirrors.aliyun.com/ubuntu/ xenial-updates main restricted multiverse universe #Added by software-properties
  7.  
    deb http://mirrors.aliyun.com/ubuntu/ xenial universe
  8.  
    deb http://mirrors.aliyun.com/ubuntu/ xenial-updates universe
  9.  
    deb http://mirrors.aliyun.com/ubuntu/ xenial multiverse
  10.  
    deb http://mirrors.aliyun.com/ubuntu/ xenial-updates multiverse
  11.  
    deb http://mirrors.aliyun.com/ubuntu/ xenial-backports main restricted universe multiverse
  12.  
    deb-src http://mirrors.aliyun.com/ubuntu/ xenial-backports main restricted universe multiverse #Added by software-properties
  13.  
    deb http://archive.canonical.com/ubuntu xenial partner
  14.  
    deb-src http://archive.canonical.com/ubuntu xenial partner
  15.  
    deb http://mirrors.aliyun.com/ubuntu/ xenial-security main restricted
  16.  
    deb-src http://mirrors.aliyun.com/ubuntu/ xenial-security main restricted multiverse universe #Added by software-properties
  17.  
    deb http://mirrors.aliyun.com/ubuntu/ xenial-security universe
  18.  
    deb http://mirrors.aliyun.com/ubuntu/ xenial-security multiverse

4/update命令

 

sudo apt-get update

E: Sub-process /usr/bin/dpkg returned an error code (1)

posted @ 2019-03-12 17:16  黒貓  阅读(413)  评论(0编辑  收藏  举报