遇到的问题:
[root@localhost src]# wget -c https://dl.google.com/go/go1.9.6.linux-amd64.tar.gz
--2018-05-04 02:42:54-- https://dl.google.com/go/go1.9.6.linux-amd64.tar.gz
Resolving dl.gocn.io... 120.132.12.8
Connecting to dl.gocn.io|120.132.12.8|:443... connected.
HTTP request sent, awaiting response... 301 Moved Permanently
Location: https://golang.google.cn/dl [following]
--2018-05-04 02:42:54-- https://golang.google.cn/dl
Resolving golang.google.cn... 203.208.43.87, 203.208.43.88, 203.208.43.79, ...
Connecting to golang.google.cn|203.208.43.87|:443... connected.
ERROR: certificate common name “google.com” doesn’t match requested host name “golang.google.cn”.
To connect to golang.google.cn insecurely, use ‘--no-check-certificate’.
[root@localhost src]#
问题解决方式:
the ceritificate problem when i use wget a file from java webside
reason is
wget before 1.12.1 do not support the Server Alternative Names extension
wget --version //check the version
so just update the wget
yum update wget
总结,执行:yum update wget
[root@localhost src]# yum update wget
Loaded plugins: fastestmirror, refresh-packagekit, security
Loading mirror speeds from cached hostfile
* atomic: mirrors.neusoft.edu.cn
* base: mirrors.aliyun.com
* extras: mirrors.aliyun.com
* updates: mirrors.163.com
atomic | 3.4 kB 00:00
base | 3.7 kB 00:00
extras | 3.4 kB 00:00
updates