Your legacy app runs on Windows Server 2016 and support ends in January

Windows Server 2016 reaches the end of extended support on 12 January 2027. After that date there are no more security updates unless you buy Extended Security Updates. If your WebForms, Classic ASP, VB6 or FoxPro application is sitting on one of those boxes, you have a dated problem that is separate from the migration you may also want.

This tutorial is about the separate problem. Moving the application onto Windows Server 2022 or 2025 is not modernization and we do not sell it as such. It is a holding action that buys roughly five years of supported runway, and it is worth doing first because a migration done under audit pressure gets sequenced badly. Check the current dates on Microsoft's Windows Server lifecycle page before you plan around them.

You need administrative access to the current server and somewhere to stand up a new one. Nothing in the application source changes.

Inventory what the old server provides

The build sheet nobody wrote is the reason these moves fail. Work through the server and write down what the application consumes from it.

IIS features and app pools

Import-Module WebAdministration
Get-WindowsFeature | Where-Object Installed | Select-Object Name
Get-ChildItem IIS:\AppPools |
  Select-Object Name,
    @{n='Runtime';e={$_.managedRuntimeVersion}},
    @{n='Pipeline';e={$_.managedPipelineMode}},
    @{n='Enable32Bit';e={$_.enable32BitAppOnWin64}},
    @{n='Identity';e={$_.processModel.identityType}},
    @{n='User';e={$_.processModel.userName}}
Get-Website | Select-Object Name, PhysicalPath, State
Get-WebBinding | Select-Object protocol, bindingInformation

Three answers from that output decide most of the work. Enable32Bit tells you whether the worker process is loading 32-bit COM or ODBC components. Pipeline on Classic means the app depends on classic-pipeline module ordering. The app pool identity tells you which account needs recreating, and whether it is a domain account with permissions you have not catalogued.

Classic ASP is still a supported IIS feature on current Windows Server, but it is not installed by default. Neither is ASP.NET 4.x. Note every feature you see installed; you will reinstall them by name.

Registered COM components

VB6 and Classic ASP applications usually depend on COM objects that someone registered by hand years ago. Find the ones the application names:

Select-String -Path 'C:\inetpub\wwwroot\*' -Include *.asp,*.aspx,*.vb,*.cs -Recurse `
  -Pattern 'Server\.CreateObject|CreateObject\(' |
  Select-Object Path, LineNumber, Line

Then resolve each ProgID to a file, because that file has to travel:

$progId = 'MyCompany.Invoicing'
$clsid = (Get-ItemProperty "HKLM:\SOFTWARE\Classes\$progId\CLSID").'(default)'
Get-ItemProperty "HKLM:\SOFTWARE\Classes\WOW6432Node\CLSID\$clsid\InprocServer32",
                 "HKLM:\SOFTWARE\Classes\CLSID\$clsid\InprocServer32" -ErrorAction SilentlyContinue |
  Select-Object PSPath, '(default)'

A DLL found under WOW6432Node is 32-bit. That is fine; it means the new server needs the same 32-bit app pool setting and the same redistributables, and it is also the reason an in-place OS upgrade sometimes looks easier than it is.

The VB6 runtime itself ships with Windows and is supported on current server versions, so a compiled VB6 EXE or DLL usually keeps running. Third-party OCX and ActiveX controls are the risk; several vendors are gone and their installers do not run on a modern OS. We covered how to catalogue those in Third-party controls: the dependency that stalls a VB6 or WebForms migration.

Data providers and DSNs

FoxPro, Access and older SQL Server connections depend on drivers that are not present on a fresh install:

Get-OdbcDriver | Select-Object Name, Platform
Get-OdbcDsn   | Select-Object Name, DriverName, Platform, @{n='Attr';e={$_.Attribute.Values -join ';'}}
Get-ChildItem 'HKLM:\SOFTWARE\Microsoft\ODBC\ODBC.INI' | Select-Object Name

Run it once normally and once from the 32-bit PowerShell at C:\Windows\SysWOW64\WindowsPowerShell\v1.0\powershell.exe. The two registries are different and the 32-bit one is usually where the interesting drivers live. The Visual FoxPro OLE DB provider is 32-bit only and out of support; the Access Database Engine comes in 32- and 64-bit builds that refuse to coexist with mismatched Office installs. Decide now which bitness the new server standardizes on, and test the connection strings before you cut over.

Scheduled tasks, services and shares

Get-ScheduledTask | Where-Object { $_.TaskPath -notlike '\Microsoft*' } |
  Select-Object TaskName, TaskPath, @{n='User';e={$_.Principal.UserId}}
Get-Service | Where-Object { $_.Status -eq 'Running' } | Select-Object Name, DisplayName
Get-SmbShare | Select-Object Name, Path
Get-ChildItem C:\ -Directory | Select-Object Name

The overnight batch is almost always a scheduled task running a VB6 EXE out of a folder nobody mentions, writing to a share with a hard-coded UNC path. Capture the account each task runs as. Those accounts need passwords someone still knows.

Build the new server from the inventory

Build new rather than upgrading in place. In-place upgrades of a server with hand-registered COM and old ODBC drivers tend to half-work, and you lose the ability to fall back by changing a DNS record or a load-balancer rule.

Install the IIS feature set you recorded, by name:

Install-WindowsFeature Web-Server, Web-Asp, Web-Asp-Net45, Web-ISAPI-Ext, `
  Web-ISAPI-Filter, Web-Windows-Auth, Web-Metabase, Web-Mgmt-Console

Then recreate app pools with the same runtime, pipeline mode, bitness and identity, copy the application directory, register the COM components, install the data providers, and recreate the scheduled tasks. Use the appcmd export from the old box as a reference, not as a script to run blind:

C:\Windows\System32\inetsrv\appcmd.exe list config /xml > iis-config.xml
C:\Windows\System32\inetsrv\appcmd.exe list apppool /config /xml > apppools.xml

Verify before you point traffic at it

This is the part that makes the move boring, and boring is the goal.

If you already have a characterization harness, point it at the new server and run it. That is exactly what it is for:

CHARACTERIZATION_BASE_URL=https://newbox.internal/ dotnet test

If you do not have one, build a small one first. A day spent recording the twenty flows that touch money is cheaper than discovering in February that invoice PDFs render with a different font metric. Golden-master tests for legacy web apps walks through the harness.

Beyond the harness, check the things an OS change moves underneath you:

  • Outbound TLS. Newer Windows versions disable old protocols and cipher suites by default. An application that calls a payment gateway or a carrier API through a legacy component may be negotiating with settings the new box no longer offers. Inventory those calls first; see Inventorying a legacy app's outbound TLS exposure.
  • Report and export output. Crystal runtimes, PDF generators and Excel automation are sensitive to installed fonts and printer drivers. Compare bytes or rendered output, not just HTTP status codes.
  • File and share permissions. The new app pool identity is a new security principal. Write paths, temp directories and UNC shares all need explicit grants.
  • Date and culture settings. A server built with different regional settings will format dates and currency differently in pages the legacy code builds by string concatenation.

Cut over with a mechanism you can reverse in under a minute, keep the old server powered on and reachable for a couple of weeks, and watch the logs rather than the clock.

What this does and does not buy you

A supported OS closes the audit finding and stops the clock. It does not make the application easier to change, and it does not reduce the risk of the one developer who understands it retiring. Treat January as the deadline for the OS and nothing else.

The useful thing is what the inventory leaves behind. The list of COM components, data providers, scheduled tasks and service accounts you just wrote is most of the dependency map a migration plan needs. Keep it in the repository next to the code. When you do scope a first slice, you will not be guessing at what the old box was quietly providing.

If the inventory turns up a component you cannot install on a current OS, that is useful information too: it names the slice that has to go first. We would rather hear about it in October than in January. If that is where you are, tell us what the server is running and a senior engineer will reply within one business day.