Once you have a problem with the Windows Installer or an MSI package ,you will be always thiking to “enable logging”.
In this post, I’ll discuss with you some of the basic tips about Logging ,Hope this will help you to be in a better position to troubleshoot package issues.
1.What is Logging
This is the process of putting different levels of activity of Windows Installer into text based log files.
2.What are all the general content in a log file
- Most errors that occurred during the install including all Windows Installer errors that generate a user dialog.
- Which custom actions were run.
- Whether a reboot was requested and completed.
- Values of Installer Properties, including details of any changes.
- The source location.
- Whether the user cancelled the install.
- Where an install stopped.
- Whether an install rolled back.
- Client and Server information
3.What is Verbose logging
When all options are turned on logging is generally called “verbose logging”
Eg : msiexec /I package.msi /l*v c:\test\log.log /qb
4.What is super verbose logging
When Loging is invoked with “x”, as in “-l*vx” on the command line it is termed as super verbose logging.
5.How ‘event Log’ will be helpful even though we create a Verbose log fie?
It is always worth a quick look to see if anything is logged particularly if trying to diagnose why Windows Installer “kicked in”, for example by a user logging on or clicking a shortcut.
And badly written custom actions may write error details directly to the event log and not to the Windows Installer log.
5.What is the meaning of log return value 0,1,2,3?
|A function could not be (or was not) executed|
|An action completed successfully.|
|A user canceled installation.|
|A fatal error.|
7. What is the log return value 8
|Another installation is already in progress. Only one installation at a time can run actions in the InstallExecuteSequence, AdminExecuteSequence, or AdvtExecuteSequence.|
8. What is the command to translate Windows Error codes
Net helpmsg <error number>
Eg:net helpmsg 1
9. If you have an MSI wrapped up in an EXE (installsiled exe), then what is the method of turning on logging?
Setup.exe /v”/L*v c:\tmp\verbose.log”
10.How to turn on Windows installer logging via policies.
“Logging” = “voicewarmup”
“Debug” = dword:00000004
11. Wat is the return code of the installation 3010 means?
A restart is required to complete the install
12.What is wilogutl.exe
Wilogutl.exe assists the analysis of log files from a Windows Installer installation, and it displays suggested solutions to errors that are found in a log file.
13.How will you quickly identify the errors in a log
Simply searching for the phrase “Return Value 3” can be a quick way of pinpointing the errors in a log
14.What is a return value ?
This is an indicator of the success or otherwise of the action. Possible values are:
|0||Action was invoked, but did not run (not necessarily a bad thing, maybe there was nothing for it to do)|
|1||Action was a success|
|2||Action was cancelled by user|
|3||An unrecoverable error has occurred|
|4||The installation was suspended awaiting a reboot|
15.What are all the ways to enable logging?
If you can install the MSI package from the command-line, even if only for troubleshooting, then this is a very easy way to generate a log. Simply use the “/l” switch during install:
msiexec /i SomeApp.msi /l*vx %temp%\SomeApp.log
Using the “*vx” modifier gives the most detail possible
Registry or Group Policy
If you cannot run the package from the command-line, then enable logging directly in the registry or via Group Policy
MsiLogging and MsiLogFileLocation properties
With MSI 4.0 these two properties can be set in the Property table of a package to enable logging and specify the log location
If you are developing an Installer-aware application, you can use the API to MsiEnableLog enable logging for the lifetime of the calling process.
Hope you enjoyed this reading!