I'm new to Azure and trying to use VPN to connect a single machine here to a VM on Azure. The VM is on the newer Resource Manager platform. Unfortunately, only the classic platform supports point-to-site. So I added a classic network and connected both networks with a site-to-site VPN.

VNet1 (Resource) -

VNet2 (Classic) -

The VNet2 Gateway also has point-to-site enabled. Point-to-site IP range is

I downloaded the VPN client on my machine here and connected to the VPN. I'm assigned

VPN Connection Successful Image (sorry, I can't post the image directly)

All VPN connections appear to be working, but I cannot see machines on VNet1 from here. A ping/tracert to times out.

One article I found referenced the need for adding a line to the routes.txt for the VPN connection. The first line was already there, I added the second one and re-connected the VPN.

ADD MASK default METRIC default IF default

ADD MASK default METRIC default IF default

No luck. I checked the route table and the routing is in there.

IPv4 Route Table
Active Routes:
Network Destination        Netmask          Gateway       Interface  Metric
<snip>         On-link     28         On-link    266         On-link     28         On-link    266

What am I missing?



The actual article for a Point-to-Site connection for Resource Manager was published by Microsoft last night to here

(Original text: Not a direct answer for you, but according to this [link][1]

"Point-to-Site connections for virtual networks created using the Azure Resource Manager deployment model are now available using REST APIs and PowerShell." )

  • I've upvoted you for leading me in the right direction. Posted the full solution below. (Unfortunately my upvotes don't count yet) Jan 12 '16 at 0:19
  • Thanks for the updated link. I've changed your answer to the accepted answer since this is the full tutorial. Jan 14 '16 at 1:31

A Microsoft employee was kind enough to post a script for creating a point-to-site VPN using Azure Resource Manager model. The feature is undocumented at this time, but this script did the trick for me! (Original Post)

# Must created a subnet called GatewaySubnet for the gateway to connect prior to creating the gateway
$vnetname = "TestNetwork"
$rgname = "TestRG"
$region = "North Europe"
$clientpool = ""
$RootCertName = "MyRootCert.cer"  
$publicCertData = "<Replace_With_Your_Base64_Cert_Data>"; #Export cert as Base64, and put data into single line.

#Login to Azure RM

# Get the Virtual Network
$vnet = Get-AzureRmVirtualNetwork -Name $vnetname -ResourceGroupName $rgname

#Create IP for the gateway
$GWIP = New-AzureRmPublicIpAddress -AllocationMethod Dynamic  -ResourceGroupName $rgname -Location $region  -Name GWIP1

#Get the gateway subnet
$GWSubnet = Get-AzureRmVirtualNetworkSubnetConfig  -Name GatewaySubnet -VirtualNetwork $vnet

# Create GW Config
$GWIPConfig = New-AzureRmVirtualNetworkGatewayIpConfig -Name GWIPConfig -SubnetId $gwsubnet.Id -PublicIpAddressId $GWIP.Id

#Create Gateway
$gw = New-AzureRmVirtualNetworkGateway -Location $region  -Name GW1 -ResourceGroupName $rgname -GatewayType Vpn  -IpConfigurations $GWIPConfig -VpnType RouteBased 

# Create client VPN config
Set-AzureRmVirtualNetworkGatewayVpnClientConfig -VirtualNetworkGateway $gw -VpnClientAddressPool $clientpool

# Create Root Cert
$rootCert = Add-AzureRmVpnClientRootCertificate  -VpnClientRootCertificateName $RootCertName  -PublicCertData $publicCertData  -VirtualNetworkGatewayName $gw.Name -ResourceGroupName $rgname

#Get URL for VPN client - download the exe from here
$packageUrl = Get-AzureRmVpnClientPackage -ResourceGroupName $rgname -VirtualNetworkGatewayName $gw.Name -ProcessorArchitecture Amd64  

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.