New xfce install Question about reflector

Hello,

I just wanted to know as reflector is already installed and set up would there be any necessary changes I need to make? Or can I just follow the wiki like normal to set up reflector. I would prefer to just do what I normally do which is paste all the mirrors from the Arch download page into /etc/pacman.d/mirrorlist and then configure the automation systemd service and enable reflector.service.

What I’m trying to ask is if I set up reflector like normal will there be an issue or clash between configurations because something has already been setup on endeavouros?

hello,you go to welcome and then you set the parameters

EndeavourOS ships with reflector-simple which is a simpler interface to reflector. It doesn’t stop you from choosing to use reflector in the same way you would on Arch.

3 Likes

Hi,

yes I know that but if I didn’t want to do that can I edit /etc/xdg/reflector/reflector.conf this file myself or would that cause a conflict?

Do I have to use reflector from the welcome screen? If I set reflector up myself would that cause an issue with whatever has already been configured by endeavouros?

Also If I did use reflector via the welcome screen will it continuously refresh my mirrorlist every time I reboot?

hello and thank you dalto.

1 Like

I think you will find that, in general, while EOS provides tools to make certain things easier there is no requirement to use them.

Pretty much everything can be done the same way you would do it on Arch if that is your preference.

2 Likes

No conflicts - at least not unless you use both methods!
It does not do it automatically - that’s up to you.
reflector-simple can be run on its own from the terminal - it is just a convenience to have it on Welcome.

lol, well it is my preference if I understand the wiki and am able to.

lol Reflector is one of the things I was able work out on my own

1 Like

Understanding the wiki is always an ‘if’ :grin: It has all the information you need - and all the information you’ll never need, and all the information you might need. If you can sort out which is which…

1 Like

:wink: yeah i’ve had a love hate relationship with the wiki, struggling to understand it as a new linux user

because reflector is used during installation am I correct in thinking it’s fine to repopulate the pacman.d/mirrorlist with the mirrors from the arch download page then set up reflector and enable it?

I’m not sure it matters if you’re new! Sometimes I find that reading it all - then waiting a while - then trying again gives better results…

That said - why do you prefer to reset your mirrors so often? I mostly redo them only when something slows down.

I just thought the systemd service was a good way to have the mirrors updated regularly for good maintenance

True enough. In fact EnOS had an app - reflector-auto - for that purpose until that capability was added to reflector itself. I am just not sure what need there is to go through the mirrorlist from Arch itself (and deal with the large number of non-useful alternatives) when just running reflector (as described) to generate a list of a few (perhaps 10) of the most useful would do (up-to-date and quick ones, usually)

Where I am, a reflector command line like:

reflector --country CA --country US --protocol https --age 3 --sort rate --number 10

gives me what’s needed - the first in the list is first used, as far as I know - and the others are fallbacks when the first is slow or unavailable. Automating that, once a week or a month, perhaps - should have you well covered…

2 Likes

Sorry for the late reply freebird54 there’s a time difference for us, I’m in the UK. I actually just came on here to apologise for my question because I just now saw in /etc/pacman.d there is endeavouros-mirrorlist and the normal mirrorlist so obviously when I set up the systemd config file and set the save location I’m deciding which to use and setting reflectors behaviour.

oh honestly the pain I’ve gone through, lol and I mean I’ve felt physical pain in my chest whilst reading and reading and reading and not understanding and then reading more to still not understand. Because I literally new hardly nothing when I started to try and install Arch. For example environment variables, the way its explained for me anyway it was extremely difficult to understand what exactly the variable is and what is the value and how are they set. I don’t really have a great understanding about them now and that’s after I got some explanations on the Arch forum. lol I’ve stayed up for 24hr periods trying to deal with Arch, I can’t wait until I become more capable at understanding the wiki and can learn from the wiki on my own. It took me hours just to work out how to use udiskie and set up the tray. I’ve just noticed on EnOS I don’t need to do that.

Well when I looked in /etc/pacman.d/mirrorlist there weren’t that many mirrors so I thought (before setting up and using reflector) it would be better to fill the file with all the mirrors then reflector would choose the best ones for me.

That’s good, new information for me thank you. Maybe it wasn’t a wasted question.

Maybe I did need this post open. When I booted this morning as reflector is enabled it should have started and refreshed my mirrorlist. I noticed in the mirrorlist file that they hadn’t been refreshed today, I then checked the status of reflector and saw the following:

systemctl status reflector shows


● reflector.service - Refresh Pacman mirrorlist with Reflector.
     Loaded: loaded (/usr/lib/systemd/system/reflector.service; enabled; vendor preset: disabled)
     Active: failed (Result: exit-code) since Sun 2020-11-01 06:40:05 GMT; 46min ago
       Docs: https://wiki.archlinux.org/index.php/Reflector
   Main PID: 827 (code=exited, status=1/FAILURE)

Nov 01 06:40:05 Blackstone systemd[1]: Starting Refresh Pacman mirrorlist with Reflector....
Nov 01 06:40:05 Blackstone reflector[829]: error: failed to retrieve mirrorstatus data: URLError: <urlopen error [Errno -3] Temporary failure in name resolution>
Nov 01 06:40:05 Blackstone systemd[1]: reflector.service: Main process exited, code=exited, status=1/FAILURE
Nov 01 06:40:05 Blackstone systemd[1]: reflector.service: Failed with result 'exit-code'.
Nov 01 06:40:05 Blackstone systemd[1]: Failed to start Refresh Pacman mirrorlist with Reflector..

I looked again at /etc/xdg/reflector/reflector.conf and couldn’t find any issues with the file. This is my file contents:


cat /etc/xdg/reflector/reflector.conf 
# Reflector configuration file for the systemd service.
#
# Empty lines and lines beginning with "#" are ignored.  All other lines should
# contain valid reflector command-line arguments. The lines are parsed with
# Python's shlex modules so standard shell syntax should work. All arguments are
# collected into a single argument list.
#
# See "reflector --help" for details.

# Recommended Options

# Set the output path where the mirrorlist will be saved (--save).
--save /etc/pacman.d/mirrorlist

# Select the transfer protocol (--protocol).
--protocol https


# Select the country (--country).
# Consult the list of available countries with "reflector --list-countries" and
# select the countries nearest to you or the ones that you trust. For example:
--country France,Germany,

# Use only the  most recently synchronized mirrors (--latest).
--age 12

# Sort the mirrors by synchronization time (--sort).
--sort rate

I ran sudo systemctl enable --now reflector and it worked, updating my mirrorlist and there were no failed log entries in systemctl status

I just did a cold boot now and ran the following:


[muj@Blackstone ~]$ sudo systemctl --failed
[sudo] password for muj: 
  UNIT LOAD ACTIVE SUB DESCRIPTION
0 loaded units listed.
[muj@Blackstone ~]$ sudo systemctl status reflector
● reflector.service - Refresh Pacman mirrorlist with Reflector.
     Loaded: loaded (/usr/lib/systemd/system/reflector.service; enabled; vendor preset: disabled)
     Active: inactive (dead) since Sun 2020-11-01 08:04:27 GMT; 1min 3s ago
       Docs: https://wiki.archlinux.org/index.php/Reflector
    Process: 951 ExecStart=/usr/bin/reflector @/etc/xdg/reflector/reflector.conf (code=exited, status=0/SUCCESS)
   Main PID: 951 (code=exited, status=0/SUCCESS)

Nov 01 08:04:23 Blackstone systemd[1]: Starting Refresh Pacman mirrorlist with Reflector....
Nov 01 08:04:27 Blackstone systemd[1]: reflector.service: Succeeded.
Nov 01 08:04:27 Blackstone systemd[1]: Finished Refresh Pacman mirrorlist with Reflector..
[muj@Blackstone ~]$ cat /etc/pacman.d/mirrorlist
################################################################################
################# Arch Linux mirrorlist generated by Reflector #################
################################################################################

# With:       reflector @/etc/xdg/reflector/reflector.conf
# When:       2020-11-01 08:04:27 UTC
# From:       https://www.archlinux.org/mirrors/status/json/
# Retrieved:  2020-11-01 08:04:24 UTC
# Last Check: 2020-11-01 06:52:48 UTC

Server = https://archlinux.mailtunnel.eu/$repo/os/$arch
Server = https://mirror.oldsql.cc/archlinux/$repo/os/$arch
Server = https://mirrors.celianvdb.fr/archlinux/$repo/os/$arch
Server = https://mirror.cyberbits.eu/archlinux/$repo/os/$arch
Server = https://mirror.wormhole.eu/archlinux/$repo/os/$arch
Server = https://mirror.f4st.host/archlinux/$repo/os/$arch
Server = https://mirror.23media.com/archlinux/$repo/os/$arch

It seems to be working, I’m not sure if this is a non-issue or if there’s something wrong for reflector not to work correctly when I first booted this morning?

My first thought is that perhaps you enabled the service, but did start it (or vice versa). Both need to happen for automatic operation…

I noticed, no UK servers in your choices? Aren’t they faster? I gather the German ones are pretty good too…

Anyway- feel free to ask here when the wiki isn’t that clear (which is often at first!) Glad you got it to work.

Oh - and don’t worry about the hours - we have people from all over on here. From UTC-6 to UTC+10! As for me, officially UTC-4 (or 5) but my software company was called Midnight Logic for a reason :grin:

1 Like

@freebird54 It’s been very nice talking to you, thank you for that.

Well I tried putting the United Kingdom in the config file but reflector failed so I just took that part out. lol Obviously I should have tried with just UK. Thanks again

No problem - just remember that only the first is likely to be used - so you can put a LOT of countries in without a downside…

:smile: cheers @freebird54

What does this say:

systemctl status reflector.timer