openvpn客户端获得固定IP

1.vim /etc/openvpn/server.conf

更改server端配置文件,开启client-config-dir /etc/openvpn/ccd

2.cd  /etc/openvpn/ccd(如果没有该文件夹,则自己创建,)

在指定的文件夹下建立以用户名为名称的文件 如 /etc/openvpn/ccd/client4.conf

3.修改该文件,设置IP 

ifconfig-push 10.0.0.16 10.0.0.17 (客户端IP是以前一个IP为准,两个IP要连着)

猜你喜欢

转载自blog.csdn.net/xiao_sheng_jun/article/details/83315777
今日推荐