|
How to Automatically Start STAF as a Windows Service with AlwaysUp |
Launch STAF whenever your computer boots, before you log in. Make sure that your Windows testing framework is always available, 24/7/365!
The Software Testing Automation Framework (STAF) is an open source package supporting automated testing across multiple platforms.
STAF can be configured to start when you log in, but that feature won't be much good if you are not there after a reboot. Installing STAF as a Windows Service will address that shortcoming!
To setup STAF as a Windows Service:
-
Download and install STAF for Windows, if necessary.
-
Download and install AlwaysUp, if necessary.
-
Start AlwaysUp.
-
Select Application > Add to open the Add Application window:
-
On the General tab:
-
In the Application field, enter the full path to the STAFProc executable, STAFProc.exe.
By default, STAF installs to C:\STAF, so you will likely find it in the bin folder:
C:\STAF\bin\STAFProc.exe
-
In the Start the application field, select Automatically, but shortly after the computer boots. With this setting, STAF will start 1-2 minutes after a reboot — after critical windows services
(such as networking and domain authentication) have fully initialized and are ready to go.
-
In the Name field, enter the name that you will call the application in AlwaysUp.
We kept the default of STAFProc but you can specify a more meaningful name if you like.
-
Click over to the Logon tab. Check the box at the bottom to prevent annoying notifications when STAF runs in the background in Session 0:
Note: This is not necessary for the latest versions of Windows where access to Session 0 has been removed.
-
We are now done configuring STAF to run as a service so click the Save >> button to record your settings.
After a couple of seconds, an entry called STAFProc will appear in the AlwaysUp window.
The state will be "Stopped" because STAF hasn't been started yet:
-
Now that STAF is configured to start at boot, there is no need to launch it again when you login.
We recommend using Microsoft's
free Autoruns tool to disable STAF's auto-start but any "startup manager" should do the trick.
With Autoruns, click over to the Logon tab and un-check the box beside the STAFProc.lnk entry:
-
To start STAF from AlwaysUp, choose Application > Start "STAFProc". The program will start invisibly in the background, on the
isolated Session 0.
Click on the green circle icon to see some details about the running process:
-
To verify that STAF is operating properly, bring up a command prompt (started as an administrator) and run:
staf local ping ping
Look for a successful PONG response:
-
That's it! Next time your computer boots, STAF will start up immediately, before anyone logs on.
We encourage you to edit STAF in AlwaysUp and check out the many other settings that may be appropriate for your environment.
For example, send email when STAF crashes or stops for any reason, boost the priority of the process,
automatically restart the program nightly to cure memory leaks, and much more.
STAF not working properly as a Windows Service?
Consult the AlwaysUp Troubleshooter — our online tool that can help you resolve the most common problems encountered when
running an application as a windows service.
From AlwaysUp, select Application > Report Activity > Today... to bring up a HTML report detailing the interaction between AlwaysUp and STAF.
The AlwaysUp Event Log Messages page explains the messages that may turn up.
Browse the AlwaysUp FAQ for answers to commonly asked questions and troubleshooting tips.
Check the STAF FAQ.
Contact us and we will be happy to help!
|
Over 94,000 installations, and counting!
|
|
|
Rock-solid for the past 19+ years!
|
Fully Compatible with 160+ Applications...
|