Azure News - 2026-07-27
2026-07-27
最終更新: 2026-08-27 21:13:49 JST
Azure Architecture Blog
Preserve a Legacy IP During Azure Migration with Private Link Service Direct Connect
- Link: https://techcommunity.microsoft.com/t5/azure-architecture-blog/preserve-a-legacy-ip-during-azure-migration-with-private-link/ba-p/4540575
- Published: 2026-07-27 21:31:30
- Fetched: 2026-08-27 21:13:49
詳細を表示
Why this matters
Phased migrations to Azure frequently stall on a single, unglamorous constraint: an application with a hard-coded dependency address. The usual options are to re-address the application or change its configuration, and both add development effort, regression testing, and risk to a migration that is already time-boxed.
This article demonstrates a pattern that removes that constraint from the critical path. Using Azure Private Link Service Direct Connect together with a Private Endpoint, the migrated application continues to reach its dependency on exactly the same private address it has always used, while that dependency remains on premises during the interim phase.
The practical benefits are:
- Reduced migration risk. No application re-addressing or code change, so no regression cycle and a significantly smaller blast radius.
- Faster migration. Web and application tiers can move now rather than waiting for the backend dependency to be modernised, so phase one is no longer blocked by phase two.
- Avoided remediation cost. No development effort to change hard-coded addressing, and none of the associated testing spend.
- Business continuity preserved. The application connects to the same address throughout, which removes addressing-related cutover risk mid-migration.
- Overlapping address space handled. One of the most common reasons enterprise datacentre exits stall is addressed directly, without VNet peering.
The pattern is deliberately a bridge rather than a destination. It buys time to modernise properly; it does not remove the need to do so.
Customer challenge
The customer was planning a phased migration of a legacy application to Azure. The web and application tiers could move first, but a dependent database service needed to remain on premises during the initial phase. The application used a hard-coded private address for this dependency, and changing the application configuration or addressing would have increased migration risk and required additional development and regression testing.
Customer requirements
The customer needed transitional architecture that would allow the web and application tiers to run in Azure while continuing to reach the on-premises database through its existing application-facing address. The solution is needed to:
- Preserve the existing application-facing database address.
- Migrate the web and application tiers to Azure without immediate application code or configuration changes.
- Keep the database on-premises until a later migration phase.
- Provide private, controlled connectivity between the Azure-hosted application tiers and the on-premises database.
- Validate the complete traffic path before considering the pattern for production use.
Solution and lab overview
This lab evaluates Azure Private Link Service Direct Connect as a transitional connectivity pattern for a phased migration. The capability can connect a Private Link service directly to a privately routable destination address without requiring the destination to sit behind a traditional load balancer. That makes it relevant to direct IP-based scenarios such as database connections, custom applications, and privately reachable on-premises resources.
In the lab, the migrated web and application virtual machines connect to a Private Endpoint in an extended prod VNet. The endpoint maps to a Private Link Service Direct Connect resource in a hub VNet. The hub then routes the traffic across a site-to-site VPN to the simulated on-premises database server. The detailed IP values used to reproduce the lab are introduced in the architecture and deployment sections rather than in the customer narrative.
|
Preview notice |
Why this pattern works
- Legacy applications often depend on fixed private addresses that cannot be changed safely during the first migration wave.
- Reusing or overlapping address space complicates conventional routed hybrid connectivity.
- Private Link Service Direct Connect can route traffic to a specific privately routable destination address and bypass the traditional load-balancer requirement.
- The pattern provides a temporary abstraction that lets the Azure-hosted application tier keep using its expected destination while the actual dependency remains on-premises.
When this pattern fits
Consider this pattern when:
- An application has a hard-coded or otherwise fixed dependency address that cannot be changed in the current migration phase.
- The application tier is ready to migrate ahead of its backend dependency.
- On-premises and Azure address spaces overlap, which rules out straightforward VNet peering.
- You need a controlled, reversible transition step rather than a single large cutover.
Look at other options when:
- The application can be reconfigured or modernised within the migration window. Where that is possible, resolving the dependency properly is the better outcome.
- You need a permanent end-state architecture. This pattern is transitional by design.
- Your target region does not yet support Private Link Service Direct Connect, which is in public preview with limited regional availability.
Architecture
|
Component |
Address space / IP |
Location |
Purpose |
|
Hub VNet |
10.230.0.0/21 |
West US 2 |
Hosts the VPN Gateway, Azure Bastion, test subnet, and Private Link Service subnet. |
|
On-premises VNet |
10.220.0.0/21 |
North Central US |
Simulates the on-premises network with production and development subnets. |
|
On-premises production subnet |
10.220.1.0/24 |
North Central US |
Hosts vm-db at 10.220.1.6. IIS on this VM simulates the test service on TCP port 80. |
|
Extended production VNet |
10.220.1.0/24 |
West US 2 |
Hosts the migrated web and application VMs that retain the original application-facing address space. |
|
Private Link Service subnet |
10.230.3.0/24 |
Hub VNet |
Hosts the Private Link Service NAT IP configurations 10.230.3.10 and 10.230.3.11. |
|
Private Endpoint |
10.220.1.6 |
Extended production subnet |
Provides the local endpoint used by the migrated application tiers to reach the on-premises dependency. |
Traffic flow
Testing note: In this lab, vm-db represents the on-premises database server. To validate the end-to-end network path without deploying a database engine, we install IIS on vm-db and use its web server on TCP port 80 as a lightweight test service. A successful HTTP response confirms that traffic reaches vm-db through the intended private connectivity path; it does not validate database functionality.
- The web or application VM in the extended production subnet connects to 10.220.1.6 on TCP port 80. For this test, that port is served by IIS running on vm-db.
- Because 10.220.1.6 is assigned to the Private Endpoint in the same subnet, the connection is sent to the Private Endpoint locally.
- The Private Endpoint connection maps to the Private Link Service Direct Connect resource in the hub VNet.
- The Private Link Service Direct Connect resource uses the destination IP address 10.220.1.6.
- The hub VNet routes 10.220.0.0/21 through the VPN Gateway to the simulated on-premises network.
- The simulated on-premises vm-db receives the request through IIS, and the HTTP response returns through the same private connectivity path.
Prerequisites and assumptions
- An Azure subscription where the Microsoft.Network/AllowPrivateLinkserviceUDR feature flag can be registered.
- Azure CLI and Az PowerShell modules available in the execution environment. The commands below assume PowerShell syntax for variables.
- Permission to create resource groups, VNets, subnets, NSGs, public IPs, VPN gateways, local network gateways, Private Link Service, Private Endpoint, NICs, and VMs.
- A region supported by Private Link Service Direct Connect. This lab uses West US 2 and North Central US.
- This lab intentionally uses overlapping application-facing IP space in the extended Azure VNet and the on-premises production subnet. Do not peer the hub VNet and the extended production VNet directly.
|
Credential hygiene |
Deploy the lab
Run the following sequence from an authenticated PowerShell session with Azure CLI available. Review every variable before execution. The lab uses IIS on the simulated database VM only as a lightweight TCP and HTTP target; the objective is to validate the network path rather than database behavior.
|
# ----------------------------- |
Validate the solution
|
Checkpoint |
Command |
Expected result |
|
VPN tunnel status |
az network vpn-connection show -g $RG -n conn-to-onprem --query connectionStatus -o tsv |
Both connections show Connected. |
|
DB web service |
az vm run-command invoke -g $ONPREM_RG -n vm-db --command-id RunPowerShellScript --scripts "netstat -ano | findstr :80" |
The DB VM is listening on TCP port 80. |
|
Private Endpoint connection |
az network private-link-service show -g $RG -n $PLS_NAME --query "privateEndpointConnections[].{Connection:name,Status:privateLinkServiceConnectionState.status}" -o table |
The connection status is Approved, and the Private Endpoint provisioning state is Succeeded. |
|
Hard-coded IP test from web and app tiers |
az vm run-command invoke -g $RG -n vm-web --command-id RunPowerShellScript --scripts "Test-NetConnection 10.220.1.6 -Port 80" |
TcpTestSucceeded is True. |
|
HTTP test from web and app tiers |
az vm run-command invoke -g $RG -n vm-web --command-id RunPowerShellScript --scripts "Invoke-WebRequest http://10.220.1.6 -UseBasicParsing" |
The response contains the sample IIS page. |
Production considerations
- Do not peer the extended prod VNet with the Azure hub VNet. The extended VNet uses 10.220.1.0/24, which overlaps with the 10.220.0.0/21 on-premises prefix that the hub routes through the VPN Gateway. The repeated database IP is intentionally exposed to the web and app tiers only through the Private Endpoint abstraction, not through direct VNet peering.
- The PLS subnet must have Private Link service network policies disabled. The Private Endpoint subnet must have Private Endpoint network policies disabled for this lab pattern.
- Private Link Service Direct Connect requires at least two IP configurations. The lab uses 10.230.3.10 and 10.230.3.11 for high availability alignment.
- The destination IP must be privately routable and reachable from the PLS path. In this lab, the hub routes 10.220.0.0/21 to the on-premises side through VPN Gateway.
- For production, validate return path, NSG rules, route tables, firewall policies, DNS behavior, logging, and operational ownership before adopting the pattern.
Clean up
When the lab is no longer required, remove the lab resource groups. Validate that no shared resources exist in these groups before deletion.
|
az group delete --name rg-pls-demo --yes --no-wait |
Conclusion
This lab shows how a Private Endpoint and Private Link Service Direct Connect can provide a controlled transition path when an application tier moves to Azure before a fixed-address dependency. The pattern can reduce immediate application change, but it should remain an interim architecture: validate routing symmetry, network security, monitoring, regional availability, operational ownership, and a clear plan to remove the legacy address dependency before production adoption.
Used well, this approach reduces migration risk, avoids application remediation cost, and keeps a datacentre exit moving when it would otherwise stall. In a recent engagement it unblocked a phased migration for an enterprise customer whose application carried a hard-coded dependency address, without a single change to application code.
Private Link Service Direct Connect is in public preview and available in selected regions, so confirm regional availability, routing, DNS behaviour, and operational ownership before any production adoption.
If you try the lab, I would welcome your feedback, and any variations you find useful in your own migrations.
References
- Configure Private Link Service Direct Connect
- What is Azure Private Link Service?
- Azure Private Link documentation
- Azure VPN Gateway documentation
- Create a site-to-site VPN connection
- Configure NSG rules for Azure Bastion
About the author
Kumar Kaushal is a Senior Digital Cloud Solutions Architect at Microsoft, focused on helping customers design and validate practical Azure architectures for cloud migration, hybrid connectivity, networking, resiliency, and modernization.