После обновления с 15.10 до 16.04 я получаю следующую ошибку на apt-get update
:
Reading package lists... Done
E: Failed to fetch http://security.ubuntu.com/ubuntu/dists/xenial-security/restricted/source/Sources Empty files can't be valid archives
E: Failed to fetch http://security.ubuntu.com/ubuntu/dists/xenial-security/universe/source/Sources Empty files can't be valid archives
E: Failed to fetch http://security.ubuntu.com/ubuntu/dists/xenial-security/multiverse/source/Sources Empty files can't be valid archives
E: Failed to fetch http://security.ubuntu.com/ubuntu/dists/xenial-security/restricted/binary-amd64/Packages Empty files can't be valid archives
E: Failed to fetch http://security.ubuntu.com/ubuntu/dists/xenial-security/restricted/binary-i386/Packages Empty files can't be valid archives
E: Failed to fetch http://security.ubuntu.com/ubuntu/dists/xenial-security/restricted/i18n/Translation-en Empty files can't be valid archives
E: Failed to fetch http://security.ubuntu.com/ubuntu/dists/xenial-security/universe/binary-amd64/Packages Empty files can't be valid archives
E: Failed to fetch http://security.ubuntu.com/ubuntu/dists/xenial-security/universe/binary-i386/Packages Empty files can't be valid archives
E: Failed to fetch http://security.ubuntu.com/ubuntu/dists/xenial-security/universe/i18n/Translation-en Empty files can't be valid archives
E: Failed to fetch http://security.ubuntu.com/ubuntu/dists/xenial-security/multiverse/binary-amd64/Packages Empty files can't be valid archives
E: Failed to fetch http://security.ubuntu.com/ubuntu/dists/xenial-security/multiverse/binary-i386/Packages Empty files can't be valid archives
E: Some index files failed to download. They have been ignored, or old ones used instead.
Кто-нибудь знает, как решить эту ошибку?
Перейдите в «Центр программного обеспечения Ubuntu-> Редактировать-> Источник ПО»
выберите «Загрузить с», выберите «Другое ...» и нажмите «Выбрать лучший сервер».
Это займет некоторое время...
И он предлагает лучший сервер для вас.
Затем выберите этот сервер и снова введите команду ниже:
sudo apt-get update
Решено с использованием этого:
sudo cd /etc/apt
sudo mv sources.list sources.list.ok
sudo echo <<EOF
deb mirror://mirrors.ubuntu.com/mirrors.txt xenial main restricted universe multiverse
deb mirror://mirrors.ubuntu.com/mirrors.txt xenial-updates main restricted universe multiverse
deb mirror://mirrors.ubuntu.com/mirrors.txt xenial-backports main restricted universe multiverse
deb mirror://mirrors.ubuntu.com/mirrors.txt xenial-security main restricted universe multiverse
EOF > sources.list
sudo apt-get clean
sudo apt-get update
После обновления вы можете вернуть свой sources.list к исходному !!
Я получал это последние несколько месяцев после обновления, но просто выполнял:
apt-get clean
исправил. Нет необходимости менять исходные серверы, как предлагали другие.
apt-get clean
работал у меня вместе с:
apt-key update
и следуя шагам, указанным в этом ответе:
У меня была эта ситуация с другим архивом. Нахождение и удаление файла байта 0 из / var / lib / apt / liess
Исправлена проблема для меня.