排查 ASDK 问题Troubleshoot the ASDK

本文提供了 Azure Stack 开发工具包 (ASDK) 的常见故障排除信息。This article provides common troubleshooting info for the Azure Stack Development Kit (ASDK). 有关 Azure Stack 集成系统的帮助,请参阅 Azure Stack 故障排除For help with Azure Stack integrated systems, see Azure Stack troubleshooting.

由于 ASDK 是一个评估环境,因此 Azure 支持不提供支持。Because the ASDK is an evaluation environment, Azure Support does not provide support. 如果遇到了文档未记录的问题,可以在 Azure Stack MSDN 论坛上获得专家的帮助。If you're experiencing an issue that isn't documented, you can get help from experts on the Azure Stack MSDN Forum.

部署Deployment

部署失败Deployment failure

如果安装期间发生失败,可以使用部署脚本的 -rerun 选项从失败的步骤重新开始部署。If you experience a failure during installation, you can restart the deployment from the failed step by using the -rerun option of the deployment script. 例如:For example:

cd C:\CloudDeployment\Setup
.\InstallAzureStackPOC.ps1 -Rerun

部署结束时,PowerShell 会话仍保持打开状态,但不显示任何输出At the end of the deployment, the PowerShell session is still open and doesn't show any output

此行为可能是选择 PowerShell 命令窗口后的默认行为。This behavior is probably just the result of the default behavior of a PowerShell command window when it's been selected. ASDK 部署成功,但选择窗口时,脚本已暂停。The ASDK deployment has succeeded but the script was paused when selecting the window. 可以通过在命令窗口的标题栏中查找“select”一词,来验证安装是否已完成。You can verify setup has completed by looking for the word "select" in the titlebar of the command window. 按 ESC 键取消选择窗口,然后即会显示完成消息。Press the ESC key to unselect it, and the completion message should be shown after it.

不允许模板验证错误参数 osProfileTemplate validation error parameter osProfile is not allowed

如果在模板验证期间遇到错误消息,该消息指出系统不允许参数 'osProfile',请确保对以下组件使用正确的 API 版本:If you get an error message during template validation that the parameter 'osProfile' is not allowed, make sure you are using the correct versions of the APIs for these components:

若要将 VHD 从 Azure 复制到 Azure Stack,请使用 AzCopy 7.3.0To copy a VHD from Azure to Azure Stack, use AzCopy 7.3.0. 请联系供应商以解决映像本身的问题。Work with your vendor to resolve issues with the image itself. 若要详细了解 Azure Stack 的 WALinuxAgent 要求,请参阅 Azure LinuX 代理For more information about the WALinuxAgent requirements for Azure Stack, see Azure LinuX Agent.

部署因缺少外部访问而失败Deployment fails due to lack of external access

如果部署在需要外部访问的阶段失败,则会返回一个异常,如以下示例所示:When deployment fails at stages where external access is required, an exception like the following example will be returned:

An error occurred while trying to test identity provider endpoints: System.Net.WebException: The operation has timed out.
   at Microsoft.PowerShell.Commands.WebRequestPSCmdlet.GetResponse(WebRequest request)
   at Microsoft.PowerShell.Commands.WebRequestPSCmdlet.ProcessRecord()at, <No file>: line 48 - 8/12/2018 2:40:08 AM

如果发生此错误,请查看部署网络流量文档,确保满足所有最低的网络要求。If this error occurs, make sure all minimum networking requirements have been met by reviewing the deployment network traffic documentation. 合作伙伴也可使用网络检查器工具(在合作伙伴工具包中提供)。A network checker tool is also available for partners as part of the Partner Toolkit.

其他部署失败通常是由于在连接到 Internet 上的资源时出现问题。Other deployment failures are typically due to problems connecting to resources on the Internet.

若要验证能否连接到 Internet 上的资源,可以执行以下步骤:To verify connectivity to resources on the Internet, you can perform the following steps:

  1. 打开 PowerShell。Open PowerShell.
  2. 通过 Enter-PSSession 连接到 WAS01 或任何 ERCs VM。Enter-PSSession to the WAS01 or any of the ERCs VMs.
  3. 运行以下 cmdlet:Run the following cmdlet:
    Test-NetConnection login.chinacloudapi.cn -port 443
    

如果此命令失败,请验证TOR 交换机以及任何其他的网络设备是否已配置为允许网络流量If this command fails, verify the TOR switch and any other network devices are configured to allow network traffic.

虚拟机Virtual machines

在 Azure Stack 中部署 VM 之前,必须先添加 Windows Server 映像和库项。A Windows Server image and gallery item must be added before deploying VMs in Azure Stack.

重启 Azure Stack 主机之后,某些 VM 不会自动启动After restarting my Azure Stack host, some VMs don't automatically start

将重新启动主机之后,可能会发现,Azure Stack 服务并非立即可用。After rebooting your host, you may notice Azure Stack services aren't immediately available. 这是因为 Azure Stack 基础结构 VM 与 RP 需要花费一段时间来检查一致性,但最终会自动启动。This is because Azure Stack infrastructure VMs and RPs take some time to check consistency, but will eventually start automatically.

另外还可能发现,在重新启动 ASDK 主机之后,租户 VM 不会自动启动。You might also notice that tenant VMs don't automatically start after a reboot of the ASDK host. 可以通过几个手动步骤将它们联机:You can bring them online with a few manual steps:

  1. 在 ASDK 主机上,从“开始”菜单启动“故障转移群集管理器”。 On the ASDK host, start Failover Cluster Manager from the Start Menu.
  2. 选择群集“S-Cluster.azurestack.local”。 Select the cluster S-Cluster.azurestack.local.
  3. 选择“角色” 。Select Roles.
  4. 租户 VM 显示为“已保存”状态。 Tenant VMs appear in a saved state. 所有基础结构 VM 运行后,右键单击租户 VM,并选择“启动”以恢复该 VM。 Once all Infrastructure VMs are running, right-click the tenant VMs and select Start to resume the VM.

我已删除某些 VM,但仍在磁盘上看到 VHD 文件I've deleted some VMs, but still see the VHD files on disk

此行为是设计使然:This behavior is by design:

  • 删除 VM 时,不会删除 VHD。When you delete a VM, VHDs aren't deleted. 磁盘是资源组中的独立资源。Disks are separate resources in the resource group.
  • 删除存储帐户后,Azure 资源管理器会立即反映删除结果,但其中的磁盘仍保留在存储中,直到运行垃圾收集为止。When a storage account gets deleted, the deletion is visible immediately through Azure Resource Manager, but the disks it may contain are still kept in storage until garbage collection runs.

如果看到“孤立的”VHD,必须知道它们是否包含在已删除的存储帐户的文件夹中。If you see "orphan" VHDs, it's important to know if they're part of the folder for a storage account that was deleted. 如果未删除存储帐户,则正常情况下会保留 VHD。If the storage account wasn't deleted, it's normal that the VHDs remain.

可以在管理存储帐户中详细了解如何配置保留阈值和按需回收。You can read more about configuring the retention threshold and on-demand reclamation in manage storage accounts.

存储Storage

存储回收Storage reclamation

回收的容量最长可能需要在 14 小时后才显示在门户中。It can take up to 14 hours for reclaimed capacity to show up in the portal. 空间回收取决于多种因素,包括块 Blob 存储中内部容器文件的用量百分比。Space reclamation depends on various factors including usage percentage of internal container files in block blob store. 因此,我们无法保证运行垃圾回收器时可回收的空间量,这取决于删除的数据量。Therefore, depending on how much data is deleted, there's no guarantee on the amount of space that could be reclaimed when garbage collector runs.

后续步骤Next steps

访问 Azure Stack 支持论坛Visit the Azure Stack support forum