\
Troubleshooting
Bugs, Features and Issues (NON-MAKEMSI)
Pending Restart Bugs
BUG: Pending Restart Bugs |
Windows Installer will return a return code of
3010
if files are in use and at least one file is scheduled for deletion or
overwrite.
The bug is it is still scheduled even when the need is gone and it will
cause problems when executed.
It is preferable to
have users close applications
whenever possible or for you
to stop services
before performing the install activity.
If this is not possible then having enough
advertised entry points is a workaround
as it ensures the application gets repaired if required.
The proper solution (by Microsoft) is that Windows Installer needs
its own locked file scheduling which it needs to manage itself
(and not just at restart).
It needs to remove pending operations that are no longer required or at
least not allow future installs that will generate this issue.
One scenario which will result in missing files:
- Install a product.
- Start the application or otherwise ensure one or more of the
installed files is "in use" (locked).
- Uninstall the product.
Do this in "quiet mode" (/qb perhaps), this ensures that the
deletion is scheduled for next boot up.
Confirm the return code is "3010" (perhaps with a verbose log).
- Stop the application or otherwise ensure none of the files are in use.
- Install this application again
(or a new version as is more likely "in the wild').
- Start the application, it should be OK.
- Reboot the computer, the scheduled deletion kicks in and the
installed file(s) now gets deleted.
- Check that the previously locked files are gone confirming the bug.
For your testing, do not attempt to let Windows Installer "cover up"
this fault by invoking advertised entry points
and causing a repair.