简体   繁体   中英

Copying application files during installation [WIX]

I have a desktop app which has a HTML interface with about 7500 files (about 40MB) Now I need to copy application files into installation dir.

Which approach would be better?

  1. using burn command to register all files and copy them into installation dir
  2. using custom action to unzip all files into target dir
  3. any other ideas?

I have encountered problem with the 1. approach - installation/uninstallation on old machines (win xp) is taking a lot of time (over 15 minutes). Why does it happen? because of burn has to register all files?

Custom actions and unzipping are very undesirable mechanism for many reasons : reliability, cleanup / uninstall, complexity, access rights, etc... Please don't go down that route.

I am not particularly fond of MSI for IIS deployment (due to all the non-versioned files), but there are few other options that are any better. Your application seems to be a desktop application, so you don't install to IIS?


MSI / Windows Installer : MSI provides a few major corporate benefits (short version) ( full length ), but has a number of quirks, one of them being slow installation speed - especially on older systems and slow disks. There are some tricks to use to speed up MSI installations . Personally I usually set MSIFASTINSTALL to 3 or 7 (see link). There are further tweaks in the link - not sure if they would mean much in your case.

Requirements : How large is your distribution? Global , internal , small scale , large scale , etc... You don't have to use MSI, especially if this is for small scale distribution and the users will install interactively. MSI is supreme for reliable remote management and silent, non-interactive deployment. There are many deployment tools: How to create windows installer (MSI and legacy tools).

Deployment Tools : You can use one of the legacy installer technology for simple requirements - if you find that to be better. Even APP-V for application virtualization - if that is available in your environment. It all depends. One user I answered went for WinRAR of all things: Executable files to MSI installer . Not something I would recommend.

WiX is a good choice though - seeing as you seem to be using it already. I would use heat.exe to create your package. Using a single file per component - which I like to use - would make the install slower. If you standardize on major upgrades you could use one component per directory to avoid slowing down the install.

No matter what you do MSI / Windows Installer will have more overhead than other deployment technologies - because it is more advanced.

One last question : are you installing on top of older files on those older boxes? MSI's rollback feature means any existing files on disk will be backed up in a rollback folder during installation. This could make installation very slow. Maybe try to install to a blank folder (you probably do this already). Though not great to do, you could try to set the DISABLEROLLBACK property to 1 for a test install if you do install on top of existing files.

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM