記事ディレクトリ
序文
Wankeun を購入し、armbian 5.88 システムをインストールしました
。インターネットには接続できますが、ソフトウェアをインストールできません。清華ソース、アリソースなどを変更すると、すべて
証明書エラーが返され、その後百度が返されました。全員が使うと言った
sudo apt-get install ca-certificates
エラー:
root@aml:~/tmp# sudo apt-get install ca-certificates
Reading package lists... Done
Building dependency tree
Reading state information... Done
Package ca-certificates is not available, but is referred to by another package.
This may mean that the package is missing, has been obsoleted, or
is only available from another source
ca-certificates パッケージをインストールしますが、ca-certificates エラーでソフトウェアをインストールできません。言葉が出ません >_<
インストール パッケージを手動でダウンロードすると、インストールでもエラーが報告され、openssl のバージョンが低すぎる、私には 1.1.1 が必要、私のバージョンは 1.1.0 であるというエラーが表示され、また言葉を失いました >_<
諦めかけたとき、ネットで見つけたものをすべて試してみたところ、うまくいきました(方法はわかりません...)
まず自分の時間が正しいことを確認し、
システム時間を確認してください
root@aml:~# date
Thu May 4 14:09:23 CST 2023
現在時刻の出力は正確です。数時間遅れている場合は、他のタイムゾーンが使用される可能性があります。
タイムゾーンを更新する
timedatectl set-timezone Asia/Shanghai
おおよその動作:
1. http ソースを変更します (https も機能するはずだと思います)
#tsinghua source 清华源
deb http://mirrors.tuna.tsinghua.edu.cn/debian/ buster main contrib non-free
deb http://mirrors.tuna.tsinghua.edu.cn/debian/ buster-updates main contrib non-free
deb http://mirrors.tuna.tsinghua.edu.cn/debian/ buster-backports main contrib non-free
deb http://mirrors.tuna.tsinghua.edu.cn/debian-security buster/updates main contrib non-free
2. armbian.listを変更する
vim /etc/apt/sources.list.d/armbian.list
このファイルを次のように変更します。
deb https://mirrors.tuna.tsinghua.edu.cn/armbian stretch main stretch-utils stretch-desktop
3. 証明書の認証
apt install apt-transport-https ca-certificates
4. ソフトウェアのソースとインデックスを更新する
sudo apt update
sudo apt upgrade
5. 証明書のインストールと更新
sudo apt-get install ca-certificates【安装包】
sudo apt-get install --reinstall ca-certificates【重新安装包】
sudo update-ca-certificates
6.SSLを無効にする
export NODE_TLS_REJECT_UNAUTHORIZED=0
7. Web サイト証明書を手動で追加します (失敗したようです)
コード:
sudo wget https://mirrors.tuna.tsinghua.edu.cn/.well-known/ca-certificates.crt -O /etc/ssl/certs/ca-certificates.crt
sudo update-ca-certificates
説明:
8. debian パッケージの公開キーをインストールします (役に立たないようです)
コード:
sudo apt-key adv --keyserver hkp://keyserver.ubuntu.com:80 --recv-keys 648ACFD622F3D138 0E98404D386FA1D9
sudo apt-get update
説明:
ソフトウェアがインストールできることを確認します。
nginx-testをインストールする
sudo apt-get install nginx
y/nの入力を求められたらインストールできるので
yを入力、インストール後nginx -tと入力すれば以下の内容でOKです。
root@aml:~/tmp# nginx -t
nginx: the configuration file /etc/nginx/nginx.conf syntax is ok
nginx: configuration file /etc/nginx/nginx.conf test is successful
要約する
上記の方法の中には役に立たないものもあるはずで、どれが役に立たないのかはわかりません。
順序は必ずしも私と同じではありません
が、これは私が見つけることができるすべての方法です。
参考:
https://www.jianshu.com/p/621165b985b9
https://www.jianshu.com/p/7daddbe56648
https://chat.openai.com/