2020/10/8 現在repo.msys2.orgは稼働しているようです.
よって以下の回避方法は不要と思われます.手順2で#をつけた行をもとに戻しておくといいかもしれません.
2020/10/6 現在repo.msys2.orgが落ちています
したがってパッケージのインストールや更新が出来ません...
不具合の回避方法
以下こちらの環境でやったことをまとめます.なお,設定ファイルは,当該ファイルを右クリックし,「プログラムから開く」を選び,メモ帳で開いて編集してください.
1. gpgフォルダの削除
-
mingw64.exe(Chocolateyを使ってインストールしている場合は`C:\tools\msys64\`にあります)を実行してターミナルを開く. -
以下のコマンドを入力して,破損している鍵が含まれる情報を削除,その他諸々.実行し終えたら,ターミナルを閉じる.
rm -r /etc/pacman.d/gnupg/
rm -r .gnupg/
gpg --refresh-keys
2. pacman関連設定ファイルの編集
(例えば)C:\tools\msys64\etc\pacman.d\にある,以下の設定ファイルを下の例を参考に,編集する.(Serverから始まる行のはじめの3行の先頭に#を追加するだけ.)
- mirrorlist.mingw32
- mirrorlist.mingw64
- mirrorlist.msys
##
## 32-bit Mingw-w64 repository mirrorlist
##
## Primary
## msys2.org
# Server = http://repo.msys2.org/mingw/i686/
# Server = https://sourceforge.net/projects/msys2/files/REPOS/MINGW/i686/
# Server = https://www2.futureware.at/~nickoe/msys2-mirror/mingw/i686/
Server = https://mirror.yandex.ru/mirrors/msys2/mingw/i686/
Server = https://mirrors.tuna.tsinghua.edu.cn/msys2/mingw/i686/
Server = http://mirrors.ustc.edu.cn/msys2/mingw/i686/
Server = http://mirror.bit.edu.cn/msys2/mingw/i686/
Server = https://mirror.selfnet.de/msys2/mingw/i686/
##
## 64-bit Mingw-w64 repository mirrorlist
##
## Primary
## msys2.org
# Server = http://repo.msys2.org/mingw/x86_64/
# Server = https://sourceforge.net/projects/msys2/files/REPOS/MINGW/x86_64/
# Server = https://www2.futureware.at/~nickoe/msys2-mirror/mingw/x86_64/
Server = https://mirror.yandex.ru/mirrors/msys2/mingw/x86_64/
Server = https://mirrors.tuna.tsinghua.edu.cn/msys2/mingw/x86_64/
Server = http://mirrors.ustc.edu.cn/msys2/mingw/x86_64/
Server = http://mirror.bit.edu.cn/msys2/mingw/x86_64/
Server = https://mirror.selfnet.de/msys2/mingw/x86_64/
##
## MSYS2 repository mirrorlist
##
## Primary
## msys2.org
# Server = http://repo.msys2.org/msys/$arch/
# Server = https://sourceforge.net/projects/msys2/files/REPOS/MSYS2/$arch/
# Server = https://www2.futureware.at/~nickoe/msys2-mirror/msys/$arch/
Server = https://mirror.yandex.ru/mirrors/msys2/msys/$arch/
Server = https://mirrors.tuna.tsinghua.edu.cn/msys2/msys/$arch/
Server = http://mirrors.ustc.edu.cn/msys2/msys/$arch/
Server = http://mirror.bit.edu.cn/msys2/msys/$arch/
Server = https://mirror.selfnet.de/msys2/msys/$arch/
3. gpg.confの編集
(例えば)C:\tools\msys64\etc\pacman.d\gnupg\gpg.confを以下のように編集.
(lock-neverの下の行にに,keyserver hkp://keys.gnupg.net:80)を追加するだけ.)
no-greeting
no-permission-warning
lock-never
keyserver hkp://keys.gnupg.net:80
keyserver-options timeout=10
keyserver-options import-clean
keyserver-options no-self-sigs-only
4. ターミナルでの作業
-
C:\tools\msys64\mingw64.exeを実行し,ターミナルを開く. -
以下のコマンドを実行する.
pacman-key --init
pacman-key --populate
pacman-key --refresh-keys
pacman -Syu
最後のコマンドで正常にパッケージデータベースが更新され,更新のあるパッケージのアップデートが出来ればOK.