This content has been machine translated dynamically.
Dieser Inhalt ist eine maschinelle Übersetzung, die dynamisch erstellt wurde. (Haftungsausschluss)
Cet article a été traduit automatiquement de manière dynamique. (Clause de non responsabilité)
Este artículo lo ha traducido una máquina de forma dinámica. (Aviso legal)
此内容已经过机器动态翻译。 放弃
このコンテンツは動的に機械翻訳されています。免責事項
이 콘텐츠는 동적으로 기계 번역되었습니다. 책임 부인
Este texto foi traduzido automaticamente. (Aviso legal)
Questo contenuto è stato tradotto dinamicamente con traduzione automatica.(Esclusione di responsabilità))
This article has been machine translated.
Dieser Artikel wurde maschinell übersetzt. (Haftungsausschluss)
Ce article a été traduit automatiquement. (Clause de non responsabilité)
Este artículo ha sido traducido automáticamente. (Aviso legal)
この記事は機械翻訳されています.免責事項
이 기사는 기계 번역되었습니다.책임 부인
Este artigo foi traduzido automaticamente.(Aviso legal)
这篇文章已经过机器翻译.放弃
Questo articolo è stato tradotto automaticamente.(Esclusione di responsabilità))
Translation failed!
服务窗口
服务窗口功能提供了一种在 MCS 预配的 VM 上安排和自动执行操作的能力。此功能目前支持各种操作,例如重置操作系统磁盘和硬件配置更改。您可以安排这些操作,稍后返回验证完成情况,而无需手动执行更新。
-
您可以为特定的 VM 列表或整个计算机目录安排操作。每个操作都在指定的时间运行。可以为同一 VM 安排多个操作。但是,您不能为单个 VM 安排多个硬件更新。
-
您还可以:
- 为服务窗口添加描述。
- 提供详细消息,以便在操作运行时显示给任何已登录的用户。
- 配置在操作强制执行之前,为已登录用户保存工作而授予的缓冲分钟数。
优势
-
改进的用户体验和连续性
- 优雅的会话处理:您可以定义专业的通知,以便在 VM 关闭电源之前保存工作,而不是突然断开连接。
- 计划停机:您可以将繁重的更新任务移至非高峰时段(例如,凌晨 2:00),而无需在该时间手动登录。
- 经济高效的硬件更新:使用服务窗口更新硬件可为大型实施节省大量成本。此功能会自动分析 VM 是否需要重新启动才能应用设置。因此,通过避免不必要的重新启动,服务窗口可最大限度地降低这些费用。
高级硬件灵活性
- 更新硬件配置:使用服务窗口安排硬件更新。系统会智能地管理更新流程,检查是否需要重新启动并处理会话注销,确保您的目录能够满足新的资源需求,而无需手动监督。
- 灵活的 SKU 重新配置:轻松更新 SKU,这在以前需要手动重新创建目录。
- 现有 VM 的休眠支持:克服了“临时磁盘”限制。服务窗口允许 MCSIO 驱动程序将页面文件重新定位到 C: 驱动器,并为已部署的 VM 启用休眠属性。
重要注意事项
- 用户通知:已登录用户会收到有关服务窗口操作的初始警报,确保他们有足够的时间保存工作。通知期结束后,计算机将自动关闭电源以执行操作。
限制
无法更改现有 VM 上的 WBC 磁盘大小。它可以应用于新 VM 的计算机目录。
服务窗口操作
-
服务窗口目前支持使用 PowerShell 重置操作系统磁盘和更改硬件配置。
-
PowerShell 命令:本文概述了通用命令,而详细的、特定于管理程序的脚本可在我们的 GitHub 页面 https://github.com/citrix/citrix-mcs-sdk-samples/ 上找到。
重置操作系统磁盘
- 可以使用 PowerShell 命令 `New-ProvMaintenanceCycle` 重置操作系统磁盘。该命令为整个目录或特定 VM 创建新的服务窗口。周期在您在 `ScheduledStartTimeInUTC` 中指定的时间开始。您还提供 `MaxDurationInMinutes`,它指示服务窗口可以运行的最长时间。
示例:重置特定 VM 的操作系统磁盘
New-ProvMaintenanceCycle -Operation ResetOSDisk -MaintenanceCycleDescription "Resetting Boot Disk" -StartsNow -MaxDurationInMinutes 100 -ProvisioningSchemeName CVC -PurgeDBAfterInDays 1 -SessionWarningTimeInMinutes 15 -SessionWarningLogOffTitle "Scheduled Maintenance" -SessionWarningLogOffMessage "There is a scheduled maintenance coming up and involves turning off the machine, please save your work and log out, Thank You" -VMName VDA02,VDA03
<!--NeedCopy-->
示例:重置整个目录的操作系统磁盘
New-ProvMaintenanceCycle -Operation ResetOSDisk -MaintenanceCycleDescription "Resetting Boot Disk" -StartsNow -MaxDurationInMinutes 100 -ProvisioningSchemeName CVC -PurgeDBAfterInDays 1 -SessionWarningTimeInMinutes 15 -SessionWarningLogOffTitle "Scheduled Maintenance" -SessionWarningLogOffMessage "There is a scheduled maintenance coming up and involves turning off the machine, please save your work and log out, Thank You" -AllVMs
<!--NeedCopy-->
更新硬件设置
使用服务窗口安排硬件更新,从而完全控制更改何时生效。您可以选择仅针对新创建的 VM、整个目录(新 VM 和现有 VM)或根据需要针对特定 VM。
- 要更新新 VM 或整个目录的硬件设置,请选择一个预配方案版本并运行 PowerShell 命令 `New-ProvSchemeHardwareUpdate`。您可以将以前创建的预配方案版本应用于 VM。您还可以在具有临时磁盘的 VM 上启用休眠。
- 要更新特定 VM 的硬件设置,请选择一个 VM 配置版本并运行 PowerShell 命令 `New-ProvVmHardwareUpdate`。
重要注意事项
- 在计划硬件更新后添加到目录的新计算机将继续使用旧规范创建,直到应用新规范的指定 UTC 时间。
- 在创建服务窗口期间,单个验证失败会阻止创建周期并返回错误消息。
- 要启用休眠,请考虑以下事项:
- VDA 版本必须大于 2503。
- 必须安装 Machine Creation Services I/O (MCSIO)。
- 计算机配置文件必须支持休眠。
- VM SKU 和操作系统必须支持休眠。
- 如果启用了 VBS,则还必须启用 Hyper-V。嵌套虚拟化需要 VM 上的受信任启动。
- 可用操作系统磁盘大小必须大于 VM 的内存大小。
在整个计算机目录或新 VM 上安排硬件更新
- 运行
New-ProvSchemeVersion以创建具有更新硬件设置的新预配方案版本。有关详细信息,请参阅 SDK 文档。 - 运行 PowerShell 命令
New-ProvSchemeHardwareUpdate以安排服务窗口进行硬件更新,如预配方案版本中指定。
示例:计算机目录中的 AllVMs(新 VM 和现有 VM)被考虑进行更新:
New-ProvSchemeHardwareUpdate -ProvisioningSchemeVersion 4 -MaintenanceCycleDescription "Updating RAM and CPU Count to 8GB and 4" -StartsNow -MaxDurationInMinutes 100 -ProvisioningSchemeName CVC -PurgeDBAfterInDays 1 -SessionWarningTimeInMinutes 15 -SessionWarningLogOffTitle "Scheduled Maintenance" -SessionWarningLogOffMessage "There is a scheduled maintenance coming up and involves turning off the machine, please save your work and log out, Thank You" -AllVMs
<!--NeedCopy-->
示例:计算机目录中的 NewVMsOnly(新 VM 和现有 VM)被考虑进行更新:
New-ProvSchemeHardwareUpdate -ProvisioningSchemeVersion 4 -MaintenanceCycleDescription "Updating RAM and CPU Count to 8GB and 4" -StartsNow -MaxDurationInMinutes 100 -ProvisioningSchemeName CVC -PurgeDBAfterInDays 1 -SessionWarningTimeInMinutes 15 -SessionWarningLogOffTitle "Scheduled Maintenance" -SessionWarningLogOffMessage "There is a scheduled maintenance coming up and involves turning off the machine, please save your work and log out, Thank You" -NewVMsOnly
<!--NeedCopy-->
- 运行 `Get-ProvSchemeHardwareUpdate` 以检索与硬件方案更新关联的服务窗口对象。示例:
- Get-ProvSchemeHardwareUpdate -MaintenanceCycleId xxxx-xxxx-yyyy-zzzz
<!--NeedCopy-->
在特定 VM 上安排硬件更新
- 1. 运行 `New-ProvVmConfiguration` 以创建新的预配 VM 配置。有关详细信息,请参阅 [SDK 文档](https://developer-docs.citrix.com/en-us/citrix-virtual-apps-desktops-sdk/2511/machinecreation/new-provvmconfiguration)。
- 运行 PowerShell 命令
New-ProvVmHardwareUpdate以安排服务窗口进行硬件更新,如 VM 配置版本中指定。
注意:
对于每个 VM,任何个性化设置(VM 配置版本)始终优先于预配方案版本中定义的规范。如果 VM 上的特定设置未个性化,则其值将从关联的预配方案版本继承。
- 示例:
New-ProvVmHardwareUpdate -ProvVmConfigurationVersion 4 -StartsNow -MaxDurationInMinutes 100 -ProvisioningSchemeName CVC -VMName AbcTest01
<!--NeedCopy-->
运行 Get-ProvVmHardwareUpdate 以检索与硬件 VM 更新关联的服务窗口对象。示例:
Get-ProvVmHardwareUpdate -MaintenanceCycleId xxxx-xxxx-yyyy-zzzz
<!--NeedCopy-->
您还可以使用 Remove-ProvVmConfiguration 命令删除用于创建预配 VM 版本的个性化设置。示例:
Remove-ProvVmConfiguration -Version 2 -VMName AbcTest01
<!--NeedCopy-->
与服务窗口关联的其他 PowerShell 命令
-
Get-ProvMaintenanceCycle:检索所有服务窗口的信息。示例:Get-ProvMaintenanceCycle -MaintenanceCycleId 10073b8e-7e94-4527-8580-0e448eae0ad1 <!--NeedCopy--> -
Get-ProvMaintenanceCycleVM:检索单个 VM 的每个服务窗口操作的信息及其状态。示例:Get-ProvMaintenanceCycleVM -MaintenanceOperation HardwareUpdate -VirtualMachineSid 42263076-44ae-1ff9-f58b-62d57ddf8db5 <!--NeedCopy-->各种服务窗口状态包括:
- 正在运行
- 失败
- 已完成
- 正在取消
- 已取消
- 未处理
- 待处理
- 不完整
- 已修复
- 正在恢复
-
Remove-ProvMaintenanceCycle:当服务窗口不活动时,删除服务窗口。示例:Remove-ProvMaintenanceCycle -MaintenanceCycleId 867af1ba-5b72-402e-9dc3-033298248f8e <!--NeedCopy--> -
Cancel-ProvMaintenanceCycle:如果 MCS 尚未在 VM 上启动操作,则此 PowerShell 命令会取消该操作。MCS 不会取消当前正在 VM 上运行的操作。示例:Cancel-ProvMaintenanceCycle -MaintenanceCycleId 867af1ba-5b72-402e-9dc3-033298248f8e <!--NeedCopy--> -
Restart-ProvMaintenanceCycle:如果服务窗口因外部原因(例如虚拟机管理程序关闭或时间不足)而失败或未完成,此命令有助于重新启动周期并处理任何失败或未处理的作业。示例:Restart-ProvMaintenanceCycle -MaintenanceCycleId 4f363b78-458a-403a-82e5-7fcc6caa498b -ScheduledStartTimeInUTC "June 19th 2024, 6AM" -MaxAllocatedDurationInMinutes 400 <!--NeedCopy--> -
Update-ProvMaintenanceCycle:如果服务窗口已计划但尚未开始,此命令会更改某些参数。示例:更新最大持续时间:
Update-ProvMaintenanceCycle -MaintenanceCycleId 4f363b78-458a-403a-82e5-7fcc6caa498b -MaxDurationInMinutes 100 <!--NeedCopy-->示例:更新预配方案的虚拟机:
Update-ProvMaintenanceCycle -MaintenanceCycleId 4f363b78-458a-403a-82e5-7fcc6caa498b -ProvisioningSchemeUid 867af1ba-5b72-402e-9dc3-033298248f8e -VMName ncn01,ncn02 <!--NeedCopy-->
This Preview product documentation is Citrix Confidential.
You agree to hold this documentation confidential pursuant to the terms of your Citrix Beta/Tech Preview Agreement.
The development, release and timing of any features or functionality described in the Preview documentation remains at our sole discretion and are subject to change without notice or consultation.
The documentation is for informational purposes only and is not a commitment, promise or legal obligation to deliver any material, code or functionality and should not be relied upon in making Citrix product purchase decisions.
If you do not agree, select I DO NOT AGREE to exit.