Super User is a question and answer site for computer enthusiasts and power users. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

Is it possible to start a windows openvpn client to make it connect using a predefined config (.ovpn) by supplying program arguments using command prompt. Or specifying the arguments in the shortcut when opening from windows shortcut etc.

share|improve this question
up vote 5 down vote accepted

Solved it as below:

from windows command prompt-

enter image description here

This is going to start the opn vpn gui client directly connecting to the connection specified in the config.

share|improve this answer
Thank you sir, A+ work – A_Elric Jan 15 '15 at 9:44

In additional to Flowerking's answer, you could specify the folder in which your ovpn file lives, perhaps to store private key data in user space. For that, use config_dir:

openvpn-gui.exe --connect "client.ovpn" --config_dir "C:\Users\Foo\Documents\protected_crypto_data"
share|improve this answer

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .