Hello,
Sorry I didn't explain that better. Basically in one of our other
installers for a different product I do have the RemoveExistingProducts
scheduled early however if I schedule it that early in this installer then the
whole install fails because of the custom actions I posted below. For some
reason it tries to install the performance counters and since it just removed
the files the dll it is looking for isn't found and the whole install
rollsback. The only way I got past this was to put the same Guid on the dll and
set the RemoveExistingProducts to be before InstallFinalize so that component
reference counting will come into play and not remove that dll, but that leaves
me with a bunch of files that don't have the same guids being removed by that
action. If this happened in the current installer I would just change the
scheduling of the custom actions, but it happens when the previous product gets
removed during a major upgrade.
Date: Tue, 4 Jun 2013 17:19:10 +0000
From: "Hoover, Jacob"
<[email protected]<mailto:[email protected]>>
Subject: Re: [WiX-users] Running a repair after install automatically
To: General discussion for Windows Installer XML toolset.
<[email protected]<mailto:[email protected]>>
Message-ID:
<[email protected]<mailto:[email protected]>>
Content-Type: text/plain; charset="us-ascii"
I'm confused about: if I schedule the remove existing product early like our
other installer then during that action the install fails as the dll is gone
when the custom action to InstallUtil.dll gets called. If you schedule it
afterInstallValidate or afterInstallInitialize, the old product is removed
before the new one is installed. If you did it afterInstallExecute, I could
see the behavior you are describing.
>From the help file:
afterInstallValidate - (Default) Schedules RemoveExistingProducts after the
InstallValidate standard action. This scheduling removes the installed product
entirely before installing the upgrade product. It's slowest but gives the most
flexibility in changing components and features in the upgrade product. Note
that if the installation of the upgrade product fails, the machine will have
neither version installed.
afterInstallInitialize - Schedules RemoveExistingProducts after the
InstallInitialize standard action. This is similar to the afterInstallValidate
scheduling, but if the installation of the upgrade product fails, Windows
Installer also rolls back the removal of the installed product -- in other
words, reinstalls it.
-----Original Message-----
From: [email protected]<mailto:[email protected]>
[mailto:[email protected]]
Sent: Tuesday, June 04, 2013 11:50 AM
To: [email protected]<mailto:[email protected]>
Subject: [WiX-users] Running a repair after install automatically
Hello,
I have a problem with an older install that we have restructured to
conform to the single file per component rules. However inside of this
installer is some custom actions that call the InstallUtil.exe to install some
performance counters that we have in a dll that gets installed. The problem we
have comes when we do a major upgrade if I schedule the remove existing product
early like our other installer then during that action the install fails as the
dll is gone when the custom action to InstallUtil.dll gets called. So I left
the RemoveExisting action before InstallFinalize and put the old Guid from the
previous version back on that Dll and that gets me through the install, but a
lot of the components that had multiple files are now in single components and
get removed when the RemoveExisting action runs. So basically I am left with a
completed install and most of the files have been removed. If I manually run a
repair that fixes it, but I was wondering if there was any ot
her way I could fix this and at the very least is there any way to
automatically run the repair so our customers don't have to do it manually? I
have pasted the relevant code for the performance counter custom actions below.
<Property Id="PerformanceCounterCustomActions" Value="1" />
<!--We use netframework20 because installutil does not exist in the .net35
installrootdir-->
<!--TODO: make this handle .net40 and prefer 40-->
<PropertyRef Id="NETFRAMEWORK20INSTALLROOTDIR"/>
<PropertyRef Id="NETFRAMEWORK40FULLINSTALLROOTDIR"/>
<Property Id="INSTALLUTILDIR" Value="NETFRAMEWORK20INSTALLROOTDIR" />
<CustomAction Id="SetInstallUtilDirToNetframework20"
Property="INSTALLUTILDIR" Value="[NETFRAMEWORK20INSTALLROOTDIR]"/>
<CustomAction Id="SetInstallUtilDirToNetframework40"
Property="INSTALLUTILDIR" Value="[NETFRAMEWORK40FULLINSTALLROOTDIR]"/>
<CustomAction Id="InstallDuckCreek.Lib.dllPerfCounters_cmd"
Property="InstallDuckCreek.Lib.dllPerfCounters"
Value='"[INSTALLUTILDIR]InstallUtil.exe" /LogToConsole=false
"[#DuckCreek.Lib.dll]"'
Execute='immediate'/>
<CustomAction Id="InstallDuckCreek.Lib.dllPerfCounters"
BinaryKey="WixCA"
DllEntry="CAQuietExec"
Execute='deferred'
Return='check'
Impersonate='no'/>
<CustomAction Id='UnInstallDuckCreek.Lib.dllPerfCounters_cmd'
Property='UnInstallDuckCreek.Lib.dllPerfCounters'
Value='"[INSTALLUTILDIR]InstallUtil.exe" /LogToConsole=false
/u "[#DuckCreek.Lib.dll]"'
Execute='immediate'/>
<CustomAction Id="UnInstallDuckCreek.Lib.dllPerfCounters"
BinaryKey="WixCA"
DllEntry="CAQuietExec"
Execute='deferred'
Return='check'
Impersonate='no'/>
<CustomAction Id="RollbackInstallDuckCreek.Lib.dllPerfCounters_cmd"
Property='RollbackInstallDuckCreek.Lib.dllPerfCounters'
Value='"[INSTALLUTILDIR]InstallUtil.exe" /LogToConsole=false
/u "[#DuckCreek.Lib.dll]"'
Execute='immediate'/>
<CustomAction Id='RollbackInstallDuckCreek.Lib.dllPerfCounters'
BinaryKey="WixCA"
DllEntry="CAQuietExec"
Execute='rollback'
Return='check'
Impersonate='no'/>
<CustomAction Id='RollbackUnInstallDuckCreek.Lib.dllPerfCounters_cmd'
Property='RollbackUnInstallDuckCreek.Lib.dllPerfCounters'
Value='"[INSTALLUTILDIR]InstallUtil.exe" /LogToConsole=false
"[#DuckCreek.Lib.dll]"'
Execute='immediate'/>
<CustomAction Id='RollbackUnInstallDuckCreek.Lib.dllPerfCounters'
BinaryKey="WixCA"
DllEntry="CAQuietExec"
Execute='rollback'
Return='check'
Impersonate='no'/>
<InstallExecuteSequence>
<Custom Action="SetInstallUtilDirToNetframework20" After="AppSearch" />
<Custom Action="SetInstallUtilDirToNetframework40"
After="SetInstallUtilDirToNetframework20"><![CDATA[NETFRAMEWORK40FULLINSTALLROOTDIR]]></Custom>
<Custom Action="RollbackInstallDuckCreek.Lib.dllPerfCounters_cmd"
Before='RollbackInstallDuckCreek.Lib.dllPerfCounters' />
<Custom Action='RollbackInstallDuckCreek.Lib.dllPerfCounters'
Before='InstallDuckCreek.Lib.dllPerfCounters'><![CDATA[NOT((NOT
UPGRADINGPRODUCTCODE) AND (REMOVE="ALL")) AND NOT
REMOVEINSTALLSHIELD]]></Custom>
<Custom Action="InstallDuckCreek.Lib.dllPerfCounters_cmd"
Before='InstallDuckCreek.Lib.dllPerfCounters' />
<Custom Action="InstallDuckCreek.Lib.dllPerfCounters"
After="InstallFiles" ><![CDATA[NOT((NOT UPGRADINGPRODUCTCODE) AND
(REMOVE="ALL"))]]></Custom>
<Custom Action="RollbackUnInstallDuckCreek.Lib.dllPerfCounters_cmd"
Before='RollbackUnInstallDuckCreek.Lib.dllPerfCounters' />
<Custom Action='RollbackUnInstallDuckCreek.Lib.dllPerfCounters'
Before='UnInstallDuckCreek.Lib.dllPerfCounters'><![CDATA[(NOT
UPGRADINGPRODUCTCODE) AND (REMOVE="ALL") AND NOT REMOVEINSTALLSHIELD]]></Custom>
<Custom Action="UnInstallDuckCreek.Lib.dllPerfCounters_cmd"
Before='UnInstallDuckCreek.Lib.dllPerfCounters' />
<Custom Action="UnInstallDuckCreek.Lib.dllPerfCounters"
After="MsiUnpublishAssemblies" ><![CDATA[(NOT UPGRADINGPRODUCTCODE) AND
(REMOVE="ALL")]]></Custom>
</InstallExecuteSequence>
Tyler Reid | Operations and Infrastructure | Accenture Software | P&C Insurance
1807 Jones Street | Bolivar, MO 65613| USA
Office: +cc.xxx.xxx.xxxx | Fax: 417.777.3792
E-Mail:
[email protected]<mailto:[email protected]<mailto:[email protected]%3cmailto:[email protected]>>
|
www.accenture.com/pcsoftware<http://www.accenture.com/pcsoftware<http://www.accenture.com/pcsoftware%3chttp:/www.accenture.com/pcsoftware>>
Tyler Reid | Operations and Infrastructure | Accenture Software | P&C Insurance
1807 Jones Street | Bolivar, MO 65613| USA
Office: +cc.xxx.xxx.xxxx | Fax: 417.777.3792
E-Mail: [email protected]<mailto:[email protected]> |
www.accenture.com/pcsoftware<http://www.accenture.com/pcsoftware>
________________________________
This message is for the designated recipient only and may contain privileged,
proprietary, or otherwise confidential information. If you have received it in
error, please notify the sender immediately and delete the original. Any other
use of the e-mail by you is prohibited.
Where allowed by local law, electronic communications with Accenture and its
affiliates, including e-mail and instant messaging (including content), may be
scanned by our systems for the purposes of information security and assessment
of internal compliance with Accenture policy.
______________________________________________________________________________________
www.accenture.com
------------------------------------------------------------------------------
How ServiceNow helps IT people transform IT departments:
1. A cloud service to automate IT design, transition and operations
2. Dashboards that offer high-level views of enterprise services
3. A single system of record for all IT processes
http://p.sf.net/sfu/servicenow-d2d-j
_______________________________________________
WiX-users mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/wix-users