QPack installation workflow June 15, 2014

QPack installation workflow

Setup initialization

During setup initialization several conditions are evaluated to make sure that target is supported by current install. Following checks are performed:

 Make sure that operating system version is or later (we support IIS7 to up);  Make sure that operating system edition is Professional or up - for Windows Vista, or Home Premium or up - for and later;  Make sure that there is no reboot scheduled. Some prerequisites may fail if a restart is pending;

On this step we also make decision about what edition of Microsoft SQL Server we can deploy, if needed; the decision is made based on operating system version

During wizard initialization setup will perform several checks to make decisions about installation workflow. Setup looks for the status of a previous installation, prerequisites installation status and setup variables, used during install, are initialized with its default values, as follows:

 Setup is looking for existence of a previous installation configuration file (%TEMP%\QPack70SetupConfig.cfg) which is created on ready to install step of installation wizard; if file is found then setup variables are populated with values from that file else with the default ones. This configuration file may be passed to installer via command line like: setup.exe /SetupConfig=”path_to_config_file”  If setup detects that current install is a resumed installation of a previous install (during prerequisites installations some of them may ask for a restart), let the user know about that, so user may make the decision to Resume, Start from the beginning or Cancel the install. If resume is chosen all pages till Ready to install will be skipped;  If setup detects that a previous installation was completed and currently installed will let the user know about that, so user may make the decision to run QPack upgrade, start from the beginning or cancel the install.

Installer user interface

Page 1

QPack installation workflow June 15, 2014

On wizard initialization the default Inno Setup look and feel is overridden with a custom design. The wizard dialog is made a little wider, with the help of ISSkin the wizard gets a new look and several custom wizard pages are created to collect needed data from the user. Following custom wizard pages are created:

 Customer information to get details about the user like Name, Company or email contact. In order to move forward with wizard, setup will make sure that all fields are filled;

Page 2

QPack installation workflow June 15, 2014

Page 3

QPack installation workflow June 15, 2014

 SQL Server Connection page is used to get all parameters needed to perform an SQL server connection needed by setup. A combo box is filled with all SQL server instances found installed on the target machine, so the user may choose one of them to be used for install; if none found, user may choose to let installer to install an Express edition of SQL server. In order to continue installer makes sure that following conditions are meet:  all needed fields are filled  installer can connect to the specified SQL Server instance  user specified for connection have enough rights to deploy and configure product database  SQL Server is running in mixed authentication mode; if mixed authentication mode is not available, user is warned about that and a fix is scheduled if user agrees.  Looks for existing product database. If database exists user may choose to drop existing, use existing or cancel the setup.

 Support Information page settings collects details regarding requesting support information from Orcanos Ltd. by specifying some SMTP server details needed to send emails. On Server editions, user may choose to let installer to install and configure Microsoft SMTP Services.

Page 4

QPack installation workflow June 15, 2014

Page 5

QPack installation workflow June 15, 2014

Page 6

QPack installation workflow June 15, 2014

 Installation Error Log page is used to display errors that may be raised during post installation steps. If no error was raised then dis page will be skipped from displaying.

Prerequisites deployment

During initialization, setup is looking for the presence of required applications / windows features required by product. If any is missing, setup will compile a product list with details needed for product installation (product name, download url if apply, command line parameters and so on).

Prerequisites are scheduled for download and install at preparing to install stage of Inno setup, so, if any product fails to install or asking for a reboot, the installer can makes decisions before installing any product file.

In order to perform prerequisite download and installations, following steps are performed:

Page 7

QPack installation workflow June 15, 2014

 If no download url was specified, it means that we deal with a windows command, so we use it as it is;  If download url was specified, it means that a product package must be downloaded; in order to download it, setup will check if that file is not already downloaded, as follow: first it is looking for Packages folder that may be placed just next to the setup.exe file (The installer may be delivered along with all needed product packages placed into the Packages folder, to allow an offline install); if needed package exists in this folder then this package will be skipped for download;  If no Packages folder exists, setup will also looks for its package cache location, for packages that may be already downloaded by a previous installation. The cache location is: C:\ProgramData\Package Cache\ {E715E818-5F09-471D-8221-913544AAD27C}\Packages (the {E715E818-5F09-471D-8221-913544AAD27C} is our installation Id). If package file already exists, then the package will be skipped from download.  For any missed package file, installer will download it and place it on Packages folder (the one next to setup.exe if exists, else to the one from C:\ProgramData\Package Cache\ {E715E818- 5F09-471D-8221-913544AAD27C}\)

So, the installer will download all needed packages, then perform the installation in specified order. If a package failed to install, the setup will be cancelled. If any package requires a restart, user is notified about that and asked for a reboot; in this case, the installer will register a RunOnce instance for setup package with /RestartResume command line flag, so the installer can resume with installation.

Install and post install tasks

If all prerequisites are in place, setup will install all product files, and perform post installation steps:

 First, will remove existing QPack web applications and virtual directories on both Web and Ftp sites, to avoid problems when a previous install failed and user is running setup for the second time.  Install the database by creating the ’Orca123’ login, restoring the QPack database from backup, assigning database user with login and give the right role member. If database already exits, the existing will be used or dropped based on uses choose.  Register asp.net on iis  Update the QPack configuration file  Setup Mime  Install Default Ftp Site (if needed) and QPackFtp virtual directory and setting the right permissions  Install Default Web Site (if needed) and QPack applications/app pools/ virtual directories and setting the right permissions  Configure the SMTP Services for windows server editions

Page 8

QPack installation workflow June 15, 2014

 Adding firewall exceptions  Install QPackClient

At the end of installation, the installer will launch QPackUpgrade package.

Installer extensions used

In order to achieve all needed functionalities installer uses few extension libraries, placed under Resources folder of installer project tree, as follows:

 Inno Download Plugin (isxdl.dll) – is a third-party library for Inno setup, developed by Bjørnar Henden, which allows you to download files as part of installation (supports FTP, HTTP and HTTPS);  ISSkin (ISSkin.dll) - is an add-on to Jordan Russell's Inno Setup compiler that provides enhanced skinning support for the Inno Setup installation. ISSkin is the free version of Codejock’s Skin Framework  Extension for QPack installer (isxhelper.dll) – is a custom made library, developed under 2007, used to achieve some SQL tasks like execute SQL scripts or enabling mixed authentication mode on SQL server; sources are available under ISXHelper folder;

Setup logging

During install setup creates an installation log that is placed under the temp folder of logged user: as %TEMP%\ Setup Log #.

When install completes the installation log is copied to the product installation folder C:\Program Files (x86)\QPack\ MainInstall.log

Page 9