在配置管理器中的应用程序部署的技术参考Technical Reference for Application Deployment in Configuration Manager

适用范围: Configuration Manager (Current Branch)Applies to: Configuration Manager (current branch)

在本文中,你将了解应用程序部署的工作原理。In this article, you'll learn how application deployments work.

准备工作Before You Begin

如果要对应用程序部署进行故障排除,则在检查客户端日志时,有几个项很有用。When troubleshooting application deployments, there are multiple items that can be useful when reviewing client logs. 这些项包括:These items include:

  • 应用程序 CI IDApplication CI ID
  • 应用程序唯一 IDApplication Unique ID
  • 部署类型唯一 IDDeployment Type Unique ID
  • 应用程序部署唯一 ID(也称为分配唯一 ID)Application Deployment Unique ID (also known as Assignment Unique ID)
  • 应用程序部署目的Application Deployment Purpose
  • 内容唯一 IDContent Unique ID
  • 集合 ID 和名称Collection ID and Name
  • 集合类型Collection Type

要简化故障排除,可针对 Configuration Manager 数据库运行如下所示的 SQL 查询,以获取上面列出的信息。To simplify troubleshooting, you can run a SQL query similar to below against the Configuration Manager database to obtain the information listed above.

SELECT APP.CI_ID [App CI ID], APP.CI_UniqueID [App Unique ID], APP.DisplayName [App Name],
DT.CI_UniqueID [DT Unique ID], DT.ContentId [DT Content ID],
CIA.Assignment_UniqueID [Assignment ID], CIA.CollectionID, CIA.CollectionName,
CASE CIA.OfferTypeID WHEN 0 THEN 'Required' WHEN 2 THEN 'Available' WHEN 3 THEN 'Simulate' ELSE 'Unknown' END AS [Deployment Purpose],
CASE C.CollectionType WHEN 1 THEN 'User Collection' WHEN 2 THEN 'Device Collection' ELSE 'Unknown' END AS [Collection Type],
DT.Technology, DT.DisplayName [DT Name]
FROM fn_ListApplicationCIs(1033) APP
JOIN fn_ListDeploymentTypeCIs(1033) DT ON DT.AppModelName = APP.ModelName AND DT.IsLatest = 1
LEFT JOIN v_CIAssignmentToCI CIACI ON CIACI.CI_ID = APP.CI_ID
LEFT JOIN v_CIAssignment CIA ON CIACI.AssignmentID = CIA.AssignmentID
LEFT JOIN v_Collection C ON C.CollectionID = CIA.CollectionID
WHERE APP.IsLatest = 1 AND APP.DisplayName = 'Application Name' -- Replace Application Name

重要

执行此查询时,必须使用“应用程序属性”的“常规信息”选项卡中列出的应用程序名称,而不是使用“应用程序属性”的“软件中心”选项卡中列出的本地化应用程序名称 。When you execute this query, you must use the Application Name listed in the General Information tab of Application Properties, instead of using the Localized application name listed in the Software Center tab of Application properties.

后续步骤Next Steps