Page 1 of 1

Install Files fails when upgrading

Posted: Fri May 18, 2007 4:18 pm
by BrandonK
I've got a very basic install for a .NET 2.0 app (2 dlls, 1 exe) that, during an upgrade installation, won't overwrite the pre-existing files. This is using IA version 6.4 (build santacruz_sp2.031207)

My testing went something like this:
- Confirmed that all Install Files commands in the script have the Never Overwrite option unchecked
- Confirmed all Install File commands are before the Apply Install command
- Added multiple MessageBox commands to display variable values

Ran VS 2005 code build #329 (i.e. version 1.0.0.0329)
- Confirmed all 3 code files had correct date/time stamp and version number

Created IA install (web executable) for build 329
- Ran IA install for 329 on XP SP2 virtual machine
- Confirmed that all 3 files were installed and had correct version number

Ran VS 2005 code build for #330 (1.0.0.0330)
- Confirmed all 3 code files had correct date/time stamp and version number

Created IA install for 330
- Created new Revision Code in IA Project Options
- Compiled IA project into web executable
- Ran IA exe on same virtual machine
- Got message box confirming NEEDSUPGRADE = True
- Got message box confirming same TARGETDIR as 329 install
- Got message box confirming entry into [OFFLINE CONTENT] media block (only block in project)
- IA install completes successfully

However, when I go and look at the files in TARGETDIR, they all show the old version (build 329) and date/time stamp.

If I run the 330 install on a clean VM, the file versions are correct. Only during an upgrade do the Install File commands not work as expected.

This has me stumped. Any ideas?

Posted: Tue May 22, 2007 6:25 pm
by MichaelNesmith
Try logging, to see why MSI is skipping the file?[/list]

Posted: Tue May 22, 2007 6:26 pm
by MichaelNesmith
Try logging, to see why MSI is skipping the file?

Posted: Thu Jun 14, 2007 9:18 am
by BrandonK
My install script is based on the IA samples with multiple modifications. One change I made was to remove the code in the prerequisites section that uninstalls the previous version. During testing I added this code back into the IA script, and now the install behaves as expected during upgrades.

Is the "Install/Remove MSI package" command to remove the previous version a requirement for upgrades?

Posted: Sat Jun 16, 2007 10:02 pm
by MichaelNesmith
Yes. That is a hard-requirement. If you do not wish to uninstall the older versions, you should then build your latest setup as a patch instead.