欢迎您访问程序员文章站本站旨在为大家提供分享程序员计算机编程知识!
您现在的位置是: 首页

wget命令出现Unable to establish SSL connection.的解决办法

程序员文章站 2022-05-31 15:36:33
...

报错:wget命令出现Unable to establish SSL connection.

[[email protected] ~]# wget https://github.com/jumpserver/jumpserver/releases/download/v2.1.0/quick_start.sh 
--2021-06-22 17:43:01--  https://github.com/jumpserver/jumpserver/releases/download/v2.1.0/quick_start.sh
Resolving github.com (github.com)... 52.74.223.119
Connecting to github.com (github.com)|52.74.223.119|:443... connected.
Unable to establish SSL connection.

解决方法:
加上跳过验证证书的参数“–no-check-certificate”
如下图:

[[email protected] ~]# wget https://github.com/jumpserver/jumpserver/releases/download/v2.1.0/quick_start.sh --no-check-certificate
--2021-06-22 17:43:01--  https://github.com/jumpserver/jumpserver/releases/download/v2.1.0/quick_start.sh
Resolving github.com (github.com)... 52.74.223.119
Connecting to github.com (github.com)|52.74.223.119|:443... connected.
Unable to establish SSL connection.

加上参数“–no-check-certificate”后也不管用
就要想到防火墙的问题(关键)

关掉防火墙并开机不自启
[[email protected] ~]# systemctl stop firewalld
[[email protected] ~]# systemctl disable firewalld
Removed symlink /etc/systemd/system/multi-user.target.wants/firewalld.service.
Removed symlink /etc/systemd/system/dbus-org.fedoraproject.FirewallD1.service.
[[email protected] ~]# wget https://github.com/jumpserver/jumpserver/releases/download/v2.1.0/quick_start.sh --no-check-certificate 
--2021-06-22 18:32:27--  https://github.com/jumpserver/jumpserver/releases/download/v2.1.0/quick_start.sh
Resolving github.com (github.com)... 52.74.223.119
Connecting to github.com (github.com)|52.74.223.119|:443... connected.
HTTP request sent, awaiting response... 302 Found
Location: https://github-releases.githubusercontent.com/21484781/6f563380-c79b-11ea-9162-15684126da9f?X-Amz-Algorithm=AWS4-....

即连接成功