증상
MariaDB yum 설치 시 에러 발생
# vi /etc/yum.repos.d/MariaDB.repo
[mariadb]
name = MariaDB
baseurl = http://yum.mariadb.org/10.4/centos7-amd64
gpgkey=https://yum.mariadb.org/RPM-GPG-KEY-MariaDB
gpgcheck=1
# yum install -y MariaDB
Dependencies Resolved
==================================================================================================================================================================================================
Package Arch Version Repository Size
==================================================================================================================================================================================================
Installing:
MariaDB-compat x86_64 10.4.24-1.el7.centos mariadb 2.2 M
replacing mariadb-libs.x86_64 1:5.5.68-1.el7
MariaDB-server x86_64 10.4.24-1.el7.centos mariadb 26 M
Installing for dependencies:
MariaDB-client x86_64 10.4.24-1.el7.centos mariadb 12 M
MariaDB-common x86_64 10.4.24-1.el7.centos mariadb 81 k
boost-program-options x86_64 1.53.0-28.el7 base 156 k
galera-4 x86_64 26.4.11-1.el7.centos mariadb 9.9 M
socat x86_64 1.7.3.2-2.el7 base 290 k
Transaction Summary
==================================================================================================================================================================================================
Install 2 Packages (+5 Dependent packages)
Total size: 50 M
Downloading packages:
경고: /var/cache/yum/x86_64/7/mariadb/packages/MariaDB-common-10.4.24-1.el7.centos.x86_64.rpm: Header V4 DSA/SHA1 Signature, key ID 1bb943db: NOKEY
Retrieving key from https://yum.mariadb.org/RPM-GPG-KEY-MariaDB
GPG key retrieval failed: [Errno 14] curl#60 - "Peer's Certificate has expired."
원인
해당 리눅스 서버의 시간이 실제 시간으로 동기화되어있지 않아 KEY를 받아오지 못하는 상황
// 현재 날짜는 2022 02 17 일이지만 시간이 동기화 되어있지 않음
# date
2021. 07. 12. (월) 22:11:42 KST
해결
타임서버와 시간 동기화
# rdate -s zero.bora.net
# date
2022. 02. 17. (목) 02:46:12 KST
# yum install -y MariaDB
Installed:
MariaDB-compat.x86_64 0:10.4.24-1.el7.centos MariaDB-server.x86_64 0:10.4.24-1.el7.centos
Dependency Installed:
MariaDB-client.x86_64 0:10.4.24-1.el7.centos MariaDB-common.x86_64 0:10.4.24-1.el7.centos boost-program-options.x86_64 0:1.53.0-28.el7 galera-4.x86_64 0:26.4.11-1.el7.centos
socat.x86_64 0:1.7.3.2-2.el7
Replaced:
mariadb-libs.x86_64 1:5.5.68-1.el7