This article provides an alternate method of starting Interactive Windows Services and detection under FireDaemon control in the currently logged in session. In our previous article we discussed how to do this using logon scripts. In this article we discuss how to automate your Windows login and run interactive services using Scheduled Tasks.
Step 1: Install FireDaemon Pro and Setup Your Services This is fairly straight forward:
- Download and install FireDaemon Pro
- Create your FireDaemon services. Ensure they are set to Manual Start and they are running as the LocalSystem account (ie. don't specify a user in your configuration). Check out our HOWTOs if you need a guidance setting up your app under FireDaemon control.
Step 2: Setup Automatic Login You now want to set automatic login for user you want to run your services as. To do this on Windows 7:
- Run netplwiz.exe
- Uncheck "Users must enter a username and password to use this computer" then click OK
- Supply the autologin username and password. If you want to use a domain user account see this article.
- Create a new Task (not a Basic Task) as follows:
- Run sched.exe (Windows 7) or taskschd.msc /s (Windows 8). Then in the
- General Tab
- Name: FireDaemonServices
- Check: Run only when user is logged on
- Check: Run with highest privileges
- Check: Hidden
- Configure for: Windows 7, Windows Server 2008 R2 (change this to suite your app and version of Windows)
- Actions Tab (add an action for each service to be elevated - click the New button. Replace ServiceA with the actual short name of your service)
- Action: Start a Program
- Settings / Program/Script: "C:\Program Files\FireDaemon\firedaemon.exe"
- Settings / Add Arguments: --start ServiceA --in-session
- Conditions Tab
- Uncheck Start the task only if the computer is on AC power
- Settings Tab
- Uncheck Stop the task if it runs longer than
- Uncheck If the running task does not end when request
- If the task is already running, then the following rules applies: Run a new instance in parallel
- General Tab