Do Update .msi's get overwritten? - Advanced Installer Community

We’re moving our forums to a new platform.

You can still browse and search existing topics, but you can no longer create new topics or post replies.

For questions, technical issues, or feature requests, please don’t hesitate to contact our support team at support@advancedinstaller.com.

Thank you for your understanding!

dms
Posts: 164
Joined: Tue Aug 28, 2007 7:11 am
Location: UK

Do Update .msi's get overwritten?

In the course of the latest update to my application I forgot to check one required file as listed by the import Visual Studio project wizzard. As the file in question was a rather important dll my app when it restarted after the update process failed rather spectacularly.

Fortunately it was pretty obvious what I had done wrong, and it was easy to rectify. I then on my test machine uninstalled the broken build and re-installed the previous build. It then saw the corrected update and downloaded it. However when it ran the same fault appeared again. This time however I knew that the fault had been corrected. What I assume happened is that although the updater saw that there was an update available and it went through the motions of downloading the updated msi it did not overwrite the file in the users application data directory that was there with the same name.

If I mannually deleted the faulty msi first and then ran the updater the correct file was run and the program worked.

So my question is essentially if the updater downloads a file, but a file with that name already exists (in the default location where you have told it to download files to) will it automatically overwrite by default, or have I inadvertently discovered a bug (because I should have thought that this should be the default behaviour).

On a seperate note, when the wizzard that imports files that it knows are needed for a visual studio project it lists them in a fairly small dialog. Granted you can rezize the dialog by dragging it's borders to enlarge it, but it would be nice if it had a maximise button on the form.

Dom
Cosmin
Posts: 5797
Joined: Tue Jul 10, 2007 6:39 pm
Contact: Website

Re: Do Update .msi's get overwritten?

Hi,
So my question is essentially if the updater downloads a file, but a file with that name already exists (in the default location where you have told it to download files to) will it automatically overwrite by default, or have I inadvertently discovered a bug (because I should have thought that this should be the default behaviour).
When the Updater finds an available update, it downloads it into a folder which is named like the AIU section of the update. Also, before the Updater starts the download of the update, it checks the folder which should be created by the download.

Therefore, if the folder exists and the update is in it, the update on the server will not be downloaded (it would be redundant to download the same file since it's already downloaded). In special cases (like the one you explained), you can avoid this behavior by renaming the AIU section of the update (the section which contains the update information in the Updates Configuration File).
On a seperate note, when the wizzard that imports files that it knows are needed for a visual studio project it lists them in a fairly small dialog. Granted you can rezize the dialog by dragging it's borders to enlarge it, but it would be nice if it had a maximise button on the form.
We will consider this improvement for a future version of Advanced Installer. Thank you for your suggestion.

Regards,
Cosmin
Cosmin Pirvu - Advanced Installer Team
Follow us: Twitter - Facebook - YouTube
dms
Posts: 164
Joined: Tue Aug 28, 2007 7:11 am
Location: UK

Re: Do Update .msi's get overwritten?

Cosmin

Thanks for your reply. Hopefully this scenario is unlikely to happen again, but if it were to happen are you talking about renaming the aiu section in the updates.ini file (such as the one below), in which case wouldn't the update fail anyway because it couldn't see an aiu section?

;aiu;

[Update]
Name=My App Version 1.43
URL=http://www.mydownloadlocation Size=7165952
ReleaseDate=15/05/2008
MD5=32bb7ee5ecd1779d1abacf0881242a7e
RegistryKey=HKLM\SOFTWARE\****Description=Latest Version of my app
Enhancement=**********
AutoCloseApplication=[APPDIR]myapp.exe


Dom
Cosmin
Posts: 5797
Joined: Tue Jul 10, 2007 6:39 pm
Contact: Website

Re: Do Update .msi's get overwritten?

Hi,

Code: Select all

are you talking about renaming the aiu section in the updates.ini file (such as the one below)
Please note that in the example you posted there is only one section: [Update]. You can modify the name of this section because the Updater will read the Updates Configuration File and perform actions based on what it finds.
in which case wouldn't the update fail anyway because it couldn't see an aiu section?
If you are referring to the ";aiu;" entry, please note that this is not a section. This entry is a special marker used by the Updater to read an Updates Configuration File.

Regards,
Cosmin
Cosmin Pirvu - Advanced Installer Team
Follow us: Twitter - Facebook - YouTube

Return to “Common Problems”