Pacman-mirrors development version


#1

As you know I have been working on pacman-mirrors to create an api for those writing iso build scripts.

I think we have reached our goal implementing an API which as @artoo expressed it

this can replace several lines of spagetti code

To ensure we have caught all the bugs, you are invited to see if you can make it break and if you can, please post your command line and the python error messages.

Also check the man page which is very comprehensive.

The package lives in unstable branch on mirror.netzspielplatz.de and will of course propagate out in the world in due time.

sudo pacman -Sy pacman-mirrors-dev

If you change mirror remember to do a pacman -Syy to syncronize the db’s

Greetings


#2

Some strange message during the installation:

[2017-06-06 21:21] [PACMAN] Running 'pacman -Sy pacman-mirrors-dev'
[2017-06-06 21:21] [PACMAN] synchronizing package lists
[2017-06-06 21:21] [ALPM] transaction started
[2017-06-06 21:21] [ALPM] warning: /etc/pacman-mirrors.conf saved as /etc/pacman-mirrors.conf.pacsave
[2017-06-06 21:21] [ALPM] removed pacman-mirrors (4.1.4-1)
[2017-06-06 21:21] [ALPM] installed pacman-mirrors-dev (4.2.0dev.20170606-11)
[2017-06-06 21:21] [ALPM] transaction completed
[2017-06-06 21:21] [ALPM] running 'pacman-mirrors-install.hook'...
[2017-06-06 21:21] [ALPM-SCRIPTLET] Your existing configuration has been restored
[2017-06-06 21:21] [ALPM-SCRIPTLET] A new pacman-mirrors.conf is created as **/etc/pacman-mirrors.conf.201706/d**
[2017-06-06 21:21] [ALPM-SCRIPTLET] Please verify you're not missing any changes
[2017-06-06 21:21] [ALPM-SCRIPTLET] .: e[1;37mInfoe[1;m Downloading mirrors from repo.manjaro.org
[2017-06-06 21:21] [ALPM-SCRIPTLET] hint: use `pacman-mirrors` to generate and update your pacman mirrorlist.

Here is the outpu of: ls -lrta /etc/pacman*

-rw-r--r-- 1 root root 2.5K 06.06.2017 01:18 /etc/pacman.conf
-rw-r--r-- 1 root root  796 06.06.2017 21:25 /etc/pacman-mirrors.conf
-rw-r--r-- 1 root root  986 06.06.2017 20:40 /etc/pacman-mirrors.conf.20170606.backup
-rw-r--r-- 1 root root  796 06.06.2017 21:21 /etc/pacman-mirrors.conf.backup

/etc/pacman.d:
total 20K
drwxr-xr-x  3 root root 4.0K 02.06.2017 21:05 ./
drwxr-xr-x 68 root root 4.0K 06.06.2017 21:25 ../
drwxr-xr-x  5 root root 4.0K 03.06.2017 11:48 gnupg/
-rw-r--r--  1 root root 7.2K 06.06.2017 21:25 mirrorlist

I don’t have anything related to: “/etc/pacman-mirrors.conf.201706/d”, just a print/layout issue?

But for the rest it works as expected.

Edit:
Looked quickly at the pkgbuild and see no particular reason why it fails.


#3

thanks, the man page looks great!
i really like the detailed information you have put in there.

just 1 little problem (which is probably completely unrelated to pacman-mirrors):
the netzspielplatz.de mirror gives a ssl error when i try to use it via https

~ > sudo pacman-mirrors -y -c Germany -aP https                                                                                          
.: Info Protocols in config is changed
.: Info Downloading mirrors from repo.manjaro.org
.: Info Using custom mirror file
.: Info Querying mirrors - This may take some time
   0.066 Germany        : https://ftp.halifax.rwth-aachen.de/manjaro/
   ..... Germany        : https://mirror.netzspielplatz.de/manjaro/packages/
.: Error _ssl.c:733: The handshake operation timed out 'https://mirror.netzspielplatz.de/manjaro/packages/'

   0.073 Germany        : https://mirror.netcologne.de/manjaro/
   0.043 Germany        : https://repo.rhindon.net/manjaro/
   0.075 Germany        : https://repo.stdout.net/manjaro/
   0.056 Germany        : https://mirror.alpix.eu/manjaro/
   0.067 Germany        : https://manjaro-mirror-a.alpix.eu/
   0.037 Germany        : https://manjaro.ieji.de/
.: Info Writing mirror list
   Germany         : https://manjaro.ieji.de/unstable
   Germany         : https://repo.rhindon.net/manjaro/unstable
   Germany         : https://mirror.alpix.eu/manjaro/unstable
   Germany         : https://ftp.halifax.rwth-aachen.de/manjaro/unstable
   Germany         : https://manjaro-mirror-a.alpix.eu/unstable
   Germany         : https://mirror.netcologne.de/manjaro/unstable
   Germany         : https://repo.stdout.net/manjaro/unstable
.: Info Mirror list generated and saved to: /etc/pacman.d/mirrorlist

#4

Thanks

I think I have overlooked a (.) - there is one to many :slight_smile:
It was a formatting error / instead of %
And a missed closing "

This one is the one you see in bold white when running pacman-mirrors.
The logging though can’t do that so it writes the esc sequence too - that is a fact we must live with.


#5

I have seen that before - it is not a persistent error.

It is not an issue in pacman-mirrors. It seems related to netzspielplatz.de sometimes takes very long time to return the handshake.

Normally we use a timeout of 2 sec when querying a mirror for response time. But know that the SSL handshake takes longer that timeout is doubled when talking to SSL hosts.

If it times out in pacman-mirrors - you could double check by opening the url in a browser - It will probably fail there too.


#6

you are right, it actually works now.
i was using the “protocol” argument the first time yesterday and this error kept happening.

good choice!


#7