首页
学习
活动
专区
圈层
工具
发布
社区首页 >问答首页 >使用Wix3.9及以上的自定义操作RegisterComPlus发生错误

使用Wix3.9及以上的自定义操作RegisterComPlus发生错误
EN

Stack Overflow用户
提问于 2018-10-15 13:03:17
回答 1查看 673关注 0票数 2

在微软,我们使用WIX工具集3.5.2519.0已经很长时间了,为我们的产品构建安装程序和补丁(,又名SCSM)。最近我们需要更新到WIX 3.14.0.1703,因为这个版本支持TLS1.2。

使用while 3.14.0.1703构建我们的项目进行得很顺利,但是在安装它时,我得到了以下错误:

然后,我用所有的WIX版本一个接一个地构建了这个产品,下面是结果:

产品与WIX ToolSet版本3.8和更低的ar精细和安装程序工作良好。

但是使用ToolSet 3.9及更高版本时,安装程序会出现错误:在执行自定义操作RegisterComPlus时发生错误

日志的片段:

代码语言:javascript
复制
Action start 21:11:37: RegisterTypeLibraries.

MSI (s) (48:B0) [21:11:37:585]: Doing action: SelfRegModules

Action ended 21:11:37: RegisterTypeLibraries. Return value 0.

Action start 21:11:37: SelfRegModules.

MSI (s) (48:B0) [21:11:37:588]: Doing action: RegisterComPlus

Action ended 21:11:37: SelfRegModules. Return value 1.

MSI (s) (48:B0) [21:11:37:589]: Note: 1: 2205 2:  3: Complus 

MSI (s) (48:B0) [21:11:37:589]: Note: 1: 2228 2:  3: Complus 4: SELECT `ComponentId`,  `FileName`, `Component`.`Directory_`, `ExpType`, `Component`.`Action`, `Component`.`Installed`  FROM `Complus`, `Component`, `File` WHERE `Complus`.`Component_` = `Component` AND `Component`.`KeyPath` = `File`.`File` AND (`Action` = 1 OR `Action` = 2) 

Action start 21:11:37: RegisterComPlus.

MSI (s) (48:B0) [21:11:37:591]: Note: 1: 2265 2:  3: -2147287035 

MSI (s) (48:B0) [21:11:37:591]: Machine policy value 'DisableRollback' is 0

MSI (s) (48:B0) [21:11:37:592]: Note: 1: 1402 2: 

HKEY_LOCAL_MACHINE\Software\Microsoft\Windows\CurrentVersion\Installer\Rollback\Scripts 3: 2 

Action ended 21:11:37: RegisterComPlus. Return value 0.

MSI (s) (48:B0) [21:11:37:592]: Note: 1: 1402 2: 

HKEY_LOCAL_MACHINE\Software\Microsoft\Windows\CurrentVersion\Installer\Rollback\Scripts 3: 2 

MSI (s) (48:B0) [21:11:37:592]: No System Restore sequence number for this installation.

MSI (s) (48:B0) [21:11:37:592]: Unlocking Server

MSI (s) (48:B0) [21:11:37:602]: Note: 1: 2717 2: 

_Set_Rollback_RemoveCodeGroup.1CA03A32_06E0_4726_8E63_FEA4484D9D6F 
DEBUG: Error 2717:  Bad action condition or error calling custom action '_Set_Rollback_RemoveCodeGroup.1CA03A32_06E0_4726_8E63_FEA4484D9D6F'.

MSI (s) (48:74) [21:11:37:622]: I/O on thread 720 could not be cancelled. Error: 1168

MSI (s) (48:74) [21:11:37:622]: I/O on thread 1244 could not be cancelled. Error: 1168

MSI (s) (48:74) [21:11:37:622]: I/O on thread 3392 could not be cancelled. Error: 1168

MSI (s) (48:74) [21:11:37:622]: I/O on thread 928 could not be cancelled. Error: 1168

MSI (s) (48:74) [21:11:37:622]: I/O on thread 680 could not be cancelled. Error: 1168

MSI (s) (48:74) [21:11:37:622]: I/O on thread 4528 could not be cancelled. Error: 1168

MSI (s) (48:74) [21:11:37:622]: I/O on thread 2156 could not be cancelled. Error: 1168

MSI (s) (48:74) [21:11:37:622]: I/O on thread 2316 could not be cancelled. Error: 1168

MSI (s) (48:74) [21:11:37:622]: I/O on thread 3980 could not be cancelled. Error: 1168

MSI (s) (48:74) [21:11:37:622]: I/O on thread 5172 could not be cancelled. Error: 1168

MSI (s) (48:74) [21:11:37:622]: I/O on thread 2724 could not be cancelled. Error: 1168

MSI (s) (48:B0) [21:11:37:622]: Product: Microsoft System Center Service Manager -- The installer has encountered an unexpected error installing this package. This may indicate a problem with this package. The error code is 2717. The arguments are: _Set_Rollback_RemoveCodeGroup.1CA03A32_06E0_4726_8E63_FEA4484D9D6F, ,
 

The installer has encountered an unexpected error installing this package. This may indicate a problem with this package. The error code is 2717. The arguments are: _Set_Rollback_RemoveCodeGroup.1CA03A32_06E0_4726_8E63_FEA4484D9D6F, , 
Action ended 21:11:37: INSTALL. Return value 3.

在WIX Toolset 3.9及以上版本中是否有任何更改正在破坏我的安装程序?对此有什么决议吗?

EN

回答 1

Stack Overflow用户

发布于 2018-10-16 07:52:42

嗯,到目前为止还没有什么建议。这将不是一个答案,但一些建议,试图让你去帮助自己,。这种情况经常发生在部署问题上,因为它们很难调试或确定有限的可用信息发生了什么。

在我看来,这可能不是COM+问题,因为看起来自定义操作完成了OK:

代码语言:javascript
复制
Action ended 21:11:37: RegisterComPlus. Return value 0.

让我们试一试远点的机会。请原谅我,因为很多这样的事情都会有点出格的。鱼雷。全面展开及所有这些:-) (寻找掩护):

  1. 比较痛苦- :-):我可以比较工作的MSI和使用这里发现的比较方法的新MSI。我不认为你会发现很多,但可能应该做。直接比较MSI和用dark.exe进行反编译?后者没有什么逻辑意义,但我想看看WiX链接MSI的方式是否发生了变化。
  2. 消除复杂性:我喜欢取出复杂的部分,看看安装的其余部分是否正常。这可能真的是浪费时间,但有时会发光。
代码语言:javascript
复制
- I would take out that merge module that adds that custom action and verify that the rest of the package installs as expected. Sometimes this doesn't work if there is high coupling going on for the custom actions (obviously).
- You can also set a condition for some custom actions to **`0`**. This should prevent the custom action from running. You can add **`AND 0`** if there is an existing condition. 

  1. 禁用回滚?:又一次尝试。禁用MSI回滚并尝试在干净的虚拟环境上进行测试安装?查看回滚自定义操作中是否存在问题。我会使用DISABLEROLLBACK性质来禁用回滚。请注意,禁用回滚不是解决方案!(对于发现这一点的其他人来说,必须提及)。
  2. 自定义操作源访问:如果您可以访问自定义操作源代码,我将尝试使用Visual进行交互调试,如此处所述:调试C#自定义操作。您在调试模式下编译代码(所以您的MSI中有调试dll-请确保不包括那些意外地用于公开发布!)并显示来自自定义操作的消息框,然后附加Visual调试器并逐步执行代码。对于本机代码附加到msiexec.exe,对于托管代码附加到rundll32.exe
票数 1
EN
页面原文内容由Stack Overflow提供。腾讯云小微IT领域专用引擎提供翻译支持
原文链接:

https://stackoverflow.com/questions/52817451

复制
相关文章

相似问题

领券
问题归档专栏文章快讯文章归档关键词归档开发者手册归档开发者手册 Section 归档