I create silent software installation packages for customers. This is pretty straight forward if the installation is a simple file dump, or add service and start; but a lot more difficult if customer instructions (and payload media), are gui based - 'run setup.exe, click next, enter text...'etc...

So I have been investigating the use of the autoit utility, which enables the installation to proceed as a gui (i.e. exactly as instructed by customer installation instructions), but with all actions performed automatically. However, as far as I can tell, in order to run the gui autoit script, someone with appropriate permissions needs to be logged on to the server.

I need a method to enable the gui script above to run, without any user actually being logged onto the server - similar to the script running as a service. Developing the installation package, delivering the media and installation scripts, then making the call isn't an issue. Getting the script to run through to completion without a user logging onto the server and starting the whole thing off, is.

To more closely look at the issue, I created a simple script to open notepad, enter some text, then save and close...

I have tried: running the script as a service which can 'interact with desktop' - notepad is displayed, but no keystrokes can be sent and the script hangs.

I am investigating to see if it is possible to raise a vncserver session, then export display (similar to unix varients), when I came across this excellent site...

Does anyone know of a method where interactive gui scripts may be raised on a server (e.g. win 2003), where no users are currently logged on at the time?


  • What OS? (Tag with the one you are interested in, rather than potential answerers having to guess.) – Richard Jun 17 '09 at 20:59
  • OS is win 2003 server. – user9897 Jun 17 '09 at 21:08

Just an idea, but maybe a batch script in a scheduled task to automagically login as a maintenance user to run the install?

  • Write the login credentials to the Registry (see KB315231)
  • Add another script to Startup to clear out the credentials and launch the AutoIt enhanced install
  • Reboot
  • Profit!

It's crazy enough that it just might work.

  • Thanks for the idea - This could potentially be the answer me thinks... I wonder if there's a way of kicking off an automatic login? - i.e. not requiring a registry update and reboot? – user9897 Jun 20 '09 at 9:23
  • You've got to get the login credentials set somehow, and I'm afraid the registry is the only way about that. However, you may find some additional help from some fellows over in Zurich. Real Men Don't Click (isg.ee.ethz.ch/tools/realmen) has the well documented methods of one IT department forced to move from UNIX to Windows. Take a look at Magic Boot Scripts (isg.ee.ethz.ch/tools/realmen/det/boot/bootmgr.en.html) and Magic Login Scripts (isg.ee.ethz.ch/tools/realmen/det/boot/loginmgr.en.html). You may find you can run your installer just prior to the user logging in. – Shazburg Jun 20 '09 at 10:04

I assume since you mentioned a "setup.exe" you mean on Windows, so...

Simple: grab a copy of WinInstall LE (http://www.softpile.com/Utilities/Miscellaneous/Review_16745_index.html and elsewhere), run through your setup in GUI mode on a test box, do any post-config you need, and it will produce an MSI file which you can then script using msiexec (with the /quiet option).

But before you even do that, check if you have an MSI file already available; it might be packaged in an exe so look in your temp folder or extract it using 7zip.

  • Thanks for the tip - but I've been here already. For me, msi creators are great, but if you want customisation - to enable deployment across multiple environments - you need to be an expert in the app being packaged - so you know which files to edit etc. Sadly, this is not the case. So I can only follow customer instructions (i.e. developers who have performed the installation - often using gui screens). Being able to follow instructions to the letter enables packages to be created much quicker... it's just the requirement to login issue that's causing me grief! – user9897 Jun 17 '09 at 21:24
  • How about creating a service that calls msiexec and then removes itself? – Maximus Minimus Jun 17 '09 at 22:25

Most software has silent install options. run the setup from the command line

setup.exe /?

to see if there are silent switches.

What is the software? Perhaps I can find it for you.

  • That's the issue - the software changes all the time. It may be a 'setup.exe' one day and an 'install.exe' the next (poor example). This is why I'm trying to resolve using a single method (i.e. autoit). I just can't get over the issue where a user needs to be logged on to display the automated gui. BTW: If media is given to me in msi format, of course I use it as is. – user9897 Jun 17 '09 at 21:07
  • The reason I ask is because I'm pushing SMS/SCCM packages and most of them have silent options. – MathewC Jun 18 '09 at 12:51

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy