步骤如下:
1. 阿里云购买服务器
最低配置,30元/月即可。
2. 为服务器安装git
先更新apt再安装,否则可能会失败
3. Github下载frp并运行./frps -c ./frps.ini
frps是一个程序,也需要在Github上下载;
运行./frps -c ./frps.ini时,-bash: ./frps: Permission denied
解决:
chmod 777 ./frps -c ./frps.ini
./frps -c ./frps.ini
即可
其中,frps.ini可为:
[common]
#Bind all local network interfaces
bind_addr = 0.0.0.0
#Expose local port for client to connect with
bind_port = 7001
#Connection password to validate client
privilege_token = xxx
# Dashboard settings
dashboard_port = 7500
dashboard_user = root
dashboard_pwd = xxx
4. 进入阿里云控制台,添加入站规则,否则客户端可能会连接失败
(报错:[service.go:97] login to server failed: dial tcp 47.114.55.62:7000: connectex: A connection attempt failed because the connected party did not properly respond after a period of time, or established connection failed because connected host has failed to respond.
dial tcp 47.114.55.62:7000: connectex: A connection attempt failed because the connected party did not properly respond after a period of time, or established connection failed because connected host has failed to respond.)
5. 进入客户端(想要控制的内网windows),下载frpc配置frpc.ini:
[common]
server_addr = 47.xxx.xx.xx
server_port = 7001
token = xxx # 密码,要与之前一样
[RDP]
type = tcp
local_ip = 0.0.0.0
# RDP default port
# Default port for RDP protocol is 3389
# local_port is to map local_ip:3389 to remote_ip:3399
local_port = 3389
remote_port = 3399
6. 被控端控制面板-->远程桌面-->允许远程桌面
7: 各个平台下输入ip:3399远程控制和账户名、密码即可。
控制端使用Micosoft remote desktop即可,在IOS, Android, MAC上均有app;
若控制端为windows,则使用自带的远程桌面连接即可。
ps: 比TeamViewer免费版快多了,而且没有设备数量限制
来源:CSDN
作者:R.X. NLOS
链接:https://blog.csdn.net/qazwsxrx/article/details/103992499