Today I changed package eos-rankmirrors to automatically rank the EndeavourOS mirror list (but not the Arch mirror list!) after every update of this package.
If you are OK with the automatic EndeavourOS mirror ranking, then you don’t have to do anything.
But if you have already set up a great /etc/pacman.d/endeavouros-mirrorlist that you don’t want to change, you can keep your own list by configuring variable
EOS_AUTO_MIRROR_RANKING=no # 'no' to prevent auto ranking
Ahhhh, so I don’t have to do anything. I like this option
All joking side, this works fine for me, just updated thank you kindly!
Edit: This is the new default config file for anyone curious btw:
sudo nano /etc/eos-rankmirrors.conf
GNU nano 6.0 /etc/eos-rankmirrors.conf
###############################################
# eos-rankmirrors.conf
###############################################
# EOS_AUTO_MIRROR_RANKING determines whether the EndeavourOS mirror list
# will be automatically ranked every time package endeavouros-mirrorlist
# is updated.
# Supported values:
# yes rank the mirror list automatically
# no do not rank the mirror list automatically
#
EOS_AUTO_MIRROR_RANKING=yes
# EOS_AUTORANK_TIMEOUT specifies the maximum time (in seconds)
# for each mirror to return the full answer.
#
EOS_AUTORANK_TIMEOUT=30
Something more: added a timeout variable EOS_AUTORANK_TIMEOUT for those who have problems with timeouts during ranking.
Note that this variable applies only to the automatic ranking, but not manual.
I may have asked this once before I can’t quite remember, but are there any thoughts to getting a US server added for the EndeavourOS repos or is the Canada server sufficient enough?
You could use @westandskif’s great utility rate-mirrors with the stdin option to rate EndeavourOS mirrors. Perhaps he could be persuaded to include them by default into his utility?
cat << EOF | rate-mirrors stdin --path-to-test="endeavouros/x86_64/endeavouros.files" --path-to-return='$repo/$arch' | sed 's/^[^#]/Server = h/g'
https://mirror.alpix.eu/endeavouros/repo/ DE
https://de.freedif.org/EndeavourOS/repo/ DE
https://mirror.moson.org/endeavouros/repo/ DE
https://ftp.acc.umu.se/mirror/endeavouros/repo/ SE
https://mirror.linux.pizza/endeavouros/repo/ SE
https://ca.gate.endeavouros.com/endeavouros/ CA
https://mirrors.tuna.tsinghua.edu.cn/endeavouros/repo/ CN
https://mirror.jingk.ai/endeavouros/repo/ SG
http://mirror.jingk.ai/endeavouros/repo/ SG
https://endeavour.remi.lu/repo/ FR
EOF
It works fine, the only problem I did not know how to fix was the output missing "Server = " before the URL, hence that somewhat ugly sed hack at the end.
This outputs the result to stdout, if you want it written to mirrorlist file, just add
| sudo tee /etc/pacman.d/endeavouros-mirrorlist
to the end of the first line (make a backup first, of course).
It should have been: automatic ranking takes place always when package endeavouros-mirrorlist is updated.
So only when that particular package is updated (and also initially installed).
Does this create a a pacnew file?
No, instead it creates a backup of the file that existed before the update. So you are able to revert to your previous EndeavourOS mirrorlist.
@Kresimir
Thanks! I’ll try that soon.
EDIT: works a treat! I had almost similar example here, but for some reason it failed. Probably some minor syntax problem…
Does it matter? Each of these backups is about 1 KiB in size. It’s extremely unlikely you’ll ever run out of storage space that way, but you are free to delete them manually if they build up and start to clutter the directory.
However, ranking the EndeavourOS mirrors is something you should probably do once, if at all. It’s not a very busy repo and most packages in it are tiny and seldom updated, so it’s not like the package download speed matters with it.
From what I see the backup of the current list is being made with eos-rankmirrors which is triggered after endeavouros-mirrorlist is upgraded (so at that point /etc/pacman.d/endeavouros-mirrorlist has already been replaced )