tinc国内服务器访问国外

tinc启动多个实例报错Can’t bind to 0.0.0.0 port 655/tcp: Address already in use

tinc的安装文档参考:《tinc实现国内服务器通过国外服务器访问外网》

tinc启动多个实例,连接到多个vpn master 的server上,本地启动报错,很显然启动多个实例会导致本地bind默认端口655的冲突,只需要在主机host配置文件中更改默认端口号就可以,加个Port=1655

root@VM-8-2-ubuntu:/etc/tinc/tinc1/hosts# cat tinc_bj
Address = 112.244.124.1
Subnet = 192.168.1.2/32
Port = 1655

-----BEGIN RSA PUBLIC KEY-----
MIFB...5utwIDAQAB
-----END RSA PUBLIC KEY-----

启动多个实例后,可以看到多个虚拟接口:

tinc启动多个实例报错Can't bind to 0.0.0.0 port 655/tcp: Address already in use