Question

Failed to fetch ubuntu xenial packages from sfo1.mirrors.digitalocean.com using apt-get update

Seems like some packages are not present in http://sfo1.mirrors.digitalocean.com/ubuntu/dists. Here is the output when I run sudo apt-get update:

Ign:1 http://repo.mongodb.org/apt/ubuntu xenial/mongodb-org/3.2 InRelease Hit:2 http://repo.mongodb.org/apt/ubuntu xenial/mongodb-org/3.2 Release Hit:3 http://linux-packages.resilio.com/resilio-sync/deb resilio-sync InRelease Get:4 http://security.ubuntu.com/ubuntu xenial-security InRelease [107 kB] Hit:5 http://ppa.launchpad.net/certbot/certbot/ubuntu xenial InRelease Hit:8 https://deb.nodesource.com/node_7.x xenial InRelease Hit:9 https://dl.yarnpkg.com/debian stable InRelease Hit:10 https://repos.sonar.digitalocean.com/apt main InRelease Get:6 http://sfo1.mirrors.digitalocean.com/ubuntu xenial InRelease [247 kB] Get:11 http://sfo1.mirrors.digitalocean.com/ubuntu xenial-updates InRelease [109 kB] Get:12 http://sfo1.mirrors.digitalocean.com/ubuntu xenial-backports InRelease [107 kB] Hit:13 http://ppa.launchpad.net/fish-shell/release-2/ubuntu xenial InRelease Hit:14 http://ppa.launchpad.net/longsleep/golang-backports/ubuntu xenial InRelease Get:15 http://sfo1.mirrors.digitalocean.com/ubuntu xenial/main Sources [868 kB] Get:16 http://sfo1.mirrors.digitalocean.com/ubuntu xenial/restricted Sources [4,808 B] Get:17 http://security.ubuntu.com/ubuntu xenial-security/main Sources [138 kB] Get:18 http://security.ubuntu.com/ubuntu xenial-security/restricted Sources [2,116 B] Hit:20 http://ppa.launchpad.net/max-c-lv/shadowsocks-libev/ubuntu xenial InRelease Get:21 http://security.ubuntu.com/ubuntu xenial-security/universe Sources [88.3 kB] Get:22 http://security.ubuntu.com/ubuntu xenial-security/multiverse Sources [2,468 B] Get:24 http://security.ubuntu.com/ubuntu xenial-security/main amd64 Packages [587 kB] Hit:26 http://ppa.launchpad.net/wireguard/wireguard/ubuntu xenial InRelease Ign:27 http://security.ubuntu.com/ubuntu xenial-security/main armhf Packages Get:29 http://security.ubuntu.com/ubuntu xenial-security/main Translation-en [245 kB] Get:30 http://security.ubuntu.com/ubuntu xenial-security/restricted amd64 Packages [7,204 B] Get:19 http://sfo1.mirrors.digitalocean.com/ubuntu xenial/universe Sources [7,728 kB] Ign:32 http://security.ubuntu.com/ubuntu xenial-security/restricted armhf Packages Get:23 http://sfo1.mirrors.digitalocean.com/ubuntu xenial/multiverse Sources [179 kB] Get:33 http://security.ubuntu.com/ubuntu xenial-security/restricted Translation-en [2,152 B] Get:25 http://sfo1.mirrors.digitalocean.com/ubuntu xenial/main amd64 Packages [1,201 kB] Ign:28 http://sfo1.mirrors.digitalocean.com/ubuntu xenial/main armhf Packages Get:35 http://security.ubuntu.com/ubuntu xenial-security/universe amd64 Packages [402 kB] Get:31 http://sfo1.mirrors.digitalocean.com/ubuntu xenial/main Translation-en [568 kB] Get:34 http://sfo1.mirrors.digitalocean.com/ubuntu xenial/restricted amd64 Packages [8,344 B] Ign:36 http://sfo1.mirrors.digitalocean.com/ubuntu xenial/restricted armhf Packages Ign:37 http://security.ubuntu.com/ubuntu xenial-security/universe armhf Packages Get:38 http://sfo1.mirrors.digitalocean.com/ubuntu xenial/restricted Translation-en [2,908 B] Get:40 http://security.ubuntu.com/ubuntu xenial-security/universe Translation-en [157 kB] Get:41 http://security.ubuntu.com/ubuntu xenial-security/multiverse amd64 Packages [3,724 B] Ign:42 http://security.ubuntu.com/ubuntu xenial-security/multiverse armhf Packages Get:43 http://security.ubuntu.com/ubuntu xenial-security/multiverse Translation-en [1,844 B] Ign:27 http://security.ubuntu.com/ubuntu xenial-security/main armhf Packages Ign:32 http://security.ubuntu.com/ubuntu xenial-security/restricted armhf Packages Get:39 http://sfo1.mirrors.digitalocean.com/ubuntu xenial/universe amd64 Packages [7,532 kB] Ign:44 http://sfo1.mirrors.digitalocean.com/ubuntu xenial/universe armhf Packages Ign:37 http://security.ubuntu.com/ubuntu xenial-security/universe armhf Packages Ign:42 http://security.ubuntu.com/ubuntu xenial-security/multiverse armhf Packages Ign:27 http://security.ubuntu.com/ubuntu xenial-security/main armhf Packages Get:45 http://sfo1.mirrors.digitalocean.com/ubuntu xenial/universe Translation-en [4,354 kB] Get:46 http://sfo1.mirrors.digitalocean.com/ubuntu xenial/multiverse amd64 Packages [144 kB] Ign:47 http://sfo1.mirrors.digitalocean.com/ubuntu xenial/multiverse armhf Packages Ign:32 http://security.ubuntu.com/ubuntu xenial-security/restricted armhf Packages Ign:37 http://security.ubuntu.com/ubuntu xenial-security/universe armhf Packages Get:48 http://sfo1.mirrors.digitalocean.com/ubuntu xenial/multiverse Translation-en [106 kB] Ign:42 http://security.ubuntu.com/ubuntu xenial-security/multiverse armhf Packages Err:27 http://security.ubuntu.com/ubuntu xenial-security/main armhf Packages 404 Not Found [IP: 91.189.91.26 80] Get:49 http://sfo1.mirrors.digitalocean.com/ubuntu xenial-updates/main Sources [327 kB] Ign:32 http://security.ubuntu.com/ubuntu xenial-security/restricted armhf Packages Get:50 http://sfo1.mirrors.digitalocean.com/ubuntu xenial-updates/restricted Sources [2,528 B] Ign:37 http://security.ubuntu.com/ubuntu xenial-security/universe armhf Packages Ign:42 http://security.ubuntu.com/ubuntu xenial-security/multiverse armhf Packages Get:51 http://sfo1.mirrors.digitalocean.com/ubuntu xenial-updates/universe Sources [235 kB] Get:52 http://sfo1.mirrors.digitalocean.com/ubuntu xenial-updates/multiverse Sources [8,740 B] Get:53 http://sfo1.mirrors.digitalocean.com/ubuntu xenial-updates/main amd64 Packages [890 kB] Ign:54 http://sfo1.mirrors.digitalocean.com/ubuntu xenial-updates/main armhf Packages Get:55 http://sfo1.mirrors.digitalocean.com/ubuntu xenial-updates/main Translation-en [361 kB] Get:56 http://sfo1.mirrors.digitalocean.com/ubuntu xenial-updates/restricted amd64 Packages [7,556 B] Ign:57 http://sfo1.mirrors.digitalocean.com/ubuntu xenial-updates/restricted armhf Packages Get:58 http://sfo1.mirrors.digitalocean.com/ubuntu xenial-updates/restricted Translation-en [2,272 B] Get:59 http://sfo1.mirrors.digitalocean.com/ubuntu xenial-updates/universe amd64 Packages [710 kB] Ign:60 http://sfo1.mirrors.digitalocean.com/ubuntu xenial-updates/universe armhf Packages Get:61 http://sfo1.mirrors.digitalocean.com/ubuntu xenial-updates/universe Translation-en [290 kB] Get:62 http://sfo1.mirrors.digitalocean.com/ubuntu xenial-updates/multiverse amd64 Packages [16.6 kB] Ign:63 http://sfo1.mirrors.digitalocean.com/ubuntu xenial-updates/multiverse armhf Packages Get:64 http://sfo1.mirrors.digitalocean.com/ubuntu xenial-updates/multiverse Translation-en [8,440 B] Get:65 http://sfo1.mirrors.digitalocean.com/ubuntu xenial-backports/main Sources [4,856 B] Get:66 http://sfo1.mirrors.digitalocean.com/ubuntu xenial-backports/universe Sources [6,740 B] Get:67 http://sfo1.mirrors.digitalocean.com/ubuntu xenial-backports/main amd64 Packages [7,288 B] Ign:68 http://sfo1.mirrors.digitalocean.com/ubuntu xenial-backports/main armhf Packages Get:69 http://sfo1.mirrors.digitalocean.com/ubuntu xenial-backports/main Translation-en [4,456 B] Get:70 http://sfo1.mirrors.digitalocean.com/ubuntu xenial-backports/universe amd64 Packages [7,804 B] Ign:71 http://sfo1.mirrors.digitalocean.com/ubuntu xenial-backports/universe armhf Packages Get:72 http://sfo1.mirrors.digitalocean.com/ubuntu xenial-backports/universe Translation-en [4,184 B] Ign:28 http://sfo1.mirrors.digitalocean.com/ubuntu xenial/main armhf Packages Ign:36 http://sfo1.mirrors.digitalocean.com/ubuntu xenial/restricted armhf Packages Ign:44 http://sfo1.mirrors.digitalocean.com/ubuntu xenial/universe armhf Packages Ign:47 http://sfo1.mirrors.digitalocean.com/ubuntu xenial/multiverse armhf Packages Ign:54 http://sfo1.mirrors.digitalocean.com/ubuntu xenial-updates/main armhf Packages Ign:57 http://sfo1.mirrors.digitalocean.com/ubuntu xenial-updates/restricted armhf Packages Ign:60 http://sfo1.mirrors.digitalocean.com/ubuntu xenial-updates/universe armhf Packages Ign:63 http://sfo1.mirrors.digitalocean.com/ubuntu xenial-updates/multiverse armhf Packages Ign:68 http://sfo1.mirrors.digitalocean.com/ubuntu xenial-backports/main armhf Packages Ign:71 http://sfo1.mirrors.digitalocean.com/ubuntu xenial-backports/universe armhf Packages Ign:28 http://sfo1.mirrors.digitalocean.com/ubuntu xenial/main armhf Packages Ign:36 http://sfo1.mirrors.digitalocean.com/ubuntu xenial/restricted armhf Packages Ign:44 http://sfo1.mirrors.digitalocean.com/ubuntu xenial/universe armhf Packages Ign:47 http://sfo1.mirrors.digitalocean.com/ubuntu xenial/multiverse armhf Packages Ign:54 http://sfo1.mirrors.digitalocean.com/ubuntu xenial-updates/main armhf Packages Ign:57 http://sfo1.mirrors.digitalocean.com/ubuntu xenial-updates/restricted armhf Packages Ign:60 http://sfo1.mirrors.digitalocean.com/ubuntu xenial-updates/universe armhf Packages Ign:63 http://sfo1.mirrors.digitalocean.com/ubuntu xenial-updates/multiverse armhf Packages Ign:68 http://sfo1.mirrors.digitalocean.com/ubuntu xenial-backports/main armhf Packages Ign:71 http://sfo1.mirrors.digitalocean.com/ubuntu xenial-backports/universe armhf Packages Err:28 http://sfo1.mirrors.digitalocean.com/ubuntu xenial/main armhf Packages 404 Not Found [IP: 198.199.99.226 80] Err:54 http://sfo1.mirrors.digitalocean.com/ubuntu xenial-updates/main armhf Packages 404 Not Found [IP: 198.199.99.226 80] Err:68 http://sfo1.mirrors.digitalocean.com/ubuntu xenial-backports/main armhf Packages 404 Not Found [IP: 198.199.99.226 80] Fetched 570 kB in 10s (53.8 kB/s) Reading package lists… Done N: Skipping acquire of configured file ‘multiverse/binary-armhf/Packages’ as repository ‘http://repo.mongodb.org/apt/ubuntu xenial/mongodb-org/3.2 InRelease’ doesn’t support architecture ‘armhf’ N: Skipping acquire of configured file ‘main/binary-armhf/Packages’ as repository ‘https://repos.sonar.digitalocean.com/apt main InRelease’ doesn’t support architecture ‘armhf’ E: Failed to fetch http://sfo1.mirrors.digitalocean.com/ubuntu/dists/xenial/main/binary-armhf/Packages 404 Not Found [IP: 198.199.99.226 80] E: Failed to fetch http://sfo1.mirrors.digitalocean.com/ubuntu/dists/xenial/restricted/binary-armhf/Packages 404 Not Found [IP: 198.199.99.226 80] E: Failed to fetch http://sfo1.mirrors.digitalocean.com/ubuntu/dists/xenial/universe/binary-armhf/Packages 404 Not Found [IP: 198.199.99.226 80] E: Failed to fetch http://sfo1.mirrors.digitalocean.com/ubuntu/dists/xenial/multiverse/binary-armhf/Packages 404 Not Found [IP: 198.199.99.226 80] E: Failed to fetch http://sfo1.mirrors.digitalocean.com/ubuntu/dists/xenial-updates/main/binary-armhf/Packages 404 Not Found [IP: 198.199.99.226 80] E: Failed to fetch http://sfo1.mirrors.digitalocean.com/ubuntu/dists/xenial-updates/restricted/binary-armhf/Packages 404 Not Found [IP: 198.199.99.226 80] E: Failed to fetch http://sfo1.mirrors.digitalocean.com/ubuntu/dists/xenial-updates/universe/binary-armhf/Packages 404 Not Found [IP: 198.199.99.226 80] E: Failed to fetch http://sfo1.mirrors.digitalocean.com/ubuntu/dists/xenial-updates/multiverse/binary-armhf/Packages 404 Not Found [IP: 198.199.99.226 80] E: Failed to fetch http://security.ubuntu.com/ubuntu/dists/xenial-security/main/binary-armhf/Packages 404 Not Found [IP: 91.189.91.26 80] E: Failed to fetch http://sfo1.mirrors.digitalocean.com/ubuntu/dists/xenial-backports/main/binary-armhf/Packages 404 Not Found [IP: 198.199.99.226 80] E: Failed to fetch http://sfo1.mirrors.digitalocean.com/ubuntu/dists/xenial-backports/universe/binary-armhf/Packages 404 Not Found [IP: 198.199.99.226 80] E: Some index files failed to download. They have been ignored, or old ones used instead.

Show comments

Submit an answer


This textbox defaults to using Markdown to format your answer.

You can type !ref in this text area to quickly search our full set of tutorials, documentation & marketplace offerings and insert the link!

Sign In or Sign Up to Answer

These answers are provided by our Community. If you find them useful, show some love by clicking the heart. If you run into issues leave a comment, or add your own answer to help others.

Accepted Answer

So I finally figured it out. I have installed resilio-sync which add armhf as foreign architecture (your architecture maybe i386 or amd64). Launch this command to verify:

dpkg --print-foreign-architectures

The output includes armhf, so I simply remove it by running the command:

sudo dpkg --remove-architecture armhf

But I met this error:

dpkg: error: cannot remove architecture 'armhf' currently in use by the database

To fix this issue, run:

dpkg --get-selections | awk '/armhf/{print $1}'

And then if happy with them being removed, run:

apt-get remove --purge `dpkg --get-selections | awk '/armhf/{print $1}'`

And then retry:

dpkg --remove-architecture armhf

Finally, launch sudo apt-get update again.

Reference:

jarland
DigitalOcean Employee
DigitalOcean Employee badge
December 5, 2018

Hey friend,

Try this and see if it helps:

rm -rf /var/lib/apt/lists/*
apt-get clean
apt-get update

Jarland

Try DigitalOcean for free

Click below to sign up and get $200 of credit to try our products over 60 days!

Sign up

Featured on Community

Get our biweekly newsletter

Sign up for Infrastructure as a Newsletter.

Hollie's Hub for Good

Working on improving health and education, reducing inequality, and spurring economic growth? We'd like to help.

Become a contributor

Get paid to write technical tutorials and select a tech-focused charity to receive a matching donation.

Welcome to the developer cloud

DigitalOcean makes it simple to launch in the cloud and scale up as you grow — whether you're running one virtual machine or ten thousand.

Learn more