Мануалы и справочники Общие команды
openvpn

Команда openvpn: опции, ключи и примеры использования

openvpn

OpenVPN client and daemon binary. More information: https://openvpn.net/.

  • Connect to server using a config file:

sudo openvpn {{path/to/client.conf}}

sudo openvpn --remote {{alice.example.com}} --dev {{tun1}} --ifconfig {{10.4.0.1}} {{10.4.0.2}}

sudo openvpn --remote {{bob.example.com}} --dev {{tun1}} --ifconfig {{10.4.0.2}} {{10.4.0.1}}

  • Create a cryptographic key and save it to file:

openvpn --genkey --secret {{path/to/key}}

  • Try to set up a peer-to-peer tunnel on bob.example.com host with a static key:

sudo openvpn --remote {{alice.example.com}} --dev {{tun1}} --ifconfig {{10.4.0.1}} {{10.4.0.2}} --secret {{path/to/key}}

sudo openvpn --remote {{bob.example.com}} --dev {{tun1}} --ifconfig {{10.4.0.2}} {{10.4.0.1}} --secret {{path/to/key}}