Possible to run OpenVPN server for clients without DHCP Client Service?

Need help configuring your VPN? Just post here and you'll get that help.

Moderators: TinCanTech, TinCanTech, TinCanTech, TinCanTech, TinCanTech, TinCanTech

Forum rules
Please use the [oconf] BB tag for openvpn Configurations. See viewtopic.php?f=30&t=21589 for an example.
Post Reply
tonemgub
OpenVpn Newbie
Posts: 1
Joined: Thu Aug 04, 2016 1:38 am

Possible to run OpenVPN server for clients without DHCP Client Service?

Post by tonemgub » Thu Aug 04, 2016 1:46 am

Hello,
A Windows client would like to use a static IP (without using a DHCP server at ALL). Here is the Linux server config:

Code: Select all

port 1194
proto udp
dev tun
ca ca.crt
cert server.crt
key server.key  # This file should be kept secret
dh dh2048.pem
server 10.0.0.0 255.255.255.0
ifconfig-pool-persist ipp.txt
client-config-dir /etc/openvpn/staticclients
#route 10.0.0.0 255.255.255.252
client-to-client
keepalive 10 120
tls-auth ta.key 0 # This file is secret
cipher AES-128-CBC   # AES
comp-lzo
persist-key
persist-tun
status openvpn-status.log
verb 3
/etc/openvpn/staticclients/user

Code: Select all

ifconfig-push 10.0.0.8 10.0.0.9
And here is client's config:

Code: Select all

client
dev tun
proto udp
remote 192.x.x.x
resolv-retry infinite
nobind
persist-key
persist-tun
cipher aes-128-cbc
ca ca.crt
cert user.crt
key user.key
tls-auth ta.key 1
remote-cert-tls server
comp-lzo
verb 1
reneg-sec 0
ip-win32 manual
Unfortunately, this method still requires that "Control Panel / Administrative Tools / Services, make sure that the DHCP Client Service is started.". The client doesn't want this, and would like to assign a static IP without DHCP running on their Windows PC. Is this even possible, if so, how?

Thank you.

TinCanTech
OpenVPN Protagonist
Posts: 11139
Joined: Fri Jun 03, 2016 1:17 pm

Re: Possible to run OpenVPN server for clients without DHCP Client Service?

Post by TinCanTech » Thu Aug 04, 2016 11:48 am

With Windows XP this is just about possible .. but it is not pretty.

You will have to assign your IP address manually and probably use --ifconfig-noexec client side.

Post Reply