How to switch to a local update mirror in Linux Mint
If you use Linux Mint and notice that software updates take too long to download, you may live too far from the official update servers. To fix this, you’ll need to swap to a local update mirror in Linux Mint. This will allow you to update the OS faster.
Swap Linux Mint update repositories
The quickest way to swap the Linux Mint update repositories with ones closer to where you live is within the GUI update manager. Open up the update manager by clicking the shield icon in the system tray. Then, once the update tool is open, follow the step-by-step instructions to switch to a local update mirror.
Step 1: In the Update Manager, install any pending software updates (if you have any). Installing updates is critical, as the app will not let you tweak settings in it before installing updates.
To install updates with the Update Manager, click “Refresh,” followed by the “Install Updates” button.
Step 2: Locate the “Edit” button and select it with the mouse to reveal the “Edit” menu.
Step 3: Look through the “Edit” menu for the “Software Sources” button and select it to open up Linux Mint’s software repo settings area.
Step 4: Look for the “Mirrors” section in the “Official Repositories” area of “Software Sources.”
Step 5: Locate the “Main (tina) box, and click it with the mouse to reveal the Linux Mint mirror chooser window.
Step 6: Let the Linux Mint mirror chooser window load up all the different software repository mirrors. Once all of them are loaded, select the mirror with the fastest Mbps speed rating, and click the “Apply” button to switch to it.
Step 7: Find the “Base (bionic) box and click it to reveal the Linux Mint mirror chooser window.
Step 8: Once again, let the mirrors load into the chooser. When all mirrors are done loading up, look through the list of choices, and select the mirror that has the fastest Mpbs speed rating. Click the “Apply” button to confirm your selection.
After switching mirrors over in the Linux Mint “Software Sources” app, a message will appear asking to refresh the software sources on the system. Do so. When done, Linux Mint will be using local mirrors!
Return to default update repo
You may find that the local mirrors aren’t as reliable as the ones that Linux Mint offers by default. If you’d like to change your system back to using the default software repositories, follow the steps below.
Step 1: Open the Linux Mint Update app and click the “Edit” button. Then, look through the menu for “Software Sources” and select it with the mouse.
Step 2: Find “Main (tina)” and click on the box to reveal the mirror chooser window.
Step 3: Let the mirror chooser window load up all the available mirrors. Look through and select the “Linux Mint” mirror, and click “Apply” to switch to it.
Step 4: Select the Base (bionic) box, load up the mirror chooser, and set it to “archive.ubuntu.com/ubuntu.” Click “Apply” to switch the system to it.
Once both mirrors are set up, refresh Linux Mint’s software sources by clicking the “OK” button in the message that appears.
Switch to local update mirror – command-line
Don’t like to use the Linux Mint Update Manager? Want to change to a local update mirror from the command-line? Follow the step-by-step instructions below to get it done!
Step 1: Open up a terminal window by pressing Ctrl + Alt + T or Ctrl + Shift + T on the keyboard.
Step 2: Using the cp command, make a complete backup of the default mirror settings on your Linux Mint PC. While this isn’t mandatory, it will make reverting to the default software sources much quicker.
sudo cp /etc/apt/sources.list.d/official-package-repositories.list /etc/apt/sources.list.d/official-package-repositories.list.bak
Step 3: Open up “official-package-repositories.list” in the Nano text editor for modification purposes.
sudo nano -w /etc/apt/sources.list.d/official-package-repositories.list
Step 4: Locate “https://packages.linuxmint.com” in the text file and erase it. DO NOT ERASE ANYTHING OTHER THAN THE URL! Then, replace the URL you’ve erased with one of the mirror URLs from this link here.
Step 5: If you’d like to change the Ubuntu base repo to a more local one, change all instances of “https://archive.ubuntu.com/ubuntu” to one of the mirrors on this list. This step is optional, so feel free to skip it.
Step 6: Save the edits made in the Nano text editor by pressing Ctrl + O on the keyboard. Then, close the text editor by pressing Ctrl + X.
Step 7: Update Linux Mint’s software sources by using the update command.
sudo apt update
When the update command finishes, your Linux Mint system will be using local mirrors!
Retrun to default update repo in command-line
To revert Linux Mint to the default software repositories, rather than local mirrors, open up a terminal window and enter the commands below.
sudo rm /etc/apt/sources.list.d/official-package-repositories.list
sudo mv /etc/apt/sources.list.d/official-package-repositories.list.bak /etc/apt/sources.list.d/official-package-repositories.list
sudo apt update
When I try to update my repository mirrors this next comes up.
E:The repository ‘http://ftp.utexas.edu/mariadb/repo/10.3/ubuntu bionic Release’ no longer has a Release file.
What next ?