概述

我们可以将当前计算机安装的 Windows Server 的升级到较新版本或转换为不同版本,或在许可选项(例如评估、零售和批量许可)之间切换。

  • 升级到较新版本(版本代数的升级)
  • 转换为不同版本(标准版、专业版、企业版、数据中心版之间)
  • 许可选项之间切换(评估转正式、零售版转批量许可版等等)

而不必进行重装、迁移的动作;

但是,强烈建议,在生产环境下做这些改变之前,务必备份当前的全部数据及OS;以免在意外发生时造成关键数据无法挽回的损失。

示例

下面我们以Windows Server 2022 DC Eval版本转换为Windows Server 2022 DC Vol版本为例:

1.查看当前版本信息

这里方法有很多:

  • GUI
  • cmd ->winver

[KB]Windows OS版本转换_版本

  • powershell -> DISM
PS C:\Users\Administrator> DISM /online /Get-CurrentEdition

Deployment Image Servicing and Management tool
Version: 10.0.20348.1

Image Version: 10.0.20348.587

Current edition is:

Current Edition : ServerDatacenterEval

The operation completed successfully.
PS C:\Users\Administrator>

2.查看可转换的目标版本有哪些

PS C:\Users\Administrator> DISM /online /Get-TargetEditions

Deployment Image Servicing and Management tool
Version: 10.0.20348.1

Image Version: 10.0.20348.587

Editions that can be upgraded to:

Target Edition : ServerDatacenter

The operation completed successfully.
PS C:\Users\Administrator>

这里可以看到,可以转换为 ServerDatacenter版本


3.执行转换

指令:

DISM /online /Set-Edition:<target edition> /ProductKey:<product key> /AcceptEula

示例:

DISM /online /Set-Edition:ServerDatacenter /ProductKey:WX4NM-KYWYW-QJJR4-XV3QB-6VM33 /AcceptEula

[KB]Windows OS版本转换_转换_02

这里按下Y就直接重启了。


4.检查转换结果

[KB]Windows OS版本转换_Key_03

PS C:\Users\Administrator> DISM /online /Get-CurrentEdition

Deployment Image Servicing and Management tool
Version: 10.0.20348.1

Image Version: 10.0.20348.587

Current edition is:

Current Edition : ServerDatacenter

The operation completed successfully.
PS C:\Users\Administrator>

并且,我升级到的这个版本是最高的了,不能再升级为其他版本:

PS C:\Users\Administrator> DISM /online /Get-TargetEditions

Deployment Image Servicing and Management tool
Version: 10.0.20348.1

Image Version: 10.0.20348.587

Editions that can be upgraded to:

(The current edition cannot be upgraded to any target editions.)

The operation completed successfully.
PS C:\Users\Administrator>



5.在哪里可以找到转换密钥?

官方提供转换密钥:

https://learn.microsoft.com/en-us/windows-server/get-started/kms-client-activation-keys?tabs=server2022%2Cwindows10ltsc%2Cversion1803%2Cwindows81


注意

版本的切换并不是任意无限制的,有关哪些版本之间可以切换,官方是有详细说明的:

https://learn.microsoft.com/en-us/windows/deployment/upgrade/windows-edition-upgrades

https://learn.microsoft.com/en-us/windows-server/get-started/upgrade-overview

一般来说从更低级的版本升级到更高级的版本是受支持的;从更高级的版本降级到更低级的版本基本都不支持。