2012-02-13 75 views
1

我正在使用WiX爲我們的產品開發安裝程序。我的安裝程序安裝的其中一項服務需要重新啓動。命令行'msiexec/norestart/fepmcs/qn'仍會重新啓動PC

在UI安裝過程中,它詢問用戶,如果用戶說「不」,則不會重新啓動。但是,使用靜默安裝,即使我指定了/norestart選項,它仍會重新啓動計算機。

這裏有沒有靜默安裝的情況下記錄,其中,如果用戶選擇「否」,它不重新啓動:

MSI (s) (F0:58) [04:42:00:795]: Windows Installer reconfigured the product. Product Name: MyProduct. Product Version: 1.0.0.0. Product Language: 1033. Manufacturer: MyOrg. Reconfiguration success or error status: 0. 

MSI (s) (F0:58) [04:42:00:795]: Value of RebootAction property is 
MSI (s) (F0:58) [04:42:00:795]: Windows Installer requires a system restart. Product Name: MyProduct. Product Version: 1.0.0.0. Product Language: 1033. Manufacturer: MyOrg. **Type of System Restart: 2. Reason for Restart: 1.** 

MSI (s) (F0:58) [04:42:00:796]: Product: MyProduct. Restart required. The installation or update for the product required a restart for all changes to take effect. The restart was deferred to a later time. 

這裏是哪裏,即使提供了/norestart選項日誌,發生了重新啓動:

MSI (s) (50:78) [04:37:06:985]: Windows Installer reconfigured the product. Product Name: MyProduct. Product Version: 1.0.0.0. Product Language: 1033. Manufacturer: MyOrg. Reconfiguration success or error status: 0. 

MSI (s) (50:78) [04:37:06:985]: Value of RebootAction property is 
MSI (s) (50:78) [04:37:06:985]: Windows Installer requires a system restart. Product Name: MyProduct. Product Version: 1.0.0.0. Product Language: 1033. Manufacturer: MyOrg. **Type of System Restart: 1. Reason for Restart: 1**. 

兩個日誌文件進行比較,我注意到以下區別:

成功案例: 類型系統重新啓動的:2.原因重啓:1.

失敗案例: 系統重新啓動的類型:1,原因重啓:1

我是否需要添加任何維克斯性能代碼來處理這種情況?

回答

2

嘗試添加REBOOT = ReallySuppress到您的命令行。

1

行爲與預期一致。

我錯過了一點。這是在修理過程中發生的。我忘記了修復會忽略任何傳遞的命令行參數。

相關問題