Monthly Archives

Tháng Bảy 2024

Công Việc IT,

Could not resolve host: mirrorlist.centos.org Centos 7

vi /etc/yum.repos.d/CentOS-Base.repo

[base]
name=CentOS-$releasever – Base
baseurl=http://vault.centos.org/7.9.2009/os/$basearch/
gpgcheck=1
gpgkey=file:///etc/pki/rpm-gpg/RPM-GPG-KEY-CentOS-7

[updates]
name=CentOS-$releasever – Updates
baseurl=http://vault.centos.org/7.9.2009/updates/$basearch/
gpgcheck=1
gpgkey=file:///etc/pki/rpm-gpg/RPM-GPG-KEY-CentOS-7

[extras]
name=CentOS-$releasever – Extras
baseurl=http://vault.centos.org/7.9.2009/extras/$basearch/
gpgcheck=1
gpgkey=file:///etc/pki/rpm-gpg/RPM-GPG-KEY-CentOS-7

[centosplus]
name=CentOS-$releasever – Plus
baseurl=http://vault.centos.org/7.9.2009/centosplus/$basearch/
gpgcheck=1
enabled=0
gpgkey=file:///etc/pki/rpm-gpg/RPM-GPG-KEY-CentOS-7

yum clean all

hoặc chạy lệnh sau
sed -i s/mirror.centos.org/vault.centos.org/g /etc/yum.repos.d/*.repo
sed -i s/^#.*baseurl=http/baseurl=http/g /etc/yum.repos.d/*.repo
sed -i s/^mirrorlist=http/#mirrorlist=http/g /etc/yum.repos.d/*.repo

Công Việc IT,

cách tạo file .p8 cho onesignal

The issue that I had was I couldn’t find the way to create the .p8 file and all methods gave me .cer file instead.

  1. Head to your Apple developer account
  2. Go to the keys section and click on the plus button (or click here):

⚠️ It is very important to select the keys section and NOT the certificate or identifiers. otherwise you will get the .cer file at last ??‍♂️

  1. Select the Apple push notification service:

⚠️ Note that since it is very powerful certificate, it is very limited and you can not have much of these. So if you already created one, you will face something like this image and you should use that file or just revoke the old one.

  1. Download the.p8 file and secure it somewhere.
Công Việc IT,

letsencrypt could not start HTTP server for challenge: listen tcp :80: bind: address already in use

lỗi renew ssl trong directadmin

sed -i ‘s/ss –no-header/ss/’ /usr/local/directadmin/scripts/letsencrypt.sh

 


2024/07/20 12:24:13 [INFO] [savingbooking.net, www.savingbooking.net] acme: Obtaining SAN certificate
2024/07/20 12:24:14 [INFO] [savingbooking.net] AuthURL: https://acme-v02.api.letsencrypt.org/acme/authz-v3/379368059547
2024/07/20 12:24:14 [INFO] [www.savingbooking.net] AuthURL: https://acme-v02.api.letsencrypt.org/acme/authz-v3/379368059557
2024/07/20 12:24:14 [INFO] [savingbooking.net] acme: Could not find solver for: tls-alpn-01
2024/07/20 12:24:14 [INFO] [savingbooking.net] acme: use http-01 solver
2024/07/20 12:24:14 [INFO] [www.savingbooking.net] acme: Could not find solver for: tls-alpn-01
2024/07/20 12:24:14 [INFO] [www.savingbooking.net] acme: use http-01 solver
2024/07/20 12:24:14 [INFO] [savingbooking.net] acme: Trying to solve HTTP-01
2024/07/20 12:24:29 [INFO] [savingbooking.net] The server validated our request
2024/07/20 12:24:29 [INFO] [www.savingbooking.net] acme: Trying to solve HTTP-01
2024/07/20 12:24:45 [INFO] Skipping deactivating of valid auth: https://acme-v02.api.letsencrypt.org/acme/authz-v3/379368059547
2024/07/20 12:24:45 [INFO] Deactivating auth: https://acme-v02.api.letsencrypt.org/acme/authz-v3/379368059557
2024/07/20 12:24:45 Could not obtain certificates:
	error: one or more domains had a problem:
[www.savingbooking.net] acme: error: 400 :: urn:ietf:params:acme:error:connection :: 103.249.100.5: Fetching https://www.savingbooking.net/.well-known/acme-challenge/lU6yOGK0h6koZs5vBD3PGC1eII4Q3134ukVq9FgVYO4: Timeout after connect (your server may be slow or overloaded), url: 
Failed to issue new certificate

tắt csf đi để tạm thời renew lại: csf -x
fix: chạy lệnh bên dưới để upgarde lên phiên bản mới nhất
csf -uf