Ubuntu, by default, will use the apt repository local to the country you set when installing your Ubuntu system. There are repositories set up for each country, where the URL are differentiated based on the 2 characters (Alpha-2) country code. Some repositories are not country-specific that you can also use, and it's possible even to set one up on your own.
Multiple apt repositories ensure the main repository is not overwhelmed by global requests and for a more seamless user experience, as local repositories are generally faster than those in foreign countries due to network latency.
You might want to change the source for your apt repository for any technical (bandwidth issues) or non-technical (corporate policy) reasons. You can do that by updating the apt repository source file from the terminal.
$ sudo cp -a /etc/apt/source.list /etc/apt/source.list.bak [sudo] password for user:
$ sudo sed -i "s/\/jp\./\/us\./g" /etc/apt/sources.list
$ sudo apt update Hit:1 http://ports.ubuntu.com/ubuntu-ports kinetic-security InRelease Get:2 http://us.ports.ubuntu.com/ubuntu-ports kinetic InRelease [267 kB] Get:3 http://us.ports.ubuntu.com/ubuntu-ports kinetic-updates InRelease [90.7 kB] Get:4 http://us.ports.ubuntu.com/ubuntu-ports kinetic-backports InRelease [90.7 kB] Get:5 http://us.ports.ubuntu.com/ubuntu-ports kinetic/main arm64 Packages [1,363 kB] ##### snipped
Step for apt update (above) is crucial before proceeding with package upgrade or installation.
$ sudo apt dist-upgrade --assume-yes
Comment anonymously. Login not required.