If sudo apt-get update command failed like this:

W: Failed to fetch http://jp.archive.ubuntu.com/ubuntu/dists/trusty/InRelease--

W: Failed to fetch http://jp.archive.ubuntu.com/ubuntu/dists/trusty-updates/InRelease--

W: Failed to fetch http://jp.archive.ubuntu.com/ubuntu/dists/trusty-backports/InRelease--

W: Failed to fetch http://jp.archive.ubuntu.com/ubuntu/dists/trusty/Release.gpg  Unable to connect to jp.archive.ubuntu.com:http:

W: Failed to fetch http://jp.archive.ubuntu.com/ubuntu/dists/trusty-updates/Release.gpg  Unable to connect to jp.archive.ubuntu.com:http:

W: Failed to fetch http://jp.archive.ubuntu.com/ubuntu/dists/trusty-backports/Release.gpg  Unable to connect to jp.archive.ubuntu.com:http:

W: Some index files failed to download. They have been ignored, or old ones used instead.

You should change apt source!

If you live in Japan region, change from //jp.archive.ubuntu/com from //ftp.jaist.ac.jp

Input this command

sudo sed -i".bak" -e 's///jp.archive.ubuntu.com///ftp.jaist.ac.jp/g'  /etc/apt/sources.list

You can now update and upgrade faster than before!

  • Reference: pc.casey.jp