Sunday, August 27, 2017

Find fastest mirror

This is for arch Linux but the simple technique can be used to sort any other mirrors.

First create a backup of the original /etc/pacman.d/mirrorlist as /etc/pacman.d/mirrorlist.orig

Then create the following simple script:

#!/bin/bash
awk -F'/' '{print $3}' /etc/pacman.d/mirrorlist.orig | grep -v '^$' | while read line;
do
HEAD $line &>/dev/null && grep -B1 $line /etc/pacman.d/mirrorlist.orig&
done > /etc/pacman.d/mirrorlist


Running this script will create the sorted list of mirrors in /etc/pacman.d/mirrorlist based on how fast the mirror respond to the HTTP request.

8 comments:

  1. This comment has been removed by a blog administrator.

    ReplyDelete
  2. This comment has been removed by the author.

    ReplyDelete
  3. Wow it is really wonderful and awesome thus it is very much useful for me to understand many concepts and helped me a lot. it is really explainable very well and i got more information from your blog.


    rpa training in chennai | best rpa training in chennai | rpa training in chennai | rpa training in bangalore
    rpa training in pune | rpa online training

    ReplyDelete
  4. Thanks for taking the time to discuss this, I feel strongly about it and love learning more on this topic.
    python training in rajajinagar
    Python training in btm
    Python training in usa

    ReplyDelete
  5. Amazing post!!! This post is very comprehensive and i learn more ideas. Thanks for your post, i like more updates from your blog...
    PHP Training in Bangalore
    PHP Course in Bangalore
    PHP Course in Perambur
    PHP Classes near me
    PHP Training in Karappakkam

    ReplyDelete

Intel Corporation XMM7360 LTE Advanced Modem in ArchLinux

The required packages are available in ArchLinux User Repository (AUR) so it will be easier if you can use an AUR helper package like yay . ...