Windows Installer错误1316.安装程序查找错误的文件名 [英] Windows Installer Error 1316. Installer looks for wrong filename

查看:212
本文介绍了Windows Installer错误1316.安装程序查找错误的文件名的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我正在尝试为我的应用程序实现以下自我更新机制:如果有可用的更新,我的应用程序将下载(由WiX生成的)MSI软件包,并将其以任意名称写入其AppData文件夹中.然后,应用程序通过调用来启动更新过程

I'm trying to implement the following self-update mechanism for my application: If an update is available, my application downloads the (WiX generated) MSI package and writes it to its AppData folder with an arbitrary name. The application then initiates the update process by calling

msiexec /fvomus "<ArbitraryName>.msi" /qn /L "<ArbitraryName>.msi.log" REINSTALL=ALL REINSTALLMODE=vomus

这样我得到一个错误1316,然后安装以错误状态1603终止.

With this I get an error 1316 and the installation then terminates with error status 1603.

MSI的原始文件名是CCWirelessServer.msi,但是正如我之前所说,我的应用程序使用任意名称(例如ba17b82d-0ab8-4fc9-aea8-62830042d49f.msi)写入安装程序包.现在,我注意到Windows Installer出于某种原因正在寻找CCWirelessServer.msi文件,而不是正确的临时文件名.您可以在下面的日志中看到它.

The original filename of the MSI is CCWirelessServer.msi, but as I said before, my application writes the installer package with an arbitrary name, for example ba17b82d-0ab8-4fc9-aea8-62830042d49f.msi. Now what I noticed is that Windows Installer is for some reason looking for a CCWirelessServer.msi file and not for the correct temporary filename. You can see this in the log below.

为什么Windows Installer不使用我通过命令行提供的文件名?我的命令行参数或安装程序包有问题吗?

Why is Windows Installer not using the filename I provided via command line? Is it a problem with my command line arguments or with the installer package?

这是日志:

=== Logging started: 24.02.2014  09:16:30 ===
Action start 09:16:30: INSTALL.
Action start 09:16:30: FindRelatedProducts.
Action ended 09:16:30: FindRelatedProducts. Return value 0.
Action start 09:16:30: ValidateProductID.
Action ended 09:16:30: ValidateProductID. Return value 1.
Action start 09:16:30: CostInitialize.
Action ended 09:16:30: CostInitialize. Return value 1.
Action start 09:16:30: FileCost.
Action ended 09:16:30: FileCost. Return value 1.
Action start 09:16:30: CostFinalize.
Action ended 09:16:30: CostFinalize. Return value 1.
Action start 09:16:30: MigrateFeatureStates.
Action ended 09:16:30: MigrateFeatureStates. Return value 0.
Action start 09:16:30: InstallValidate.
Action ended 09:16:30: InstallValidate. Return value 1.
Action start 09:16:30: RemoveExistingProducts.
Action ended 09:16:30: RemoveExistingProducts. Return value 0.
Action start 09:16:30: InstallInitialize.
Action ended 09:16:30: InstallInitialize. Return value 1.
Action start 09:16:30: ProcessComponents.
Action ended 09:16:30: ProcessComponents. Return value 1.
Action start 09:16:30: UnpublishFeatures.
Action ended 09:16:30: UnpublishFeatures. Return value 1.
Action start 09:16:30: RemoveRegistryValues.
Action ended 09:16:30: RemoveRegistryValues. Return value 1.
Action start 09:16:30: RemoveShortcuts.
Action ended 09:16:30: RemoveShortcuts. Return value 1.
Action start 09:16:30: CAUninstallAsService.
Action ended 09:16:30: CAUninstallAsService. Return value 1.
Action start 09:16:30: RemoveFiles.
Action ended 09:16:30: RemoveFiles. Return value 1.
Action start 09:16:30: InstallFiles.
Action ended 09:16:30: InstallFiles. Return value 1.
Action start 09:16:30: CAInstallAsServiceRollback.
Action ended 09:16:30: CAInstallAsServiceRollback. Return value 1.
Action start 09:16:30: CAInstallAsService.
Action ended 09:16:30: CAInstallAsService. Return value 1.
Action start 09:16:30: CreateShortcuts.
Action ended 09:16:30: CreateShortcuts. Return value 1.
Action start 09:16:30: WriteRegistryValues.
Action ended 09:16:30: WriteRegistryValues. Return value 1.
Action start 09:16:30: RegisterUser.
Action ended 09:16:30: RegisterUser. Return value 0.
Action start 09:16:30: RegisterProduct.
MSI (s) (4C:50) [09:16:30:406]: Product: Wireless Server -- Error 1316. A network error occurred while attempting to read from the file: C:\ProgramData\MyCompanyName\Wireless Server\Updates\CCWirelessServer.msi

Error 1316. A network error occurred while attempting to read from the file: C:\ProgramData\MyCompanyName\Wireless Server\Updates\CCWirelessServer.msi
Action ended 09:16:30: RegisterProduct. Return value 3.
Action ended 09:16:30: INSTALL. Return value 3.
MSI (s) (4C:50) [09:16:30:419]: Windows Installer reconfigured the product. Product Name: Wireless Server. Product Version: 1.0.0.0. Product Language: 1033. Manufacturer: MyCompanyName. Reconfiguration success or error status: 1603.

=== Logging stopped: 24.02.2014  09:16:30 ===


只是为了验证问题是否出在任意文件名上,我尝试使用安装程序的原始文件名编写更新程序包,并且可以正常工作!

Just to verify that the problem is with the arbitrary filename I tried write the update package with the original filename of the installer, and it works!

推荐答案

不支持尝试更改MSI的文件名并执行次要升级.参见:

Trying to change the filename of the MSI and performing a minor upgrade is not supported. See:

Windows Installer最佳做法

保持软件包名称和软件包代码一致.

.msi文件的名称可以帮助用户识别 包,但在不更改名称的情况下,请勿更改名称 产品代码.

The .msi file can be given any name that helps users identify the package, but the name should not be changed without also changing the product code.

•为您的.msi文件提供一个用户友好的名称,该名称使用户能够 确定Windows Installer程序包的内容.

•Give your .msi file a user-friendly name that enables the user to identify the contents of the Windows Installer package.

•产品代码是应用程序的主要标识 并且必须在对内容进行全面更新后进行更改 应用.有关信息,请参阅产品代码和更改产品. 代码.更改应用程序.msi文件的名称被认为是 全面的变更,并且始终需要相应的变更 产品代码以保持一致性.

•The product code is the principal identification of an application and must change whenever there is a comprehensive update to the application. For information, see ProductCode and Changing the Product Code. Changing the name of the application's .msi file is considered a comprehensive change and always requires a corresponding change of the product code to maintain consistency.

•程序包代码是安装程序用于以下目的的主要标识符: 搜索并验证给定安装的正确软件包. 任何两个不完全相同的.msi文件都不应具有相同的程序包代码. 如果在不更改软件包代码的情况下更改了软件包,则 如果仍然可以访问安装程序,则安装程序可能不会使用较新的程序包 到安装程序.程序包代码存储在修订号中 摘要信息流的摘要属性.

•The package code is the primary identifier used by the installer to search for and validate the correct package for a given installation. No two nonidentical .msi files should ever have the same package code. If a package is changed without changing the package code, the installer may not use the newer package if both are still accessible to the installer. The package code is stored in the Revision Number Summary Property of the Summary Information Stream.

•请注意,产品代码和包装代码GUID中的字母必须全部为 大写.

•Note that letters in product code and package code GUIDs must all be uppercase.

更改产品代码

如果满足以下任一条件,则必须更改产品代码 更新:

The product code must be changed if any of the following are true for the update:

•原始和更新产品在计算机上的共存安装 同一系统必须是可能的.

•Coexisting installations of both original and updated products on the same system must be possible.

•.msi文件的名称已更改.

•The name of the .msi file has been changed.

•现有组件的组件代码已更改.

•The component code of an existing component has changed.

•从现有功能中删除了一个组件.

•A component is removed from an existing feature.

•现有功能已成为现有功能的子级 功能.

•An existing feature has been made into a child of an existing feature.

•现有的子功能已从其父功能中删除.

•An existing child feature has been removed from its parent feature.

为什么更改MSI文件的名称需要重大升级?

这篇关于Windows Installer错误1316.安装程序查找错误的文件名的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆