[wix-users] WixQuietExec Error

Christopher Painter chrpai at iswix.com
Wed Feb 15 11:29:33 PST 2017


In 15 years I've yet to find a windows service that couldn't be installed using the ServiceInstall table.  You might have to understand the problem and work it a bit but it will work without a custom action.


________________________________
From: wix-users <wix-users-bounces at lists.wixtoolset.org> on behalf of Orzyszek Andreas <Andreas.Orzyszek at dentsplysirona.com>
Sent: Wednesday, February 15, 2017 4:42 AM
To: 'WiX Toolset Users Mailing List'
Subject: [wix-users] WixQuietExec Error

Hi,

a new week with new problems …
I try to create an msi package for a service.

Getting the files to system works well.
But I can’t get the registering part of the service right.

I can’t use the normal <ServiceInstall> because the dotnet core services does not start in this case.
So my next try was wrapping the service with topshelf and let topshelf handle the service registration.
In the msi I then use a CA after the files are installed like this:
<CustomAction Id="InstallLfsService" Directory="LoggingForwarderFolder" ExeCommand="[LoggingForwarderFolder] ServiceTopshelf.exe install --localsystem start" Return="ignore" Execute="deferred" Impersonate="no"/>
<CustomAction Id="DeleteLfsService" Directory="LoggingForwarderFolder" ExeCommand="[LoggingForwarderFolder] ServiceTopshelf.exe stop uninstall --localsystem" Return="ignore" Execute="deferred" Impersonate="no"/>
<InstallExecuteSequence>
    <Custom Action="DeleteLfsService" After="InstallInitialize">(NOT UPGRADINGPRODUCTCODE) AND (REMOVE~="ALL")</Custom>
    <Custom Action="InstallLfsService" Before="InstallFinalize">NOT Installed</Custom>
</InstallExecuteSequence>

This works but always shows a command window.


So next step was to use the WixQuietExec to get rid of the command window.

<SetProperty Id='InstallLfsService' Value='"[LoggingForwarderFolder] ServiceTopshelf.exe" install --localsystem start' Before='InstallLfsService' Sequence='execute'/>
<CustomAction Id="InstallLfsService" BinaryKey="WixCA" DllEntry="WixQuietExec" Return="ignore" Execute="deferred" Impersonate="no"/>

<SetProperty Id='DeleteLfsService' Value='"[LoggingForwarderFolder] ServiceTopshelf.exe" uninstall --localsystem' After='DeleteLfsService' Sequence='execute'/>
<CustomAction Id="DeleteLfsService" BinaryKey="WixCA" DllEntry="WixQuietExec" Return="ignore" Execute="deferred" Impersonate="no"/>

<InstallExecuteSequence>
    <Custom Action="DeleteLfsService" After="InstallInitialize">(NOT UPGRADINGPRODUCTCODE) AND (REMOVE~="ALL")</Custom>
    <Custom Action="InstallLfsService" Before="InstallFinalize">NOT Installed</Custom>
</InstallExecuteSequence>

When I install the msi on my test machine I always get this error in the log:

MSI (s) (C0:AC) [10:38:05:606]: Executing op: ActionStart(Name=InstallLfsService,,)
MSI (s) (C0:AC) [10:38:05:606]: Executing op: CustomActionSchedule(Action=InstallLfsService,ActionType=3137,Source=BinaryData,Target=WixQuietExec,CustomActionData="C:\ProgramData\Sirona Dental Systems\Services\LoggingForwarder\ServiceTopshelf.exe" install --localsystem start)
MSI (s) (C0:5C) [10:38:05:606]: Invoking remote custom action. DLL: C:\Windows\Installer\MSI8AD9.tmp, Entrypoint: WixQuietExec
MSI (s) (C0:1C) [10:38:05:606]: Generating random cookie.
MSI (s) (C0:1C) [10:38:05:606]: Created Custom Action Server with PID 1480 (0x5C8).
MSI (s) (C0:0C) [10:38:05:637]: Running as a service.
MSI (s) (C0:0C) [10:38:05:637]: Hello, I'm your 32bit Elevated Non-remapped custom action server.
WixQuietExec:  Error 0x80070002: Command failed to execute.
WixQuietExec:  Error 0x80070002: QuietExec Failed
WixQuietExec:  Error 0x80070002: Failed in ExecCommon method
CustomAction InstallLfsService returned actual error code 1603 but will be translated to success due to continue marking

I am afraid that I have to debug the WixQuietExec but I have no experience with this at all.
So maybe someone here finds an error in my code.

Thanks

Andreas



-----------------------------------------------------------------------------------------------------------
Sirona Dental Systems GmbH • HRB 24948 •
Vorsitzender des Aufsichtsrats: Dr. Erich Blum •
Sirona Dental Services GmbH • HRB 25817 •
Geschäftsführung: Rainer Berthan • Michael Geil •
Sitz der Gesellschaften: Bensheim • Registergericht: AG Darmstadt •
------------------------------------------------------------------------------------------------------------
Diese E-Mail ist ausschliesslich fuer den angesprochenen Adressaten
bestimmt und kann vertrauliche Informationen beinhalten.
--
This e-mail is intended only for the designated recipient(s). It may
contain confidential or proprietary information.
------------------------------------------------------------------------------------------------------------

____________________________________________________________________
WiX Toolset Users Mailing List provided by FireGiant http://www.firegiant.com/

WiX Support | WiX Experts and Resources from FireGiant<http://www.firegiant.com/>
www.firegiant.com
WiX Support | Installation, Development, Deployment | WiX Experts and Resources from FireGiant




More information about the wix-users mailing list