Showing posts with label windows 11. Show all posts
Showing posts with label windows 11. Show all posts

Sunday, January 8, 2023

OpenVPN Server on Ubuntu 22.04 LTS Desktop VMWare Virtual Machine

Hardware & Software

  • Host: Windows 11
  • Host: VMWare Workstation Pro 18
  • Guest: Ubuntu 22.04 LTS Desktop
  • OpenVPN

VMWare Guest Configuration



  • VMWare Network: Bridged
  • Install Ubuntu 22.04 LTS Desktop
  • In Ubuntu, set Static IP Address (e.g. 192.168.26.60/24)

OpenVPN Server Installation

  • Update System
    • sudo apt update
    • sudo apt upgrade
  • Get OpenVPN
    • wget https://git.io/vpn -O openvpn-ubuntu-install.sh
    • chmod -v +x openvpn-ubuntu-install.sh
  • Install OpenVPN
    • sudo ./openvpn-ubuntu-install.sh
    • Public IP address or hostname: <your DDNS hostname>
    • Protocol: UDP
    • Port: 1194
    • DNS: 1.1.1.1
    • Client Name: phone
  • Additional options in /etc/openvpn/server/server.conf
    • duplicate-cn
    • client-to-client
  • Manage OpenVPN
    • sudo systemctl stop openvpn-server@server.service
    • sudo systemctl start openvpn-server@server.service
    • sudo systemctl restart openvpn-server@server.service

Configure Router / Gateway


OpenVPN Client Installation

  • Transfer /root/phone.ovpn to your device
  • Import phone.ovpn in OpenVPN

References:

  • https://www.cyberciti.biz/faq/ubuntu-20-04-lts-set-up-openvpn-server-in-5-minutes/