Windows OS Hub
  • Windows Server
    • Windows Server 2022
    • Windows Server 2019
    • Windows Server 2016
    • Windows Server 2012 R2
    • Windows Server 2008 R2
    • SCCM
  • Active Directory
    • Active Directory Domain Services (AD DS)
    • Group Policies
  • Windows Clients
    • Windows 11
    • Windows 10
    • Windows 8
    • Windows 7
    • Windows XP
    • MS Office
    • Outlook
  • Virtualization
    • VMWare
    • Hyper-V
    • KVM
  • PowerShell
  • Exchange
  • Cloud
    • Azure
    • Microsoft 365
    • Office 365
  • Linux
    • CentOS
    • RHEL
    • Ubuntu
  • Home
  • About

Windows OS Hub

  • Windows Server
    • Windows Server 2022
    • Windows Server 2019
    • Windows Server 2016
    • Windows Server 2012 R2
    • Windows Server 2008 R2
    • SCCM
  • Active Directory
    • Active Directory Domain Services (AD DS)
    • Group Policies
  • Windows Clients
    • Windows 11
    • Windows 10
    • Windows 8
    • Windows 7
    • Windows XP
    • MS Office
    • Outlook
  • Virtualization
    • VMWare
    • Hyper-V
    • KVM
  • PowerShell
  • Exchange
  • Cloud
    • Azure
    • Microsoft 365
    • Office 365
  • Linux
    • CentOS
    • RHEL
    • Ubuntu

 Windows OS Hub / Windows 10 / Fixing VPN Error: Can’t Establish Connection, Change Network Settings

November 10, 2022 Windows 10Windows 11Windows Server 2019

Fixing VPN Error: Can’t Establish Connection, Change Network Settings

I encountered a strange issue in Windows 10 when all VPN connections suddenly stopped working with the following error message:

Can’t connect to VPN
A connection to the remote computer could not be established. You might need to change the network settings for this connection.

Can’t connect to VPN - error 720 A connection to the remote computer could not be established. You might need to change the network settings for this connection.

I use a built-in Windows VPN client to connect. On the neighboring device, the VPN connection with the same settings works fine, so the problem is not with the remote VPN host.

There is a VPN error 720 in the Application log of Event Viewer:

EventID: 20227
Source: RasClient
The user dialed a connection named VPN which has failed. The error code returned on failure is 720.

The basic recommendation in such cases is to reset the TCP/IP stack and network adapter settings on your computer with the following commands:

netsh winsock reset
netsh int ip reset
ipconfig /release
ipconfig /renew
ipconfig /flushdns

The connection may be blocked by Windows Firewall rules or a third-party antivirus/firewall (try to disable them for some time).

Make sure that Windows doesn’t use WinHTTP proxy to access the Internet.

netsh winhttp show proxy

check for WinHTTP proxy direct access

Current WinHTTP proxy settings:
Direct access (no proxy server).

In this example, a direct connection is used.

If you want to reset proxy settings, run the command below:

netsh winhttp reset proxy

If proxy settings are set using GPO on your computer and you cannot change proxy server settings in Windows, contact your system administrator and make sure that VPN traffic is not blocked on your proxy server.

In my case, I was not able to connect to VPN after doing it.

Then try to reinstall the WAN Miniports virtual adapters in the Device Manager.

WAN Miniports are virtual network adapters with drivers for different connection protocols. Windows has WAN Miniport adapters for IKEv2, IP, IPv6, L2TP, Network Monitor, PPPOE, PPTP, and SSTP.
  1. Open the Device Manager (devmgmt.msc), expand the Network Adapters section, and uninstall all devices with the name WAN Miniport;
  2. For example, select WAN Miniport (SSTP), right-click it, and select Uninstall Device in the context menu; uninstall WAN Miniport adapters in windows
  3. Move on to the next WAN Miniport device. You need to remove all devices:
    • WAN Miniport (PPTP)
    • WAN Miniport (PPPOE)
    • WAN Miniport (Network Monitor)
    • WAN Miniport (L2TP)
    • WAN Miniport (IPv6)
    • WAN Miniport (IP)
    • WAN Miniport (IKEv2)
  4. Then rescan your hardware configuration (Action -> Scan for Hardware changes), and wait till Windows detects and installs drivers for WAN Miniport devices; scan for hardware changes with device manager
  5. After all WAN Miniports have been reinstalled, check your VPN connection. It should work.
If Windows could not install WAN Miniports, check your Windows image health using DISM:

SFC /scannow
DISM /Online /Cleanup-Image /CheckHealth

You can use PowerShell to diagnose any WAN Miniports issues.

Make sure that all protocols are enabled for a network adapter (Enabled=True), and there are no third-party drivers among your filtering drivers (they can be added by your antivirus software).

$adapter=Get-NetAdapter -IncludeHidden | Where-Object {$_.InterfaceDescription -eq "WAN Miniport (PPTP)"}
Get-NetAdapterBinding -Name $adapter.name -IncludeHidden –AllBindings

manage network filtering drivers with powershell

You can enable/disable a filtering driver with the command:

Enable-NetAdapterBinding -Name $adapter.name -IncludeHidden -AllBindings -ComponentID ms_wanarp

0 comment
3
Facebook Twitter Google + Pinterest
previous post
How to Enable Wireless (Wi-Fi) on Windows Server 2019/2016
next post
Fix: Network Adapters Are Missing in Windows

Related Reading

Zabbix: How to Get Data from PowerShell Scripts

October 27, 2023

Tracking Printer Usage with Windows Event Viewer Logs

October 19, 2023

How to Use Ansible to Manage Windows Machines

September 25, 2023

Installing Language Pack in Windows 10/11 with PowerShell

September 15, 2023

How to View and Change BIOS (UEFI) Settings...

September 13, 2023

Leave a Comment Cancel Reply

Categories

  • Active Directory
  • Group Policies
  • Exchange Server
  • Microsoft 365
  • Azure
  • Windows 11
  • Windows 10
  • Windows Server 2022
  • Windows Server 2019
  • Windows Server 2016
  • PowerShell
  • VMWare
  • Hyper-V
  • Linux
  • MS Office

Recent Posts

  • Zabbix: How to Get Data from PowerShell Scripts

    October 27, 2023
  • Tracking Printer Usage with Windows Event Viewer Logs

    October 19, 2023
  • PowerShell: Configure Certificate-Based Authentication for Exchange Online (Azure)

    October 15, 2023
  • Reset Root Password in VMware ESXi

    October 12, 2023
  • How to Query and Change Teams User Presence Status with PowerShell

    October 8, 2023
  • How to Increase Size of Disk Partition in Ubuntu

    October 5, 2023
  • How to Use Ansible to Manage Windows Machines

    September 25, 2023
  • Installing Language Pack in Windows 10/11 with PowerShell

    September 15, 2023
  • Configure Email Forwarding for Mailbox on Exchange Server/Microsoft 365

    September 14, 2023
  • How to View and Change BIOS (UEFI) Settings with PowerShell

    September 13, 2023

Follow us

  • Facebook
  • Twitter
  • Telegram
Popular Posts
  • How to Allow Multiple RDP Sessions on Windows 10 and 11
  • How to Repair EFI/GPT Bootloader on Windows 10 or 11
  • How to Restore Deleted EFI System Partition in Windows
  • Network Computers are not Showing Up in Windows 10/11
  • How to Run Program without Admin Privileges and Bypass UAC Prompt
  • Fix: BSOD Error 0x0000007B (INACCESSABLE_BOOT_DEVICE) on Windows
  • Fixing ‘The Network Path Was Not Found’ 0x80070035 Error Code on Windows
Footer Logo

@2014 - 2023 - Windows OS Hub. All about operating systems for sysadmins


Back To Top