mikaela.github.io/blog/_posts/2015-10-09-arch-reflector.md

62 lines
1.9 KiB
Markdown
Raw Normal View History

2015-10-09 12:46:43 +02:00
---
layout: post
sitemap: false
2015-10-09 12:46:43 +02:00
comments: true
title: "Using reflector in Arch my way"
category: [english]
tags: [arch, linux, reflector, mirrors]
redirect_from:
- /reflector.html
- /arch-reflector.html
- /antergos-reflector.html
2018-11-25 23:51:24 +01:00
- /english/2015/10/09/arch-reflector.html
2015-10-09 12:46:43 +02:00
---
2024-06-19 07:19:44 +02:00
_Reflector is a tool that checks the most recently upgraded Arch Linux mirrors
and ranks them by speed and saves them to your mirrorlist._
2015-10-09 12:46:43 +02:00
2024-06-19 07:19:44 +02:00
**This is largely based on [ArchWiki page on reflector] which is licensed in [GNU
Free
Documentation License 1.3 or later].**
2015-10-09 12:46:43 +02:00
2023-02-22 19:28:38 +01:00
[archwiki page on reflector]: https://wiki.archlinux.org/index.php/Reflector
2024-06-19 07:19:44 +02:00
[gnu free documentation license 1.3 or later]:
https://www.gnu.org/copyleft/fdl.html
2015-10-09 12:46:43 +02:00
TL;DR commands:
2015-10-09 12:49:46 +02:00
<pre>
2015-10-09 12:46:43 +02:00
sudo pacman --needed -S reflector rsync curl
cd /etc/systemd/system/
sudo curl -LO https://github.com/Mikaela/shell-things/raw/master/etc/systemd/system/reflector.service
sudo systemctl enable reflector
sudo systemctl start reflector
sudo pacman -Syu
2015-10-09 12:49:46 +02:00
</pre>
2015-10-09 12:46:43 +02:00
(end of TL;DR and what you actually do)
2024-06-19 07:19:44 +02:00
1. Install reflector itself, additional depedency of rsync to rank the mirrors
by speed, and curl which you use in the second command
2015-10-09 12:46:43 +02:00
2. to download my reflector.service
2024-06-19 07:19:44 +02:00
- differences to Arch Wiki version: requires network-online.target so you
don't have to enable any wait-online services and uses only https mirrors.
2015-10-09 12:46:43 +02:00
3. enable the service so it's ran on boot
2024-06-19 07:19:44 +02:00
4. start it now so it checks the most recently updated mirrors and saves them to
mirrorlist.
2015-10-09 12:46:43 +02:00
5. Check for updates & install them.
2024-06-19 07:19:44 +02:00
Do check the service itself at
https://github.com/Mikaela/shell-things/raw/master/etc/systemd/system/reflector.service
!
2015-10-17 14:02:15 +02:00
Bonus: edit `/etc/pacman.conf` and add the line:
```
NoExtract = etc/pacman.d/mirrorlist
```
2024-06-19 07:19:44 +02:00
so when you upgrade you won't get useless mirrorlist.pacnew file. **NOTE:** it's
intented to be `etc/pacman.d/mirrorlist` without the initial `/`, because it's
_relative_, not _absolute_, path.