PsExec - deploy software to more than 100 Windows computers

Luca Matteis / Saturday, August 14, 2010

I was hired by Bioversity International to develop a software deploying system. Their office has about 120 Windows computers. Windows isn't as easy as linux when it comes to software distribution... most software isn't distributed through a standard way such as repositories. Windows software mostly comes in the form of a .exe package file; an installer that will take care of installing or upgrading.

You might ask yourself that there must be some Windows community willing to create some repository to contain all these .exe files and make distribution a bit easier for people... wrong. Nothing of this sort exists other than sites like Filehippo.com that are just software download sites.



So how am I suppose to automate installation on more than 120 computers without a repository? Easy, I'll create one myself. It looks like my boss doesn't need more than about 20 programs to be deployed... Firefox, Skype and some others.

To deploy the .exe files to the clients I'm using PsExec which seems great for the job. It was a bit tricky to setup at first with all the credentials, but now it works great. Fortunately also, most .exe installers come with a silent install switch, which is mandatory for automated installation.

There isn't really a standard way of silently installing a .exe, it's up to the program itself to deliver correct silent flags. If the .exe doesn't have silent flags you might as well just consider not using it, or try and find a .msi version and then use msiexec with it.

Silent installation is crucial for the correct automation of the installation. Without it the .exe would just show a popup, expecting user interaction, and halt execution of the installation.

Fortunately most .exe installation come with silent switches that work great.. appdeploy.com and wpkg.org have huge databases of the flags you need to use for many different apps. However there's still a couple that don't behave as they should.

For example VLC will halt installation if you already have VLC installed, popping a window saying to delete the current version before installing the new one. This is a bit annoying for my automation routine because PsExec will try and run the VLC-installer.exe and it will just hang there on the popup window, waiting for the user to click continue, which of course will never happen.

Apart from these annoying cases, this is definitely a very good choice for deploying software to lots of Windows clients. There are many 3rd party softwares that promise to do the job, but frankly it seems a tedious job, given the instability of how Windows software is delivered to the masses; it's hard to keep up with different software installations, and you constantly need to test the .exe files to see that they work. This is why I decided to go with PsExec and silent switches.