karlf
Posts: 30
Joined: Tue Nov 01, 2016 7:30 pm

Updater.exe issues

I am using AI version 14.7. I have been trying to make an update for my program and have been running into an interesting issue. When I run the updater to check for an update, it sees that I have an update on the server and does the download, then I see a quick flash of text that says "Checking Integrity (MD5)". After that, I see no more text in the status above the percentage bar. The percentage bar stays at full, then after 10-15 seconds the updater just quit with no message of any kind.

The new updated .exe that got downloaded in the updates folder in ProgramData then gets deleted and it's as if nothing ever happened. No update is performed and it fails silently. I have read in other forum replies that the updater doesn't have a logging mechanism built in, is this true? There are command line options for it that I can't seem to get working listed here: https://www.advancedinstaller.com/user- ... dater.html

Question: Is there a way to get some kind of log info from updater.exe during the install process on why it is failing?

I know there is a way to view MSI logs, but I'm not sure how to do that when the updater.exe is calling the new updated installer for my program (which is an exe) by iteself.

There is also another piece of info that may help diagnose the issue. While doing some testing to try to find the cause of the issue, I watched the updates downloads folder in ProgramData. Once the updater had downloaded the new installer (but before it quit out and deleted the updated downloaded installer) I tried to run the installer directly from it's location in program data. This brought up the installation menu which I then quit. This also seemed to have prevented updater.exe from deleting it since it was open at the time updater.exe quit.

The next time I ran the updater to check for an update, it didn't download the file since it was already in the local ProgramData folder, but it worked without issue. It ran through the installer and performed the update flawlessly like I have seen it do in the past.

I know that the error isn't related to the MD5 hashes mismatching because I have verified that they are the same, and in the past I have seen an actual error come up from updater.exe when the hashes don't match. In this case it is failing silently.

I have tried enabling the registry setting here: https://www.advancedinstaller.com/user- ... a-log.html
However, it doesn't seem that the updater.exe is actually calling the MSI. Because no update log is created unless I manually click on the downloaded installer.

This seems to be related to the computer that the install has happened on. On 2 machines, a dev and a tester machine (that have done a lot of installs/uninstalls of different versions), the steps above were observed. However, on a "fresh" machine, I installed the previous version and was able to upgrade without issues. Are there any suggestions you have or resources that could be used to debug what is causing the error on 2 machines an not the other?

Interestingly, when I run this command:

$new = Start-Process -FilePath ".\updater.exe" -ArgumentList "/silent",/MIR -Wait -PassThru

$new.ExitCode is displayed as 0 indicating it completed successfully. These are the same arguments that my program calls when checking for updates on startup.

Thanks for the help
Daniel
Posts: 8276
Joined: Mon Apr 02, 2012 1:11 pm
Contact: Website

Re: Updater.exe issues

Hello,

We apologize for the delayed reply.
Question: Is there a way to get some kind of log info from updater.exe during the install process on why it is failing?
To do so, before running your Updater to check for updates, just launch the Updater with a command line like this:

Code: Select all

Updater.exe /set loglevel Error|Debug
After this command line call, all the Updater subsequent calls/run operations will create a log file named "updater.log" and created in the folder where the updates are downloaded next to.
I know there is a way to view MSI logs, but I'm not sure how to do that when the updater.exe is calling the new updated installer for my program (which is an exe) by iteself.
For this you can:
1. either configure the updates configuration project to run your downloaded updates EXE setup with a log command line. For instance you can call an EXE setup with a command line like this to create an MSI installation log:

Code: Select all

setup.exe /L*V <pathToLog>log.txt
2. or you can configure the setup project of your updated product version to always create an MSI log at install time. You should just go to "Builds" page -> "Configuration" tab and set the "MSI command line" field like this:

Code: Select all

/L*V <pathToLog>log.txt
Interestingly, when I run this command:

$new = Start-Process -FilePath ".\updater.exe" -ArgumentList "/silent",/MIR -Wait -PassThru

$new.ExitCode is displayed as 0 indicating it completed successfully. These are the same arguments that my program calls when checking for updates on startup.
This is due to the design of our Updater tool. This is how it works:

1. when launched it searches for updates and downloads them, then returns an exit code of 0 (updates found)
2. before exiting the original Updater from 1 creates a copy of it in a temporary location and the Updater copy if further launched to install the updates package

The copy of the Updater is used because if the entire updates process would have been handled from the original Updater then during updates installation it would have triggered a file in use error; the original Updater is part of the old product setup thus it will be removed during the old product version uninstall as part of the upgrade process.

However, just use the Updater log command and send us by email to support at advancedinstaller dot com the created Updater log to investigate. The log file will include the actions of the second instance of the updater.

All the best,
Daniel
Daniel Radu - Advanced Installer Team
Follow us: Twitter - Facebook - YouTube
karlf
Posts: 30
Joined: Tue Nov 01, 2016 7:30 pm

Re: Updater.exe issues

Daniel,

When I run the command:

Code: Select all

Updater.exe /set loglevel "Error|Debug"
I get no command line output from the updater to indicate either success or failure. I am also unable to see any logs output in the download location. I'm looking in the downloads folder that's specified in the "Configure Options" link in the updater, which in my case is: "C:\ProgramData\DCI\DigiTrak LWD Cloud Suite\updates\Update_4.4.93". Although I have noticed that it can be downloaded to my "Downloads" folder depending on the arguments used to start the updater, but there is no log there for me either. Is there possibly another place to look for the log?

The issue doesn't seem to be related to the new installer as far as I can tell. Every time I have gotten the new downloaded installer to run (by double clicking on it before it gets removed), it has installed successfully. The issue seems to be related to getting the new downloaded installer to actually run before it gets removed.

I will send in my AI project file and updates file as well in case it is needed. Are there any other suggestions on how I can get the updater to produce a log that I can send in or where I can locate the existing one?

Thanks
Daniel
Posts: 8276
Joined: Mon Apr 02, 2012 1:11 pm
Contact: Website

Re: Updater.exe issues

Hello Karl,

Thank you for your sent files. I've tested the updates scenario using your projects configuration, but everything went fine. Could you also send us the AIP (project file) of the old product version which is installed on the computers where the related behavior occurs? Or even better, if you could send us a download link of the old setup package which is installed on those machines this will be great. Also, please give us more details about the scenario like this:

1. How it is the Updater launched? What command line is the Updater started with?
2. Under which user account (admin or standard) is the Updater launched?
3. OS version and architecture (32 or 64 bit) where the behavior occurs.
4. Is there any antivirus or firewall product installed? If so, please try to disable them temporarily, only for testing purposes, and then launch again the updater and see if there is any behavior change; the Updater operations could be somehow falsely detected by an AV.

In what regards the Updater log this should be created in the download location specified in the INI file residing next to the installed updater (into your app install folder). This path is set as the value of the "DownloadsFolder" ini key. From what I saw into your setup project this path should be "C:\ProgramData\DCI\DigiTrak LWD Cloud Suite\updates\". However, if the old setup package which install the launched Updater was built with an AI version lower than 14.2 then no log will be created. This is because the lower version of AI did not have support to create Updater logs.

All the best,
Daniel
Daniel Radu - Advanced Installer Team
Follow us: Twitter - Facebook - YouTube

Return to “Common Problems”