Top 10 most common ICE Validation Errors and How to Fix them

Written by Horatiu Vladasel · March 24th, 2022 · 6min read

We extremely recommend you to validate an MSI before attempting to install it for the first time.

The action of validating an MSI package helps in the detection of authoring errors in the MSI database.

This is a critical step since an MSI package that fails to pass validation may cause damage to the user's system.

According to MSDN, MSI package validation includes the following processes:

  • Internal validation
  • String-Pool Validation
  • Internal Consistency Evaluators

In this article, we're going to be diving deeper into Internal Consistency Evaluators or ICEs.

ICEs scan the MSI database for entries that are valid separately – meaning they passed the Internal Validation and String-Pool Validation, but may cause issues in the context of the whole database.

NoteWith Microsoft Windows Installer, the installation data for the application is stored in an .MSI file that acts as a relational database.

What is ICE Package Validation?

ICEs are nothing else but custom actions written in VBScript, Jscript, or as a DLL or EXE which when executed return four types of messages:

  1. Errors
  2. Warnings
  3. Failures
  4. Information Messages.

ICEs are stored in .cub files. A .cub file is a standard .msi database that contains only ICEs and their required tables:

  • Binary
  • CustomAction
  • _ICESequence
  • _Validation
  • Or any other special processing table required. Keep in mind that the name of these tables must be prefixed with “_”.

How does ICE Validation work?

When you validate an MSI package with ICEs, the .cub file is merged to the MSI database. Then, the ICEs get executed and the output is reported.

ICE validation is a straightforward process and it consists of two steps:

  1. Selecting the .cub file that will be used;
  2. Validation.

NoteThis is how most ICE validation programs work:

How to validate your MSI package using Orca

One of the most known tools used for MSI validation is Orca. To validate an MSI in Orca:

1. Go to the “Tools” menu and select “Validate”.

2. In the “Validation Output” windows, select the “Evaluation File” (.cub file) you want to use and the “ICEs to Run”.

ICE Validation with Orca

How to validate your MSI package with Advanced Installer

You can also use Advanced Installer to validate your MSI package:

1. Select the “Package Validation” ribbon from the “Settings” menu.

2. Same as with Orca, you can select the .cub file you want to use (the evaluation file).

Did you know Advanced Installer validates your package using best practice criteria and compatibility checks when you are creating your MSI package (including App-V and MSIX packages)?

Check how it works through our 30-day full-featured trial

ICE Validation with Advanced Installer

Useful .cub files for MSI Validation

The Microsoft Windows Software Development Kit includes several .cub files that can be used for MSI validation:

  • Darice.cub – can be used for Full MSI Validation (all standard ICEs)
  • Logo.cub – can be used for validation against Windows Logo Program
  • XPlogo.cub – can be used for validation against Windows XP Logo Program
  • Vstalogo.cub – can be used for validation against Windows Vista Logo Program
  • Mergemod.cub – can be used for validation of Merge Modules.

NoteWhen you need to provide specific validation, you can simply create custom .cub files using ICE rules.

When validation is completed, you must review the validation results and resolve them where needed.

What are the Top 10 most common ICE Validation errors?

ICE02

Description

The ICE02 rule checks if certain references between the Component, File, and Registry tables are reciprocal. It returns an error message if a component references as "keypath" a file or a registry key that is controlled by another component.

Fix

To fix this issue, we should either change the keypath or move the file/registry key to the correct component.

ICE03

Description

The ICE03 validates the data types and foreign keys based on the _Validation table and the database tables in the .msi file.

Fix

This ICE rule can return multiple error messages. We must review each error message individually, and we should follow the error's description to fix the error.

ICE04

Description

The ICE04 validates that the sequence number of every file in the File table is less than or equal to the largest sequence number in the LastSequence column of the Media table.

Fix

This ICE error usually occurs when files are added manually in the File table without updating the LastSequence field in the Media table.

The sequence field for files in the File table, or LastSequence field in the Media table should always be adjusted to correlate with each other.

ICE08

Description

The ICE08 validates that the Component table has no duplicate GUIDs. .

Fix

This ICE error usually occurs when you copy-paste the components manuall. You need to create unique GUIDs to eliminate duplicates.

ICE09

Description

The ICE09 validates that the permanent bit is set for every component marked for installation into the SystemFolder.

Fix

This ICE error usually occurs when you add components manually using copy and paste. You need to generate unique GUIDs to eliminate duplicates.

ICE21

Description

The ICE21 validates that every component in the Component table belongs to a feature.

Fix

This ICE error usually occurs when components are added manually to the Component table without being assigned to any feature within the MSI package.

To fix this, add an entry to the FeatureComponents table.

ICE57

Description

The ICE57 validates that individual components do not mix per-machine and per-user data.

Fix

You must reorganize MSI resources so that each component contains only either per-machine or per-user data. If needed, you can create new components.

ICE67

Description

The ICE67 checks that the target of a non-advertised shortcut belongs to the same component as the shortcut itself.

Fix

To fix this, reorganize MSI resources so that both the target file of the shortcut and the shortcut itself belong to the same component. If they don’t, then you must move the shortcut to the component which contains the target file.

ICE71

Description

The ICE71 verifies that the Media table contains an entry with DiskId equal to 1.

Fix

This ICE error usually occurs when you add Media table entries manually. One entry in the Media table must have the DiskId set to 1.

ICE99

Description

The ICE99 verifies that no property name entered in the Directory table duplicates a name reserved for the public or private use of the Windows Installer.

Fix

You must not use reserved property names as a value in the Directory column of the Directory table.

To fix this error, replace the already used names with something else.

Conclusion

This is an overview of what ICE validation is, how it works and how you can address the most common errors.

We hope you find this article useful and let us know if you've come across other ICE errors, other than the above mentioned.

Subscribe to Our Newsletter

Sign up for free and be the first to receive the latest news, videos, exclusive How-Tos, and guides from Advanced Installer.

Comments: