JauntePE - Do It Yourself, Robust Application Virtualization for Portablizing Apps Print E-mail
Written by Darwin Sanoy   
Monday, April 25, 2011 10:19am

Portable applications can be run without an installation.  Portabilization is the act of making an application run portably even though it was not designed to do so.  Although portable apps are generally used on a flash drive to allow someone to carry their productivity applications anywhere, they can also be very handy for running various IT utility on any server or VM without installation.  This solution is a true hidden gem!

Application Virtualization versus Application Portablization

Before continuing, let's understand some of the differences between Portabilization and commercial Application Virtualization.

One key difference between full application virtualization and virtualizing for portablization is that there is no virtual "storage container" for the application nor it's state data or documents.  The application is run from a folder and the state data and user documents are stored with the portable application.  So the actual files that have been redirected and possibly .REG files are visible in the file system in the portable application location.  Commericial Application Virtualization solutions generally use proprietary, binary file based storage containers for the application and for any application state data.  User documents are normally put on the machine in their normal locations.

Another key difference is that the main value driver behind portabilizing applications is to enable zero-install and zero-footprint usage of applications.  Portablizing solutions do not need to enable isolation from system components or comprehensive user state preservation.

A third difference is that it is usually considered desirable to virtualize/rediretc user documents - this is because portablization focuses on "taking all my stuff with me to be hosted on any PC"

"Swap In" Virtualization for Portablizing

The most popular and robust framework for portabilizing applications is the portableapps.com framework.  It is a blend of open source Delphi code and compiled NSIS installer code.  

The approach used by portableapps is to "swap in" any files and registry keys used by the application and then swap them out to the portable application location to preserve the application state (changed registry or file based settings).

If the same applicationis already installed locally, the local instance settings are automatically backed up and restored during this process.

File locations are redirected to the portable location via environment variables.

It would be fair to call this virtualization via swapping.

This approach not a true, process level redirection like commercial application virtualization solutions use - which actually has some advantages.  For instance, the changes are global to all instances of a portable application - so multiple instances all see the SAME "virtualized" data.  Secondarily, it works for applications that are composed of multiple EXEs since each one does not need to be virtualized independently.  This gets around problems like when procmon.exe extracts "procmon64.exe" from inside itself and runs that on 64-bit platforms.  It can also work equally well for 64-bit applications

PortableApps.com Framework Capabilities Beyond "Virtualization"

Before going any farther it should be mentioned that PortableApps.com framework is doing MUCH MORE than "virtualizing" the application - it also provides:

  • A themable menu framework that auto-discovers new applications.
  • A portable application launcher framework and compiler.
  • A auto-updates framework.
  • Global redirection for all applications in the same menu structure (for instance a shared, portable Documents folder)
  • Many pre-portablized personal productivity applications.

Challenges for Swap In

However, there are challenges to the virtualization via swapping approach that IT administrators who understand Application Virtualization would find challenging:

  • the need to rewrite registry and file references when the drive letter of the flash drive changes (which adds time to the next point)
  • the amount of time required to develop a portablized application - discovery of files and registry keys, specification of deletion of empty reg keys and folders, etc, etc.
  • the amount of time it takes to setup the environment
  • the requirement that proper shutdown is done in order to cleanup and preserve application state data.

JauntePE - True Process Level Virtualization for Portablization

This is where JauntePE shines.  It only does the application virtualization portion of the puzzle, so if needed a menu framework needs to be found seperately and PortableApps.com menu will work just fine.  However, if you are an IT admin just interested in running apps portably from a network location, JauntePE may be sufficient by itself.

JauntePE works just like App-V Application Virtualization and Microsoft's Application Compatibility Toolkit - it injects a DLL into the target process and redirects registry and file system writes.  It is highly configurable as to which file locations and registry keys are redirected to the portable locations and which ones are allowed through to the real system.  Any child process created by the originally virtualized EXE will inherit the virtualization as well.  It also has a portablization wizard that makes your first attempts at portablizing much easier than they would otherwise be.

Enjoying your read? Subscribe to our newsletter (without loosing your place in this article).
(Please ensure that the confirmation email clears your spam filter so that you will see future mailings.)

I was able to instantly virtualize an application that stores it's settings in a binary file that is in the %APPDATA% folder structure with no additional work.  Under swapping type virtualization it took some real effort to: a) discover this application state store (binary file), b) create directives to swap it in and out.  In addition, it adds time to application startup and proper shutdown is essential.

It is important to know that JauntePE has undergone a massive revision.  The version previous to the latest beta did things using Delphi as well, but the latest version uses a true injected DLL approach.

In order to inject the DLL, JauntePE must build an EXE based launcher for your application.  One point of excellent design is that the injected JauntePE DLL uses a .INI file to customize the virtual environment, so no "recompiles" of your launcher (or anyting else) are needed to revise what is virtualized and what is not.

You can find JauntePE 0.6 here.
(please note if you google JauntePE and find the 0.5 version website - it is a very different technology)