Nyr / openvpn-install

OpenVPN road warrior installer for Ubuntu, Debian, AlmaLinux, Rocky Linux, CentOS and Fedora
MIT License
18.66k stars 4.81k forks source link

Can you change the subnet for VPN connections? #1063

Closed daveydoom closed 8 months ago

daveydoom commented 9 months ago

Hello. Just installed this today, excellent, thank you!

Is there a way to change the subnet which the script automatically creates for the VPN connections? I see in the script where the 10.8.0.0 subnet is listed but am reluctant to mess around without some guidance.

Regards, Dave

MohamadSafi commented 9 months ago

Hello for me it was only allowing me to connect with one device at the same time at changed the subnet from:

server 10.8.0.0 255.255.255.0" > /etc/openvpn/server/server.conf to: server 10.8.0.0 255.255.255.128" > /etc/openvpn/server/server.conf

and that worked fine with me now you can connect with a 126 different device since there will be to ip addresses reserved and you will be left with 126 different ip address.

Nyr commented 8 months ago

If you change all the references in the script and install from zero, that will work. But do not do that once OpenVPN is already installed, that will not work.