简体   繁体   English

Wix Service安装程序有时无法安装或启动

[英]Wix Service Installer sometimes fails to install or start

Sometimes when i am running my installer (build with wix) it fails to install or start the service. 有时,当我运行安装程序(使用wix构建)时,它无法安装或启动服务。 But the problem doesn't always appear, so most of the time it works and but now and then it fails. 但是问题并不总是会出现,因此在大多数情况下都可以解决,但有时又会失败。 My solutions until now are: 到目前为止,我的解决方案是:

  1. Retrying by pressing the retry button. 通过按重试按钮重试。
  2. Retrying by closing the installer and opening it again. 通过关闭安装程序并再次打开进行重试。
  3. Retrying by closing the installer and the windows file explorer and the reopening both. 通过关闭安装程序和Windows文件浏览器重试,然后重新打开两者。
  4. Disconnecting external drive and the reconnecting it and retrying the installer. 断开外部驱动器的连接,然后重新连接,然后重试安装程序。

But i am looking for how i can permanently solve it. 但是我正在寻找如何永久解决它。 Since i want to have a reliable installer. 由于我想要一个可靠的安装程序。

The following devices are used: 使用以下设备:

  1. Windows tablet with Windows 8.1 装有Windows 8.1的Windows平板电脑
  2. Windows tablet with Windows 10 Windows 10平板电脑
  3. Windows pc with Windows 10 装有Windows 10的Windows PC
  4. VirtualBox instance with Windows Server 2016 Windows Server 2016的VirtualBox实例
  5. VMWare instance with Windows 7 Windows 7的VMWare实例

Project specs: 项目规格:

  • .NET 4.7.1 .NET 4.7.1
  • Wix 3.11.1.2318 蜡3.11.1.2318

Verbose, Debug Logging : Maybe try to do verbose logging with extra debugging information and direct write without buffering (to prevent loss of log buffer due to crashes - the latter not really needed for your case, but leave it in) and see if you get more information about the runtime error: 详细的调试日志记录 :也许尝试使用额外的调试信息进行详细的日志记录,并在不进行缓冲的情况下直接写入日志(以防止由于崩溃而导致日志缓冲区丢失-后者并非您真正需要的情况,但请留在里面),看看是否得到有关运行时错误的更多信息:

msiexec.exe /i C:\\Path\\Your.msi /L*vx! C:\\Your.log


Some questions : 一些问题

  • Are you running any custom actions related to the service installation? 您是否正在运行与服务安装相关的任何自定义操作
  • What does your service actually do? 您的服务实际上是做什么的? Does it involve any database connections ? 是否涉及任何数据库连接
  • Does the error happen on specific machines only - or on all machines? 该错误特定计算机上 -或在所有计算机上发生吗? Is the machine in question a virtual machine? 相关机器是虚拟机吗?
  • Is it accurate that retrying makes the service eventually start ? 重试使服务最终启动是否准确?
  • What language is the service written in? 服务用什么语言书写? Managed code ? 托管代码 (yes, looks like it is) (是的,看起来像是)
  • This service is not a binary automatically converted to run as a service, is it? 该服务不是自动转换为服务运行的二进制文件 ,对吗? (guess not) (可能不会)
  • What does it say in the event viewer ? 事件查看器中怎么说? ( Windows + R eventvwr and OK ) Windows + R eventvwrOK

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM