• Skip to primary navigation
  • Skip to main content
  • Skip to primary sidebar
  • Skip to footer navigation

The Geek Diary

  • OS
    • Linux
    • CentOS/RHEL
    • VCS
  • Interview Questions
  • Database
    • MariaDB
  • DevOps
    • Docker
    • Shell Scripting
  • Big Data
    • Hadoop
    • Cloudera
    • Hortonworks HDP

pacman-mirrors Command Examples in Linux

by Deepika

“pacman-mirrors” is a tool for generating a pacman mirrorlist in Manjaro Linux and other Arch Linux-based distributions. A mirrorlist is a list of mirrors (or servers) that provide access to package repositories, and pacman uses the mirrorlist to download packages during package installations and upgrades.

“pacman-mirrors” is used to generate a new and up-to-date mirrorlist for the system, by gathering information about available mirrors and selecting the best ones based on factors such as speed, reliability, and geographic location. The generated mirrorlist is then used by pacman to download packages from the selected mirrors.

Using a good mirrorlist is important for several reasons, such as:

  • Speed: Selecting fast and reliable mirrors can significantly improve the download speed of packages.
  • Reliability: By using a well-curated mirrorlist, the user can ensure that pacman downloads packages from mirrors that are reliable and have a good track record.
  • Geo-location: By selecting mirrors that are close to the user’s location, pacman can download packages faster and more reliably.

Every run of “pacman-mirrors” requires the user to synchronize their database and update their system using “sudo pacman -Syyu”. This ensures that the system is up-to-date with the latest package information and minimizes the chances of encountering problems during package installations and upgrades.

pacman-mirrors Command Examples

1. Generate a mirrorlist using the default settings:

# sudo pacman-mirrors --fasttrack

2. Get the status of the current mirrors:

# pacman-mirrors --status

3. Display the current branch:

# pacman-mirrors --get-branch

4. Switch to a different branch:

# sudo pacman-mirrors --api --set-branch {{stable|unstable|testing}}

5. Generate a mirrorlist, only using mirrors in your country:

# sudo pacman-mirrors --geoip

Filed Under: Linux

Some more articles you might also be interested in …

  1. hsw-cli Command Examples
  2. dar Command Examples in Linux
  3. doctum: A PHP API documentation generator
  4. Linux OS Service ‘scsi_reserve’
  5. How to Install Automatic Bug Reporting Tool(ABRT) package in RHEL 9 (How to capture coredump in RHEL 9)
  6. lp Command Examples
  7. nsnake Command Examples in Linux
  8. doctl serverless: Manage serverless functions
  9. ldconfig Command Examples in Linux
  10. bpftrace Command Examples in Linux

You May Also Like

Primary Sidebar

Recent Posts

  • Vanilla OS 2 Released: A New Era for Linux Enthusiasts
  • mk Command Examples
  • mixxx Command Examples
  • mix Command Examples

© 2025 · The Geek Diary

  • Archives
  • Contact Us
  • Copyright