freenom 免费域名海外上网
概述
-
为什么使用 v2R
由于笔者之前使用 ssr,但是每次搭建完第二天就会被封端口,进行了一波百度,发现采用 v2Ray 会相对稳定,没那么容易被墙
-
相关概念
https://toutyrater.github.io/
开干
该脚本只适用于 centos7 服务器
申请免费域名
这里使用 freenom.com 进行域名申请
记得使用 firefox 浏览器
-
先注册帐号
这里笔者采用的是谷歌帐号登录(需要翻墙才可以,可以随便网上找个免费的vpn软件连接登录一下)
-
完善信息(不然后面无法完成免费域名订单)
填入必要的信息
-
Services –> Register a New Domain, 注册新域名
-
输入你想要的域名,并且点击
Check Availability
tk, ml, ga, cf, gq 都是是免费的后缀,可以按自己喜好选择,比如说 sindy123.tk, 如果检测出需要收费,那可以重新输入直到合适
-
点击 Checkout
-
选择12个月免费,并点击 Continue
-
完成订单
-
很遗憾,无法完成订单
别着急,网上百度了一下解决方法,https://baijiahao.baidu.com/s?id=1689185764130254565&wfr=spider&for=pc
貌似是校验ip导致的问题,需要使用 Firefox 的代理插件(这就是前面说需要使用 Firefox 的原因了),步骤如下
-
Firefox 浏览器安装 Gooreplacer 插件
点击 “扩展” 并输入
Gooreplacer
回车点击并安装即可
-
再重新来一遍注册域名的步骤即可
-
有时候其实已经注册成功了,但是还是显示失败,可以点击 Services –> My Domains 检查一下
DNS 解析到梯子服务器
这里使用 cloudflare
-
管理域名使用自定义的 Nameservers
使用 cloudflare 的nameservers,
DAVE.NS.CLOUDFLARE.COM
,GINA.NS.CLOUDFLARE.COM
-
登入 cloudflare,添加站点
-
选择免费的 plan,如果想更高的配置可以考虑收费的
-
添加 DNS 解析记录,解析到梯子服务器
如果想使用二级域名,那就把
@
改成二级域名前缀即可 -
校验 dns 解析是否生效,一般半小时内生效
如果发现 ping 出的地址不对,那是因为上一步添加代理把
proxy status
开启了,不影响后续操作,你也可以关闭,生效后会直接显示你配置的地址
服务器处理
如果是 oracle 免费 vps 安装 BBR 重启会导致服务重连,可以执行以下步骤
关闭防火墙
由于甲骨文云有控制台可以配置安全防火墙,加上修改了SSH
端口,可以禁用防火墙,使用iptables
来管理.
systemctl stop firewalld
systemctl disable firewalld
修改主机名
编辑修改oci-hostname.conf
文件
systemctl stop firewalld
将PRESERVE_HOSTINFO=0
中的的值0
修改为1
# compute instance on Oracle Cloud Infrastructure (formerly Baremetal Cloud Services)
# Set PRESERVE_HOSTINFO to one of the following values
# 0 -- default behavior to update hostname, /etc/hosts and /etc/resolv.conf to
# reflect the hostname set during instance creation from the metadata service
# 1 -- preserve user configured hostname across reboots; update /etc/hosts and
# /etc/resolv.conf from the metadata service
# 2 -- preserve user configured hostname across instance reboots; no custom
# changes to /etc/hosts and /etc/resolv.conf from the metadata service,
# but dhclient will still overwrite /etc/resolv.conf
# 3 -- preserve hostname and /etc/hosts entries across instance reboots;
# update /etc/resolv.conf from instance metadata service
PRESERVE_HOSTINFO=0
卸载相关程序
-
rpcbind
使用
netstat -ntlp
命令发现rpcbind
监听了111
端口,如担心安全可执行以下命令卸载禁用:systemctl stop rpcbind
systemctl stop rpcbind.socket
systemctl disable rpcbind
systemctl disable rpcbind.socket -
oracle-cloud-agent
卸载甲骨文云官方后台监控程序
systemctl stop oracle-cloud-agent
systemctl disable oracle-cloud-agent
systemctl stop oracle-cloud-agent-updater
systemctl disable oracle-cloud-agent-updater
一键搭建
如果是 oracle 免费 vps 安装 BBR 重启会导致服务重连,可以执行以下步骤
参考:https://www.ioiox.com/archives/99.html
- 关闭防火墙
- 修改主机名
- 卸载相关程序:rpcbind, oracle-cloud-agent
-
在梯子服务器,执行一键搭建脚本
bash <(curl -sL https://gist.githubusercontent.com/JodenHe/815dd91277b722d36a860d39c2296083/raw/7f2b5ac0f8137b245d44741fc4a9f40cffa36755/v2Ray-install.sh) -
这里选择
4. 安装V2ray-VMESS+WS+TLS(推荐)
,输入 4 回车 -
这里提示需要一个域名,域名的dns解析到本服务器(前面步骤已经做了),直接输入 y 进入安装
-
输入前面准备的域名:sindy123.tk,回车
因为脚本里面的dns校验已经被去除了,所以请自行保证dns解析的正确
-
输入 v2Ray 的端口,回车,这里使用 39554
-
其他一路回车即可,也可以按提示输入其他
-
最终输出 v2Ray 配置信息如下
-
最后最后,记得在你的服务器开放 v2Ray 的端口,这里设置的是:39554,否则无法连接通
v2Ray 客户端
参考:https://tlanyan.pp.ua/v2ray-clients-download/
笔者使用的windows客户端为:V2rayN
, 安卓客户端为:V2rayNG
参考
https://toutyrater.github.io/
https://tlanyan.pp.ua/v2ray-clients-download/
https://baijiahao.baidu.com/s?id=1689185764130254565&wfr=spider&for=pc
https://www.ioiox.com/archives/99.html
网友评论