谷歌翻译无法使用的处理方法

translate.googleapis.com 被墙,于是chrome浏览器自带的翻译用不了,解决方法如下:

hosts文件里添加
C:\Windows\System32\drivers\etc\hosts 

108.177.10.199 translate.googleapis.com
108.177.103.102 translate.googleapis.com
108.177.103.105 translate.googleapis.com
108.177.103.199 translate.googleapis.com
108.177.11.81 translate.googleapis.com
108.177.111.90 translate.googleapis.com
108.177.12.103 translate.googleapis.com

下面两个项目IP能ping通基本就能用(第一个项目的IP非常好用):
IPV4和IPv6一起使用


https://github.com/Ponderfly/GoogleTranslateIpCheck/tree/master/src/GoogleTranslateIpCheck/GoogleTranslateIpCheck
https://github.com/hcfyapp/google-translate-cn-ip/blob/master/packages/google-translate-ip/ips.txt

35.194.154.71		translate.googleapis.com
8.138.21.175		translate.googleapis.com
8.134.173.202		translate.googleapis.com
103.25.60.164		translate.googleapis.com
47.104.71.109		translate.googleapis.com
113.31.116.229		translate.googleapis.com
113.31.111.112		translate.googleapis.com
101.200.234.11		translate.googleapis.com
113.31.108.40		translate.googleapis.com
123.56.100.109		translate.googleapis.com
8.137.83.3		translate.googleapis.com
8.130.102.87		translate.googleapis.com
8.137.102.117		translate.googleapis.com
106.75.73.203		translate.googleapis.com
106.75.49.9		translate.googleapis.com
106.75.182.197		translate.googleapis.com
106.75.169.206		translate.googleapis.com
106.75.130.130		translate.googleapis.com
27.128.208.200		translate.googleapis.com
106.75.33.25		translate.googleapis.com
221.204.41.13		translate.googleapis.com
221.194.179.97		translate.googleapis.com
221.194.152.177		translate.googleapis.com
180.184.99.159		translate.googleapis.com
218.30.103.21		translate.googleapis.com
38.180.189.156		translate.googleapis.com
106.3.147.131		translate.googleapis.com
188.116.22.18		translate.googleapis.com
45.38.42.57		translate.googleapis.com
2.56.91.144		translate.googleapis.com
47.113.110.152		translate.googleapis.com
120.79.149.13		translate.googleapis.com
47.103.34.63		translate.googleapis.com
47.103.46.164		translate.googleapis.com
121.43.186.252		translate.googleapis.com
121.43.177.34		translate.googleapis.com
39.101.73.57		translate.googleapis.com
47.102.115.14		translate.googleapis.com
47.103.7.216		translate.googleapis.com
106.15.56.215		translate.googleapis.com
62.60.248.170		translate.googleapis.com
120.26.207.106		translate.googleapis.com
120.26.58.213		translate.googleapis.com
109.185.236.240		translate.googleapis.com
8.130.82.138		translate.googleapis.com
47.103.15.240		translate.googleapis.com
47.115.32.167		translate.googleapis.com
120.25.234.79		translate.googleapis.com
39.106.25.252		translate.googleapis.com
101.200.38.185		translate.googleapis.com
120.79.81.149		translate.googleapis.com
142.251.189.136		translate.googleapis.com
142.251.189.88		translate.googleapis.com
142.251.189.105		translate.googleapis.com
142.251.189.164		translate.googleapis.com
142.251.189.90		translate.googleapis.com
142.251.223.34		translate.googleapis.com
142.251.223.15		translate.googleapis.com
142.251.223.21		translate.googleapis.com
142.251.223.18		translate.googleapis.com
142.251.223.2		translate.googleapis.com
142.251.223.40		translate.googleapis.com
142.251.223.23		translate.googleapis.com
173.194.65.92		translate.googleapis.com
142.251.218.139		translate.googleapis.com
142.251.218.149		translate.googleapis.com
142.251.218.151		translate.googleapis.com
142.251.223.35		translate.googleapis.com
142.251.223.17		translate.googleapis.com
142.251.223.3		translate.googleapis.com
142.251.218.138		translate.googleapis.com
216.58.206.143		translate.googleapis.com
216.58.206.134		translate.googleapis.com
216.58.206.138		translate.googleapis.com
216.58.206.146		translate.googleapis.com
142.251.218.131		translate.googleapis.com
216.58.206.142		translate.googleapis.com
192.178.24.241		translate.googleapis.com
192.178.24.139		translate.googleapis.com
192.178.24.229		translate.googleapis.com
192.178.24.165		translate.googleapis.com
192.178.24.133		translate.googleapis.com
192.178.24.143		translate.googleapis.com
192.178.24.191		translate.googleapis.com
192.178.24.181		translate.googleapis.com
192.178.24.160		translate.googleapis.com
192.178.24.201		translate.googleapis.com
192.178.24.199		translate.googleapis.com
192.178.24.233		translate.googleapis.com
192.178.24.166		translate.googleapis.com
192.178.24.255		translate.googleapis.com
192.178.24.203		translate.googleapis.com
192.178.24.198		translate.googleapis.com
192.178.24.216		translate.googleapis.com
192.178.24.249		translate.googleapis.com
192.178.24.231		translate.googleapis.com
192.178.24.152		translate.googleapis.com
192.178.24.185		translate.googleapis.com
192.178.24.137		translate.googleapis.com
192.178.24.128		translate.googleapis.com
192.178.24.168		translate.googleapis.com
192.178.24.169		translate.googleapis.com
192.178.24.184		translate.googleapis.com
192.178.24.134		translate.googleapis.com
192.178.24.248		translate.googleapis.com
192.178.54.104		translate.googleapis.com
192.178.54.103		translate.googleapis.com
192.178.54.120		translate.googleapis.com
192.178.54.73		translate.googleapis.com
192.178.54.107		translate.googleapis.com
192.178.54.77		translate.googleapis.com
192.178.54.95		translate.googleapis.com
192.178.54.79		translate.googleapis.com
192.178.54.98		translate.googleapis.com
192.178.54.101		translate.googleapis.com
192.178.54.64		translate.googleapis.com
192.178.54.100		translate.googleapis.com
192.178.54.88		translate.googleapis.com
192.178.54.117		translate.googleapis.com
192.178.24.205		translate.googleapis.com
192.178.54.121		translate.googleapis.com
192.178.24.173		translate.googleapis.com
192.178.24.171		translate.googleapis.com
192.178.54.71		translate.googleapis.com
172.217.28.67		translate.googleapis.com
142.251.135.31		translate.googleapis.com
142.251.132.198		translate.googleapis.com
142.251.135.210		translate.googleapis.com
192.178.130.164		translate.googleapis.com
192.178.130.197		translate.googleapis.com
192.178.130.97		translate.googleapis.com
192.178.130.214		translate.googleapis.com
192.178.130.201		translate.googleapis.com
192.178.130.199		translate.googleapis.com
192.178.130.200		translate.googleapis.com
192.178.130.202		translate.googleapis.com
192.178.130.124		translate.googleapis.com
192.178.130.190		translate.googleapis.com
192.178.130.31		translate.googleapis.com
192.178.130.143		translate.googleapis.com
192.178.130.102		translate.googleapis.com
192.178.130.98		translate.googleapis.com
192.178.130.155		translate.googleapis.com
192.178.130.195		translate.googleapis.com
192.178.130.113		translate.googleapis.com
192.178.130.147		translate.googleapis.com
192.178.130.117		translate.googleapis.com
192.178.130.112		translate.googleapis.com
192.178.130.18		translate.googleapis.com
192.178.130.106		translate.googleapis.com
192.178.130.96		translate.googleapis.com
192.178.130.198		translate.googleapis.com
192.178.130.83		translate.googleapis.com
192.178.130.123		translate.googleapis.com
192.178.130.92		translate.googleapis.com
192.178.130.120		translate.googleapis.com
192.178.130.19		translate.googleapis.com
192.178.130.82		translate.googleapis.com
192.178.130.84		translate.googleapis.com
192.178.130.85		translate.googleapis.com
192.178.130.116		translate.googleapis.com
192.178.130.145		translate.googleapis.com
192.178.130.126		translate.googleapis.com
192.178.130.122		translate.googleapis.com
192.178.130.181		translate.googleapis.com
192.178.130.94		translate.googleapis.com
192.178.130.88		translate.googleapis.com
192.178.130.107		translate.googleapis.com
192.178.130.110		translate.googleapis.com
192.178.130.118		translate.googleapis.com
192.178.130.93		translate.googleapis.com
192.178.130.154		translate.googleapis.com
192.178.130.194		translate.googleapis.com
192.178.130.156		translate.googleapis.com
192.178.130.95		translate.googleapis.com
192.178.130.176		translate.googleapis.com
192.178.130.137		translate.googleapis.com
192.178.130.165		translate.googleapis.com
192.178.130.166		translate.googleapis.com
192.178.130.101		translate.googleapis.com
192.178.130.90		translate.googleapis.com
192.178.130.191		translate.googleapis.com
192.178.130.138		translate.googleapis.com
192.178.130.133		translate.googleapis.com
192.178.130.132		translate.googleapis.com
192.178.130.167		translate.googleapis.com
192.178.130.196		translate.googleapis.com
192.178.130.81		translate.googleapis.com
192.178.130.141		translate.googleapis.com
192.178.130.103		translate.googleapis.com
192.178.130.142		translate.googleapis.com
192.178.130.157		translate.googleapis.com
192.178.130.148		translate.googleapis.com
192.178.130.139		translate.googleapis.com
192.178.130.99		translate.googleapis.com
142.251.178.199		translate.googleapis.com
142.251.221.139		translate.googleapis.com
142.251.221.96		translate.googleapis.com
142.251.221.151		translate.googleapis.com
142.250.154.112		translate.googleapis.com
142.251.221.146		translate.googleapis.com
142.251.221.100		translate.googleapis.com
142.251.221.105		translate.googleapis.com
142.251.221.133		translate.googleapis.com
142.251.221.119		translate.googleapis.com
142.251.221.129		translate.googleapis.com
142.251.221.97		translate.googleapis.com
142.251.221.98		translate.googleapis.com
142.251.221.120		translate.googleapis.com
142.251.221.138		translate.googleapis.com
142.251.221.110		translate.googleapis.com
142.251.221.134		translate.googleapis.com
142.250.68.222		translate.googleapis.com
142.251.178.144		translate.googleapis.com
142.251.178.181		translate.googleapis.com
142.251.178.167		translate.googleapis.com
142.251.178.143		translate.googleapis.com
142.251.178.139		translate.googleapis.com
142.250.154.95		translate.googleapis.com
142.250.154.139		translate.googleapis.com
142.250.154.202		translate.googleapis.com
142.250.154.167		translate.googleapis.com
142.251.165.165		translate.googleapis.com
142.251.178.137		translate.googleapis.com
142.251.165.146		translate.googleapis.com
142.251.165.195		translate.googleapis.com
142.250.154.101		translate.googleapis.com
142.250.154.198		translate.googleapis.com
142.250.154.120		translate.googleapis.com
142.250.154.196		translate.googleapis.com
142.251.178.97		translate.googleapis.com
142.251.178.124		translate.googleapis.com
142.251.178.96		translate.googleapis.com
142.251.178.155		translate.googleapis.com
142.251.165.193		translate.googleapis.com
142.251.178.99		translate.googleapis.com
142.250.154.157		translate.googleapis.com
142.251.165.107		translate.googleapis.com
142.251.178.107		translate.googleapis.com
142.250.154.116		translate.googleapis.com
142.251.178.88		translate.googleapis.com
142.251.178.92		translate.googleapis.com
142.251.178.106		translate.googleapis.com
142.250.154.90		translate.googleapis.com
142.250.154.106		translate.googleapis.com
142.250.154.136		translate.googleapis.com
142.250.154.141		translate.googleapis.com
142.251.178.166		translate.googleapis.com
142.250.154.94		translate.googleapis.com
142.250.154.165		translate.googleapis.com
142.250.154.155		translate.googleapis.com
142.251.165.149		translate.googleapis.com
142.250.154.124		translate.googleapis.com
142.250.154.195		translate.googleapis.com
142.250.154.200		translate.googleapis.com
142.250.154.145		translate.googleapis.com
142.250.154.181		translate.googleapis.com
142.250.154.156		translate.googleapis.com
142.250.154.107		translate.googleapis.com
142.250.154.214		translate.googleapis.com
142.250.154.132		translate.googleapis.com
142.250.154.149		translate.googleapis.com
142.250.154.117		translate.googleapis.com
142.250.154.193		translate.googleapis.com
142.250.154.126		translate.googleapis.com
142.250.154.122		translate.googleapis.com
142.250.154.144		translate.googleapis.com
142.250.154.197		translate.googleapis.com
142.250.154.147		translate.googleapis.com
142.250.154.17		translate.googleapis.com
142.250.154.143		translate.googleapis.com
142.250.154.84		translate.googleapis.com
142.250.154.194		translate.googleapis.com
142.250.154.191		translate.googleapis.com
142.250.154.164		translate.googleapis.com
142.250.154.114		translate.googleapis.com
142.250.154.93		translate.googleapis.com
142.250.154.123		translate.googleapis.com
142.250.154.201		translate.googleapis.com
142.250.154.176		translate.googleapis.com
142.250.154.190		translate.googleapis.com
142.250.154.113		translate.googleapis.com
142.250.154.31		translate.googleapis.com
142.250.154.18		translate.googleapis.com
142.250.154.99		translate.googleapis.com
142.250.154.146		translate.googleapis.com
142.250.154.81		translate.googleapis.com
142.250.154.138		translate.googleapis.com
142.250.154.166		translate.googleapis.com
142.250.154.97		translate.googleapis.com
142.250.154.133		translate.googleapis.com
142.250.154.152		translate.googleapis.com
142.250.154.102		translate.googleapis.com
142.250.154.91		translate.googleapis.com
142.251.178.197		translate.googleapis.com
142.250.154.142		translate.googleapis.com
142.250.154.96		translate.googleapis.com
142.251.178.117		translate.googleapis.com
142.251.165.112		translate.googleapis.com
142.251.178.110		translate.googleapis.com
142.250.154.83		translate.googleapis.com
142.251.221.141		translate.googleapis.com
142.251.221.135		translate.googleapis.com
142.251.221.128		translate.googleapis.com
142.251.221.107		translate.googleapis.com
142.250.196.46		translate.googleapis.com
142.251.178.113		translate.googleapis.com
64.233.177.191		translate.googleapis.com
142.251.178.100		translate.googleapis.com
142.251.165.196		translate.googleapis.com
142.251.178.91		translate.googleapis.com
142.251.178.98		translate.googleapis.com
142.251.165.83		translate.googleapis.com
142.251.165.136		translate.googleapis.com
142.251.165.145		translate.googleapis.com
142.251.165.141		translate.googleapis.com
142.251.165.148		translate.googleapis.com
142.251.165.147		translate.googleapis.com
142.251.165.19		translate.googleapis.com
142.251.165.198		translate.googleapis.com
142.251.165.143		translate.googleapis.com
142.251.165.93		translate.googleapis.com
142.251.178.189		translate.googleapis.com
142.251.178.93		translate.googleapis.com
142.251.165.17		translate.googleapis.com
142.251.165.103		translate.googleapis.com
142.251.178.104		translate.googleapis.com
173.194.194.97		translate.googleapis.com
64.233.165.118		translate.googleapis.com
142.251.165.118		translate.googleapis.com
142.250.77.195		translate.googleapis.com
142.251.178.152		translate.googleapis.com
142.251.165.124		translate.googleapis.com
74.125.135.99		translate.googleapis.com
74.125.202.103		translate.googleapis.com
172.217.165.21		translate.googleapis.com
142.250.157.157		translate.googleapis.com
142.251.12.120		translate.googleapis.com
142.251.221.131		translate.googleapis.com
172.217.161.233		translate.googleapis.com
142.250.195.227		translate.googleapis.com
142.250.182.142		translate.googleapis.com
74.125.202.156		translate.googleapis.com
74.125.202.144		translate.googleapis.com
74.125.71.133		translate.googleapis.com
74.125.71.137		translate.googleapis.com
74.125.206.96		translate.googleapis.com
142.250.183.238		translate.googleapis.com
142.251.178.19		translate.googleapis.com
142.250.190.143		translate.googleapis.com
64.233.165.191		translate.googleapis.com
142.250.71.3		translate.googleapis.com
142.251.135.131		translate.googleapis.com
142.251.165.95		translate.googleapis.com
142.251.178.18		translate.googleapis.com
173.194.195.147		translate.googleapis.com
64.233.163.191		translate.googleapis.com
142.251.178.17		translate.googleapis.com
142.251.8.92		translate.googleapis.com
108.177.125.157		translate.googleapis.com
142.250.199.77		translate.googleapis.com
216.239.38.180		translate.googleapis.com
142.250.199.66		translate.googleapis.com
142.250.157.156		translate.googleapis.com
142.251.12.91		translate.googleapis.com
172.217.175.18		translate.googleapis.com
142.251.42.164		translate.googleapis.com
108.177.97.154		translate.googleapis.com
64.233.188.97		translate.googleapis.com
108.177.125.81		translate.googleapis.com
142.250.66.66		translate.googleapis.com
108.177.97.155		translate.googleapis.com
108.177.97.81		translate.googleapis.com
142.250.203.110		translate.googleapis.com
172.217.168.10		translate.googleapis.com
142.251.36.8		translate.googleapis.com
64.233.165.198		translate.googleapis.com
108.177.14.113		translate.googleapis.com
142.251.12.103		translate.googleapis.com
74.125.71.196		translate.googleapis.com
142.251.165.190		translate.googleapis.com
142.251.178.133		translate.googleapis.com
142.251.178.132		translate.googleapis.com
142.250.195.141		translate.googleapis.com
142.250.157.149		translate.googleapis.com
64.233.169.96		translate.googleapis.com
172.253.112.18		translate.googleapis.com
142.250.69.74		translate.googleapis.com
142.251.165.191		translate.googleapis.com
142.250.69.142		translate.googleapis.com
142.250.69.146		translate.googleapis.com
142.250.69.133		translate.googleapis.com
142.251.165.120		translate.googleapis.com
172.217.218.133		translate.googleapis.com
142.250.69.134		translate.googleapis.com
142.250.69.79		translate.googleapis.com
142.250.69.158		translate.googleapis.com
74.125.206.93		translate.googleapis.com
142.251.165.101		translate.googleapis.com
142.251.165.94		translate.googleapis.com
142.250.69.88		translate.googleapis.com
142.250.69.94		translate.googleapis.com
142.250.69.143		translate.googleapis.com
142.251.1.136		translate.googleapis.com
64.233.169.100		translate.googleapis.com
172.253.116.92		translate.googleapis.com
173.194.220.101		translate.googleapis.com
64.233.188.155		translate.googleapis.com
142.250.199.75		translate.googleapis.com
142.251.8.189		translate.googleapis.com
142.250.204.37		translate.googleapis.com
172.217.175.23		translate.googleapis.com
172.217.175.242		translate.googleapis.com
216.58.200.138		translate.googleapis.com
142.250.196.174		translate.googleapis.com
142.251.8.199		translate.googleapis.com
142.250.157.133		translate.googleapis.com
172.253.117.118		translate.googleapis.com
74.125.142.116		translate.googleapis.com
74.125.135.17		translate.googleapis.com
172.217.164.103		translate.googleapis.com
173.194.199.94		translate.googleapis.com
172.253.58.94		translate.googleapis.com
142.251.42.197		translate.googleapis.com
74.125.202.104		translate.googleapis.com
142.250.199.161		translate.googleapis.com
172.253.115.149		translate.googleapis.com
142.251.2.139		translate.googleapis.com
74.125.201.93		translate.googleapis.com
74.125.206.144		translate.googleapis.com
74.125.196.124		translate.googleapis.com
74.125.127.18		translate.googleapis.com
173.194.70.114		translate.googleapis.com
142.250.176.6		translate.googleapis.com
74.125.21.191		translate.googleapis.com
142.250.72.104		translate.googleapis.com
172.253.120.142		translate.googleapis.com
74.125.21.98		translate.googleapis.com
74.125.196.195		translate.googleapis.com
173.194.77.81		translate.googleapis.com
142.251.2.100		translate.googleapis.com
142.250.145.139		translate.googleapis.com
172.217.197.123		translate.googleapis.com
173.194.79.200		translate.googleapis.com
142.250.27.113		translate.googleapis.com
74.125.139.97		translate.googleapis.com
74.125.206.146		translate.googleapis.com
74.125.206.154		translate.googleapis.com
142.251.1.102		translate.googleapis.com
74.125.71.152		translate.googleapis.com
142.251.165.152		translate.googleapis.com
172.217.168.227		translate.googleapis.com
172.217.168.215		translate.googleapis.com
216.58.214.4		translate.googleapis.com
173.194.68.97		translate.googleapis.com
74.125.71.199		translate.googleapis.com
142.251.40.104		translate.googleapis.com
142.251.165.194		translate.googleapis.com
216.58.213.8		translate.googleapis.com
173.194.222.138		translate.googleapis.com
74.125.140.113		translate.googleapis.com
108.177.127.214		translate.googleapis.com
172.217.222.92		translate.googleapis.com
172.253.115.93		translate.googleapis.com
74.125.133.155		translate.googleapis.com
74.125.201.91		translate.googleapis.com
142.250.145.113		translate.googleapis.com
142.251.165.164		translate.googleapis.com
142.250.141.100		translate.googleapis.com
64.233.189.148		translate.googleapis.com
172.217.16.210		translate.googleapis.com
64.233.189.133		translate.googleapis.com
142.251.40.202		translate.googleapis.com
172.217.197.91		translate.googleapis.com
142.251.1.190		translate.googleapis.com
172.217.19.72		translate.googleapis.com
142.250.66.10		translate.googleapis.com
74.125.193.152		translate.googleapis.com
64.233.165.97		translate.googleapis.com
142.251.1.93		translate.googleapis.com
64.233.165.132		translate.googleapis.com
142.251.165.110		translate.googleapis.com
108.177.97.141		translate.googleapis.com
172.217.169.138		translate.googleapis.com
172.217.17.104		translate.googleapis.com
172.217.192.149		translate.googleapis.com
172.217.192.92		translate.googleapis.com
142.250.183.106		translate.googleapis.com
172.217.204.104		translate.googleapis.com
172.253.122.154		translate.googleapis.com
142.251.165.106		translate.googleapis.com
172.253.62.88		translate.googleapis.com
142.251.165.104		translate.googleapis.com
142.250.110.102		translate.googleapis.com
74.125.206.117		translate.googleapis.com
142.251.165.201		translate.googleapis.com
74.125.206.142		translate.googleapis.com
142.251.165.99		translate.googleapis.com
142.250.187.139		translate.googleapis.com
74.125.206.137		translate.googleapis.com
108.177.97.132		translate.googleapis.com
142.250.196.78		translate.googleapis.com
172.217.164.49		translate.googleapis.com
172.217.164.46		translate.googleapis.com
172.217.164.62		translate.googleapis.com
172.217.164.55		translate.googleapis.com
172.217.164.32		translate.googleapis.com
172.217.164.40		translate.googleapis.com
142.250.70.206		translate.googleapis.com
74.125.206.136		translate.googleapis.com
74.125.206.100		translate.googleapis.com
108.177.127.133		translate.googleapis.com
64.233.162.191		translate.googleapis.com
142.250.192.10		translate.googleapis.com
172.217.21.42		translate.googleapis.com
142.251.143.195		translate.googleapis.com
74.125.206.138		translate.googleapis.com
172.253.116.199		translate.googleapis.com
108.177.14.101		translate.googleapis.com
142.250.69.238		translate.googleapis.com
64.233.162.94		translate.googleapis.com
142.251.221.109		translate.googleapis.com
142.251.39.3		translate.googleapis.com
74.125.142.102		translate.googleapis.com
142.250.102.94		translate.googleapis.com
172.217.175.231		translate.googleapis.com
142.250.199.130		translate.googleapis.com
142.251.46.232		translate.googleapis.com
172.217.167.227		translate.googleapis.com
216.58.214.15		translate.googleapis.com
74.125.142.137		translate.googleapis.com
142.251.8.141		translate.googleapis.com
142.250.188.1		translate.googleapis.com
172.217.174.226		translate.googleapis.com
172.217.166.14		translate.googleapis.com
142.250.192.206		translate.googleapis.com
173.194.210.120		translate.googleapis.com
74.125.26.92		translate.googleapis.com
74.125.133.156		translate.googleapis.com
172.217.165.129		translate.googleapis.com
172.253.116.106		translate.googleapis.com
74.125.26.136		translate.googleapis.com
172.217.203.99		translate.googleapis.com
142.251.35.227		translate.googleapis.com
172.217.204.195		translate.googleapis.com
142.250.196.67		translate.googleapis.com
74.125.199.106		translate.googleapis.com
142.250.179.98		translate.googleapis.com
172.253.120.167		translate.googleapis.com
74.125.140.95		translate.googleapis.com
172.217.168.34		translate.googleapis.com
142.250.182.78		translate.googleapis.com
172.217.171.225		translate.googleapis.com
172.253.116.105		translate.googleapis.com
142.250.200.67		translate.googleapis.com
142.251.36.131		translate.googleapis.com
74.125.131.101		translate.googleapis.com
142.250.184.174		translate.googleapis.com
142.250.180.174		translate.googleapis.com
172.217.169.163		translate.googleapis.com
172.217.169.174		translate.googleapis.com
172.217.203.97		translate.googleapis.com
173.194.67.117		translate.googleapis.com
142.251.40.99		translate.googleapis.com
142.250.200.78		translate.googleapis.com
142.250.64.129		translate.googleapis.com
142.250.74.99		translate.googleapis.com
142.250.183.3		translate.googleapis.com
142.250.141.139		translate.googleapis.com
142.250.80.67		translate.googleapis.com
142.250.80.78		translate.googleapis.com
142.250.74.206		translate.googleapis.com
142.250.180.78		translate.googleapis.com
142.250.4.181		translate.googleapis.com
142.250.107.95		translate.googleapis.com
142.250.72.35		translate.googleapis.com
142.250.64.99		translate.googleapis.com
142.250.76.110		translate.googleapis.com
64.233.188.91		translate.googleapis.com
108.177.125.142		translate.googleapis.com
142.250.183.74		translate.googleapis.com
74.125.138.196		translate.googleapis.com
74.125.71.197		translate.googleapis.com
142.250.9.181		translate.googleapis.com
172.253.122.114		translate.googleapis.com
142.250.65.226		translate.googleapis.com
142.250.65.200		translate.googleapis.com
142.250.66.163		translate.googleapis.com
74.125.140.154		translate.googleapis.com
74.125.140.155		translate.googleapis.com
173.194.76.155		translate.googleapis.com
142.250.147.113		translate.googleapis.com
64.233.163.94		translate.googleapis.com
173.194.220.97		translate.googleapis.com
142.250.200.99		translate.googleapis.com
142.251.35.225		translate.googleapis.com
74.125.201.164		translate.googleapis.com
142.251.179.90		translate.googleapis.com
142.250.157.137		translate.googleapis.com
172.217.17.36		translate.googleapis.com
172.217.169.196		translate.googleapis.com
142.250.71.10		translate.googleapis.com
142.251.5.154		translate.googleapis.com
108.177.11.105		translate.googleapis.com
108.177.11.103		translate.googleapis.com
142.251.36.99		translate.googleapis.com
74.125.206.120		translate.googleapis.com
108.177.127.95		translate.googleapis.com
142.251.32.14		translate.googleapis.com
216.58.215.99		translate.googleapis.com
142.251.37.228		translate.googleapis.com
142.250.96.94		translate.googleapis.com
142.251.2.136		translate.googleapis.com
142.250.72.14		translate.googleapis.com
172.217.3.142		translate.googleapis.com
142.250.27.156		translate.googleapis.com
173.194.70.100		translate.googleapis.com
172.217.168.174		translate.googleapis.com
142.250.207.5		translate.googleapis.com
142.250.66.49		translate.googleapis.com
142.250.150.113		translate.googleapis.com
216.58.196.168		translate.googleapis.com
74.125.142.138		translate.googleapis.com
172.217.13.8		translate.googleapis.com
172.217.13.10		translate.googleapis.com
172.217.13.3		translate.googleapis.com
172.217.13.15		translate.googleapis.com
172.217.13.18		translate.googleapis.com
172.217.13.30		translate.googleapis.com
172.217.13.14		translate.googleapis.com
172.217.13.24		translate.googleapis.com
108.177.125.18		translate.googleapis.com
142.251.43.67		translate.googleapis.com
74.125.142.155		translate.googleapis.com
142.251.8.148		translate.googleapis.com
108.177.98.118		translate.googleapis.com
74.125.195.176		translate.googleapis.com
172.217.14.87		translate.googleapis.com
173.194.70.137		translate.googleapis.com
74.125.195.110		translate.googleapis.com
142.250.27.154		translate.googleapis.com
172.217.15.248		translate.googleapis.com
172.253.58.97		translate.googleapis.com
173.194.70.102		translate.googleapis.com
173.194.78.165		translate.googleapis.com
142.251.36.36		translate.googleapis.com
172.217.214.96		translate.googleapis.com
142.251.16.103		translate.googleapis.com
173.194.204.17		translate.googleapis.com
172.217.165.203		translate.googleapis.com
108.177.12.19		translate.googleapis.com
172.217.203.92		translate.googleapis.com
172.253.126.193		translate.googleapis.com
173.194.77.102		translate.googleapis.com
142.251.16.147		translate.googleapis.com
172.217.167.68		translate.googleapis.com
142.251.16.106		translate.googleapis.com
172.217.197.103		translate.googleapis.com
172.253.112.191		translate.googleapis.com
173.194.69.181		translate.googleapis.com
172.253.115.91		translate.googleapis.com
173.194.193.96		translate.googleapis.com
142.250.184.228		translate.googleapis.com
173.194.221.154		translate.googleapis.com
216.58.212.164		translate.googleapis.com
142.250.181.206		translate.googleapis.com
74.125.71.195		translate.googleapis.com
142.251.36.40		translate.googleapis.com
66.102.1.110		translate.googleapis.com
173.194.69.124		translate.googleapis.com
172.217.215.92		translate.googleapis.com
172.217.194.19		translate.googleapis.com
142.251.143.174		translate.googleapis.com
173.194.73.195		translate.googleapis.com
173.194.222.91		translate.googleapis.com
173.194.221.95		translate.googleapis.com
216.58.207.228		translate.googleapis.com
216.58.207.235		translate.googleapis.com
142.250.150.102		translate.googleapis.com
172.217.169.103		translate.googleapis.com
142.250.78.195		translate.googleapis.com
172.217.17.79		translate.googleapis.com
64.233.161.98		translate.googleapis.com
173.194.222.190		translate.googleapis.com
108.177.127.17		translate.googleapis.com
66.102.1.112		translate.googleapis.com
142.250.4.214		translate.googleapis.com
172.217.174.72		translate.googleapis.com
172.217.165.134		translate.googleapis.com
172.217.215.84		translate.googleapis.com
172.217.168.197		translate.googleapis.com
172.217.218.195		translate.googleapis.com
172.253.113.190		translate.googleapis.com
108.177.119.176		translate.googleapis.com
172.253.122.198		translate.googleapis.com
172.217.203.152		translate.googleapis.com
172.217.171.247		translate.googleapis.com
64.233.163.122		translate.googleapis.com
64.233.190.144		translate.googleapis.com
142.251.12.82		translate.googleapis.com
74.125.132.144		translate.googleapis.com
172.217.174.183		translate.googleapis.com
74.125.195.198		translate.googleapis.com
74.125.20.198		translate.googleapis.com
172.217.174.79		translate.googleapis.com
172.253.58.157		translate.googleapis.com
108.177.104.123		translate.googleapis.com
172.253.58.200		translate.googleapis.com
216.58.200.201		translate.googleapis.com
74.125.134.198		translate.googleapis.com
172.253.112.133		translate.googleapis.com
172.217.214.194		translate.googleapis.com
74.125.199.91		translate.googleapis.com
173.194.175.110		translate.googleapis.com
172.253.122.195		translate.googleapis.com
172.217.197.122		translate.googleapis.com
172.253.115.201		translate.googleapis.com
172.217.165.128		translate.googleapis.com
172.217.215.133		translate.googleapis.com
172.253.113.81		translate.googleapis.com
173.194.79.117		translate.googleapis.com
172.253.112.143		translate.googleapis.com
74.125.141.122		translate.googleapis.com
172.217.204.105		translate.googleapis.com
172.217.203.137		translate.googleapis.com
74.125.196.167		translate.googleapis.com
172.217.197.198		translate.googleapis.com
172.253.62.118		translate.googleapis.com
172.253.122.106		translate.googleapis.com
172.217.203.199		translate.googleapis.com
74.125.196.189		translate.googleapis.com
172.253.113.181		translate.googleapis.com
172.253.122.31		translate.googleapis.com
172.217.222.31		translate.googleapis.com
66.102.1.176		translate.googleapis.com
172.253.120.88		translate.googleapis.com
172.217.169.68		translate.googleapis.com
172.217.222.83		translate.googleapis.com
172.217.214.196		translate.googleapis.com
172.217.17.4		translate.googleapis.com
172.217.203.103		translate.googleapis.com
172.253.116.194		translate.googleapis.com
74.125.195.200		translate.googleapis.com
173.194.175.117		translate.googleapis.com
74.125.26.195		translate.googleapis.com
172.217.192.112		translate.googleapis.com
173.194.210.88		translate.googleapis.com
172.217.171.200		translate.googleapis.com
173.194.73.104		translate.googleapis.com
172.253.122.147		translate.googleapis.com
108.177.122.31		translate.googleapis.com
172.217.197.190		translate.googleapis.com
108.177.125.201		translate.googleapis.com
108.177.97.31		translate.googleapis.com
172.217.161.207		translate.googleapis.com
74.125.197.124		translate.googleapis.com
142.250.4.165		translate.googleapis.com
108.177.9.88		translate.googleapis.com
172.253.58.136		translate.googleapis.com
108.177.104.181		translate.googleapis.com
66.102.1.196		translate.googleapis.com
108.177.9.91		translate.googleapis.com
172.217.204.124		translate.googleapis.com
64.233.185.155		translate.googleapis.com
142.250.31.113		translate.googleapis.com
64.233.184.196		translate.googleapis.com
64.233.184.181		translate.googleapis.com
172.217.218.105		translate.googleapis.com
108.177.11.201		translate.googleapis.com
172.253.126.19		translate.googleapis.com
108.177.122.145		translate.googleapis.com
172.253.127.107		translate.googleapis.com
172.253.112.104		translate.googleapis.com
66.102.1.195		translate.googleapis.com
172.217.171.224		translate.googleapis.com
108.177.14.116		translate.googleapis.com
172.217.17.110		translate.googleapis.com
142.250.183.174		translate.googleapis.com
172.253.116.198		translate.googleapis.com
172.253.58.133		translate.googleapis.com
172.253.58.152		translate.googleapis.com
172.253.62.196		translate.googleapis.com
173.194.175.17		translate.googleapis.com
74.125.133.202		translate.googleapis.com
172.253.122.149		translate.googleapis.com
172.217.172.79		translate.googleapis.com
172.217.192.123		translate.googleapis.com
74.125.192.193		translate.googleapis.com
216.58.196.160		translate.googleapis.com
2001:67c:2960:6464::d8ef:2003		translate.googleapis.com
2001:67c:2960:6464::d8ef:2228		translate.googleapis.com
2001:67c:2960:6464::d8ef:2036		translate.googleapis.com
2001:67c:2960:6464::d8ef:2027		translate.googleapis.com
2001:67c:2960:6464::d8ef:2025		translate.googleapis.com
2001:67c:2960:6464::d8ef:2058		translate.googleapis.com
2001:67c:2960:6464::d8ef:2038		translate.googleapis.com
2001:67c:2960:6464::d8ef:2224		translate.googleapis.com
2001:67c:2960:6464::d8ef:2039		translate.googleapis.com
2001:67c:2960:6464::d8ef:2071		translate.googleapis.com
2001:67c:2960:6464::d8ef:2006		translate.googleapis.com
2001:67c:2960:6464::d8ef:2070		translate.googleapis.com
2001:67c:2960:6464::d8ef:2037		translate.googleapis.com
2001:67c:2960:6464::d8ef:2045		translate.googleapis.com
2001:67c:2960:6464::d8ef:2049		translate.googleapis.com
2001:67c:2960:6464::d8ef:2076		translate.googleapis.com
2001:67c:2960:6464::d8ef:2048		translate.googleapis.com
2001:67c:2960:6464::d8ef:2028		translate.googleapis.com
2001:67c:2960:6464::d8ef:118c		translate.googleapis.com
2001:67c:2960:6464::d8ef:a45f		translate.googleapis.com
2001:67c:2960:6464::d8ef:ac54		translate.googleapis.com
2001:67c:2960:6464::d8ef:a136		translate.googleapis.com
2001:67c:2960:6464::d8ef:3f2		translate.googleapis.com
2001:67c:2960:6464::d8ef:2049		translate.googleapis.com
2001:67c:2960:6464::d8ef:24a7		translate.googleapis.com
2001:67c:2960:6464::d8ef:263c		translate.googleapis.com
2001:67c:2960:6464::d8ef:2070		translate.googleapis.com
2001:67c:2960:6464::d8ef:22b7		translate.googleapis.com
2001:67c:2960:6464::d8ef:24a0		translate.googleapis.com
2001:67c:2960:6464::d8ef:2c77		translate.googleapis.com
2001:67c:2960:6464::d8ef:20b2		translate.googleapis.com
2001:67c:2960:6464::d8ef:2c13		translate.googleapis.com
2001:67c:2960:6464::d8ef:248f		translate.googleapis.com
2001:4860:4802:32::179		translate.googleapis.com
2001:4860:4802:32::45		translate.googleapis.com
2607:f8b0:4007:809::2017		translate.googleapis.com
2607:f8b0:4007:80a::2017		translate.googleapis.com
2607:f8b0:4009:808::2017		translate.googleapis.com
2607:f8b0:4008:807::2017		translate.googleapis.com
2607:f8b0:400d:c04::76		translate.googleapis.com
2607:f8b0:400d:c01::76		translate.googleapis.com
2607:f8b0:4008:809::2000		translate.googleapis.com
2607:f8b0:4008:808::2017		translate.googleapis.com
2a00:1450:400e:803::2015		translate.googleapis.com
2a00:1450:4009:80a::2017		translate.googleapis.com
2a00:1450:4006:804::2017		translate.googleapis.com
2a00:1450:4010:c0a::c7		translate.googleapis.com
2a00:1450:4010:c09::c3		translate.googleapis.com
2a00:1450:4003:808::201f		translate.googleapis.com
2a00:1450:4003:808::2017		translate.googleapis.com
2a00:1450:4010:c06::c4		translate.googleapis.com
2607:f8b0:4009:80a::2017		translate.googleapis.com
2a00:1450:4010:c0b::c7		translate.googleapis.com
2a00:1450:4010:c0d::c3		translate.googleapis.com
2a00:1450:4010:c03::c7		translate.googleapis.com
2a00:1450:4002:809::2017		translate.googleapis.com
2404:6800:4008:c13::5a		translate.googleapis.com
2404:6800:4008:c13::c6		translate.googleapis.com
2404:6800:4008:c13::c2		translate.googleapis.com

Debian10修改IPV6主机的DNS64(可访问IPV4网站) + 彻底修改debian10系统DNS

在 Debian 系统中修改 DNS 服务器地址通常涉及编辑 /etc/resolv.conf 文件。然而,从 Debian 版本 Buster(10)开始以及后续版本,包括 Bullseye(11)和 Bookworm(假设为未来版本),该文件可能由网络管理服务(如 systemd-resolved)自动管理,并且直接编辑它可能不是持久化更改的推荐方式。

对于使用 systemd-resolved 的系统:
临时修改: 如果系统使用了 systemd-resolved,可以通过命令行工具 resolvectl 来临时设置DNS服务器:

sudo resolvectl dns eth0 8.8.8.8 8.8.4.4

其中eth0是网卡名称

永久修改: 若要永久性地更改配置,应编辑 /etc/systemd/resolved.conf 文件并添加或修改 DNS= 行下的DNS服务器列表:

sudo nano /etc/systemd/resolved.conf

在其中找到或添加如下内容:


nameserver 8.8.8.8
nameserver 8.8.4.4
echo -e "nameserver 8.8.8.8\nnameserver 8.8.4.4" > /etc/systemd/resolved.conf
或者
nameserver 1.1.1.1
nameserver 1.0.0.1
echo -e "nameserver 1.1.1.1\nnameserver 1.0.0.1" > /etc/systemd/resolved.conf

修改后,重启 systemd-resolved 服务以应用更改:

sudo systemctl restart systemd-resolved.service

如果没有使用systemd-resolved 的系统,则可以直接修改 /etc/resolv.con文件

打开修改文件

nano /etc/resolv.conf

纯IPV6主机修改DNS64(NAT64),可访问IPV4地址

nameserver 2001:67c:2b0::4 
nameserver 2001:67c:27e4::64

最后查看是否生效:

cat /etc/resolv.conf

Cloudflare DNS64:


nameserver 2606:4700:4700::64
nameserver 2606:4700:4700::6400
echo -e "nameserver 2606:4700:4700::64\nnameserver 2606:4700:4700::6400" > /etc/resolv.conf
nameserver 2606:4700:4700::1111
nameserver 2606:4700:4700::1001
echo -e "nameserver 2606:4700:4700::1111\nnameserver 2606:4700:4700::1001" > /etc/resolv.conf

Quad9 DNS:


nameserver 2620:fe::fe
nameserver 2620:fe::9
echo -e "nameserver 2620:fe::fe\nnameserver 2620:fe::9" > /etc/resolv.conf

Go6Lab:


nameserver 2001:67c:27e4:15::6411
nameserver 2001:67c:27e4::64
echo -e "nameserver 2001:67c:27e4:15::6411\nnameserver 2001:67c:27e4::64" > /etc/resolv.conf

google nat64:


nameserver 2001:4860:4860::6464
nameserver 2001:4860:4860::64
nameserver 2001:4860:4860:0:0:0:0:6464
nameserver 2001:4860:4860:0:0:0:0:64
echo -e "nameserver 2001:4860:4860::6464\nnameserver 2001:4860:4860::64" > /etc/resolv.conf

nat64和DNS64不能同时使用:


nameserver 2001:4860:4860::8888
nameserver 2001:4860:4860::8844
echo -e "nameserver 2001:4860:4860::8888\nnameserver 2001:4860:4860::8844" > /etc/resolv.conf

Linux本地测速方法

speedtest 是一款使用 python 语言编写的轻量级的 linux 命令行测速工具,在 python2 以及 python3 的环境下都可以运行,基于 speedtest.net 基础框架来测量网络的上下行数据,安装也很简单,只要下载对应的 python 文件执行即可。

汇总处理:


wget https://raw.githubusercontent.com/sivel/speedtest-cli/master/speedtest.py && \
chmod a+rx speedtest.py && \
chown root:root speedtest.py && \
mv speedtest.py /usr/local/bin/speedtest && \
sudo ln -s /usr/bin/python3 /usr/bin/python && \
speedtest 
 

测速方法
1、先下载脚本(wget 下载或者下载好上传到服务器上)

wget https://raw.githubusercontent.com/sivel/speedtest-cli/master/speedtest.py 

2、为脚本授权

chmod a+rx speedtest.py
chown root:root speedtest.py 

3、移至本机运行目录

mv speedtest.py /usr/local/bin/speedtest 

4、执行测速

speedtest 

如果出现找不到 python 环境的错误,对应以下解决即可!


[root@ecs-test ~]# speedtest 
/usr/bin/env: ‘python’: No such file or directory
[root@ecs-test ~]# python3 --version
Python 3.6.8
[root@ecs-test ~]# 
[root@ecs-test ~]# whereis python3
python3: /usr/bin/python3.6 /usr/bin/python3 /usr/bin/python3.6m /usr/lib/python3.6 /usr/lib64/python3.6 /usr/local/lib/python3.6 /usr/include/python3.6m /usr/share/man/man1/python3.1.gz
[root@ecs-test ~]# sudo ln -s /usr/bin/python3 /usr/bin/python
[root@ecs-test ~]# speedtest 
 

5、查看测速节点列表

speedtest --list 

6、对指定节点测速,14623是节点编号

speedtest  --server 14623 

Kimsufi-ks系列怎么配置ipv6

debian10:
ipv6 地址以及网关的获取方式:

美区账号登录:https://ca.api.kimsufi.com/
请求:https://ca.api.kimsufi.com/console/#/dedicated/server/%7BserviceName%7D/specifications/network~GET
(欧洲将链接中 ca 换成 eu )
填入主机名,Execute,便可找到:

 
{
        .....
-vmac: {
supported: true
}
-routing: {
-ipv6: {
gateway: "xx"
ip: "xx/128"
network: "xxx/56"
}
-ipv4: {
network: "xx"
ip: "xx"
gateway: "xx"
}
}
-vrack: {
type: null
bandwidth: null
}
}

编辑文件/etc/network/interfaces
添加以下代码

 
iface ens3 inet6 static    ##ens3为我的网卡,请修改成自己的网卡
    address 你的ipv6地址 
    netmask 128

post-up /sbin/ip -f inet6 route add IPv6_GATEWAY dev ens3
post-up /sbin/ip -f inet6 route add default via IPv6_GATEWAY 
pre-down /sbin/ip -f inet6 route del IPv6_GATEWAY dev ens3
pre-down /sbin/ip -f inet6 route del default via IPv6_GATEWAY
 
service networking restart
 
ping6 -c 4 google.com

网络DD重装Linux-已适配Oracle甲骨文免费主机

确保安装了所需软件:
#Debian/Ubuntu:

apt-get install -y xz-utils openssl gawk file

#RedHat/CentOS:
yum install -y xz openssl gawk file
如果出现了错误,请运行:
#Debian/Ubuntu:

apt-get update

项目1:
github 项目地址如下,欢迎 star:
https://github.com/leitbogioro/Tools

下载并运行脚本:

wget --no-check-certificate -qO InstallNET.sh 'https://raw.githubusercontent.com/leitbogioro/Tools/master/Linux_reinstall/InstallNET.sh' && chmod a+x InstallNET.sh

国内机器现在可以从 Gitee 下载:

wget --no-check-certificate -qO InstallNET.sh 'https://gitee.com/mb9e8j2/Tools/raw/master/Linux_reinstall/InstallNET.sh' && chmod a+x InstallNET.sh

安装debian 10或者11(支持 9 至 12)

bash InstallNET.sh -debian 10
bash InstallNET.sh -debian 11
bash InstallNET.sh -debian 12

安装12记得更新openssh(爆出过漏洞9.8P1才没漏洞)
不用再输入使用何种架构,脚本会自动检测架构、实现 Debian 系和 Redhat 系架构名相互智能转换!

Ubuntu 22.04(-ubuntu 20.04/22.04/24.04

bash InstallNET.sh -ubuntu 20.04

Windows 11 Pro for Workstations

bash InstallNET.sh -windows

然后等提示 reboot 后 就可以登录了
ssh端口不变 root 默认密码

LeitboGi0ro

默认用户名

For Linux: root

For Windows: Administrator

默认密码

For Linux: LeitboGi0ro

For Windows: Teddysun.com

项目2:支持甲骨文,不支持vir
1.新增对 Oracle AMD,Oracle ARM全面支持. 可支持从 Ubuntu, Oracle Linux 等系统网络重装.
2.更新 dd 镜像的基础系统版本.
3.移除对外部 wget 的依赖.
4.新增 -port 参数, 可更改默认SSH端口.
5.更新 内置的网络参数计算 逻辑.
6.更新 grub 配置文件定位逻辑, 可支持任意引导grub的系统.
默认密码:Vicer

以下系统已通过测试(其他自测):
Debian: 9, 10, 11;
Ubuntu: 18.04, 20.04;
CentOS: 6.10;
以下平台已通过测试(其他自测):
Oracle、Do、Azure

示例安装Debian10和Debian11(512M内存推荐使用Debian10):

bash <(wget --no-check-certificate -qO- 'https://raw.githubusercontent.com/MoeClub/Note/master/InstallNET.sh') -d 11 -v 64 -p "自定义root密码" -port "自定义ssh端口"

手动测试Oracle甲骨文免费主机安装Debian11,成功通过。
默认root密码:MoeClub.org
以上脚本支持IPV6,但是实用性不是很广,buyvm和dmit无法使用,dmit安装debian10成功

wget --no-check-certificate -O AutoReinstall.sh https://git.io/AutoReinstall.sh && bash AutoReinstall.sh

手动测试商家buyvm通过,默认密码:Pwd@Linux
这个脚本IPV4没问题对IPV6支持不太好,可能会出现模块无法加载的问题,但是实用性很广,几乎支持所有IDC

开机改密:

#!/bin/bash
echo root:Vicer |sudo chpasswd root
sudo sed -i 's/^#\?PermitRootLogin.*/PermitRootLogin yes/g' /etc/ssh/sshd_config;
sudo sed -i 's/^#\?PasswordAuthentication.*/PasswordAuthentication yes/g' /etc/ssh/sshd_config;
sudo reboot

支持centos7、8

bash <(wget --no-check-certificate -qO- 'https://raw.githubusercontent.com/MoeClub/Note/master/InstallNET.sh') -c 7 -v 64 -a
bash <(wget --no-check-certificate -qO- 'https://raw.githubusercontent.com/MoeClub/Note/master/InstallNET.sh') -c 8 -v 64 -a

 

 

buyvm DD脚本

wget --no-check-certificate -O AutoReinstall.sh https://git.io/AutoReinstall.sh && bash AutoReinstall.sh

端口22,密码:Pwd@Linux

功能强大的linux系统一键DD重装脚本

一、Linux reinstall下载

网站:

    1. https://github.com/leitbogioro/Tools

脚本下载:
wget –no-check-certificate -qO InstallNET.sh ‘https://raw.githubusercontent.com/leitbogioro/Tools/master/Linux_reinstall/InstallNET.sh’ && chmod a+x InstallNET.sh

默认密码是:LeitboGi0ro

相关说明:
支持各大云商,特别支持Oracle ARM机
支持 raid 0,仅限 Debian,要使用 raid 0 请添加 -raid “0”参数。单硬盘请不要添加此参数。有效性尚待测试。
DD Windows 方法和原版萌咖功能一样,该怎么用就怎么用,如果 DD 包无后缀名,默认使用 gz 解压方式,支持 xz 结尾的压缩包,如果要解压 xz 压缩包请添加参数 -filetype “xz”。
支持 RedHat 系新系统,包括 CentOS 9 Stream,RockyLinux 8+,AlmaLinux 8+,Fedora 34+,也支持从 OracleLinux/VzLinux 装到脚本支持的系统。
Debian 9+ 支持 xfs,这也是 Redhat 系默认的文件系统,抛弃老旧的默认 ext2。
如果要指定其他参数,比如镜像地址,系统后面必须带上版本,比如:-debian 11,不然会出错。
默认采用 DHCP 配置网络,如果确认是静态地址,请附带 –dhcp-static 参数,不过脚本仍然会自动检测,如果是 DHCP,还会改回来。
由于 RedHat 7 以后默认采用 firewalld 做防火墙,防火墙不放行的端口都用不了,所以通过强改 firewalld 配置文件来对 RedHat 系列的系统自定 s-s-h 端口号进行支持。此前旧版本仅支持 22 端口,不支持自定。
脚本对当前与运行系统的硬件架构作了判断和对要装的系统硬件架构名称做了自动转换,并且 -v 参数已经被废弃,用 -version 替代,如果不懂,不要再使用这个参数
国内机器不用指定安装源,脚本自动监测并切换到国内源。

注意事项:
脚本完善了对 grub2 的处理,使 Debian 和 Redhat 系可以无限互装而不受影响,萌咖的脚本只支持处理 grub1,这就导致从 Debian 系装到 Redhat 系,grub1 变成了 grub2,导致从 Redhat 系没法再装回 Debian 系。
AMD64 legacy boot 和 AMD64 UEFI boot 以及 ARM64 UEFI boot 的启动项处理参数完全不同,处理错了就是坑,能解决好才是支持主流各 CPU 架构和主板固件启动的基础。
已进行了大量测试,确认 Oracle 机器上跑没问题。
为什么 Debian IPv6 为什么没配置正确(双栈机)?检查一下你原系统是不是 /etc/default/grub 文件里是不是 GRUB_CMDLINE_LINUX=”” 里面带 net.ifnames=0 biosdevname=0 参数?如果带,系统网卡名称会统一变成 eth0 eth1 eth2 这种的,这样会干扰新系统里写入网络配置。有能力的自己在原系统里把相关配置清掉,确保网卡显示的是真实物理网卡的名称,而不是被系统重定向过的,脚本获取手段就是这个,你原系统配置不对,不要怪脚本怎么没在新系统内写入正确的。
多网卡,多ip请进新系统内手工配置,单网卡双栈机自动配置 ipv6 仅限 debian
由于 CentOS 6 的 grub1 脚本语法和其他系统 grub1 grub2 的完全不同,所以不再对装回 CentOS 6 和将 CentOS 6 重装成别的系统的支持。
Redhat 8 要求 2.5GB 内存,Redhat 9 要求 2GB 内存。

二、Linux reinstall使用
先安装依赖:

Debian series(Debian / Ubuntu):
apt update -y
apt install wget -y

Redhat series(CentOS / AlmaLinux / RockyLinux / OracleLinux / Fedora / VzLinux):
yum update –allowerasing -y
yum install wget -y
快速安装系统:

Debian 11系统

bash InstallNET.sh -debian
CentOS 9 stream系统

bash InstallNET.sh -centos
AlmaLinux 9系统

bash InstallNET.sh -almalinux
RockyLinux 9系统

bash InstallNET.sh -rockylinux
Fedora 37系统

bash InstallNET.sh -fedora
Ubuntu 20.04系统

bash InstallNET.sh –ubuntu

三、Linux reinstall参数

Linux reinstall详细的使用示例如下:
bash InstallNET.sh -debian/ubuntu/centos/almalinux/rockylinux/fedora(os type) 11(os version) -version 64(os bit) -port “your server port” -pwd “your server password” -mirror “a valid url for linux image source” -dd/–image “dd image url” -filetype “gz or xz” -timezone “like Asia/Tokyo etc” –dhcp-static/–ip-addr ‘x.x.x.x'(ip address) –ip-mask ‘x.x.x.x'(subnet mask) –ip-gate ‘x.x.x.x'(gateway) -firmware(Debian with hardware drivers)

如果你想安装指定操作系统,请修改为以下的参数:

-debian 9/10/11 : Debian 9 and later

-centos 7/8/9-stream: CentOS 7 and later

-almalinux/alma 8/9: AlmaLinux 8 and later

-rockylinux/rocky 8/9: RockyLinux 8 and later

-fedora 34/35/36/37: Fedora 34 and later

-ubuntu 16.04/18.04/20.04: Ubuntu from 16.04 to 20.04

指定操作系统源:-mirror “a valid DIST mirror url”。有如下官方可供选择:

For Debian, official recommend mirror lists are here:

https://www.debian.org/mirror/list.html
For CentOS, official recommend mirror lists are here:

https://www.centos.org/download/mirrors/
For AlmaLinux, official recommend mirror lists are here:

https://mirrors.almalinux.org/
For RockyLinux, official recommend mirror lists are here:

https://mirrors.rockylinux.org/mirrormanager/mirrors
For Fedora, official recommend mirror lists are here:

https://admin.fedoraproject.org/mirrormanager/mirrors/Fedora
For Ubuntu, official recommend mirror lists are here:

https://launchpad.net/ubuntu/+cdmirrors
指定端口:

-port “”: you can pre-specify s-s-h port of system, range is 1~65535, both Redhat series or Debian series could be supported, 默认端口是’22’.

指定密码:

-pwd “”: you can pre-specify ssh password of system, both Redhat series or Debian series could be supported, 默认密码是’LeitboGi0ro’.

DD系统模式:

-dd/–image “DD image from a valid url”: This parameter is for DD mode in KVM or XEN virtualization platform, current os must be Debian series, for example, if you want to DD windows,。

-filetype “gz/xz”: To determine DD file type, not only “.gz”(default) but also “.xz” can be supported.

指定时区:

-timezone “like Asia/Tokyo etc”.

支持 raid 0,仅限 Debian:

-raid “0”: Only for raid 0 disk partition, if your machine has only one hard drive, don’t assign it!

以安装Debian 11示例如下(默认密码是:LeitboGi0ro):

bash InstallNET.sh -debian 11 -mirror “http://ftp.riken.jp/Linux/debian/debian/”

四、安装Windows系统
脚本并不提供任何Windows系统,你需要自己在网上找一些自己被DD好的Windows系统了。

用法示例:

如果是 KVM or XEN virtualization, Debian series only:

bash InstallNET.sh -dd “DD image download URL”
如果是 physical hardware, Intel network adapter, kimsufi etc:

Change netboot to rescue mode, receive mail, get temporary username and password, log into linux, execute:

wget -O- “DD download URL” | xzcat | dd of=/dev/sda
网上免费的 Windows DD images可以在这里找到:

Windows Server series from TeddySun(https://teddysun.com/):

Username: Administrator
Password: Teddysun.com

Windows Server 2022 Datacenter

Chinese: https://dl.lamp.sh/vhd/zh-cn_win2022.xz
English: https://dl.lamp.sh/vhd/en-us_win2022.xz
Japanese: https://dl.lamp.sh/vhd/ja-jp_win2022.xz

Windows Server 2019 Datacenter

Chinese: https://dl.lamp.sh/vhd/cn_win2019.xz
English: https://dl.lamp.sh/vhd/en_win2019.xz
Japanese: https://dl.lamp.sh/vhd/ja_win2019.xz

Windows Server 2012 R2 Datacenter

Chinese: https://dl.lamp.sh/vhd/cn_win2012r2.xz
English: https://dl.lamp.sh/vhd/en_win2012r2.xz
Japanese: https://dl.lamp.sh/vhd/ja_win2012r2.xz

Linux设置IPv4优先,IPv6靠后解析(包含关闭IPv6)

默认的安装中,IPv4 和 IPV6 并存,并且 IPv6 优先于 IPv4。

如果不需要彻底关闭 IPv6,也可以设置让 IPv4 优先于 IPv6。

配置方式如下:
第一种方法:

echo "precedence ::ffff:0:0/96 100" >>/etc/gai.conf 

第二种方法:

vim  /etc/gai.conf 

#precedence ::ffff:0:0/96 100
去掉这一行前面的#号

保存即可生效。

测试:

ping www.google.com -c 3 

测试下来平均可以减少10ms所有的访问时间。

或者
关闭IPv6:

echo -e "net.ipv6.conf.all.disable_ipv6=1\nnet.ipv6.conf.default.disable_ipv6=1\nnet.ipv6.conf.lo.disable_ipv6=1" >> /etc/sysctl.conf
sysctl -p