The Core Technologies Blog

Professional Software for Windows Services / 24×7 Operation

Q & A: What Setting will Help AlwaysUp Start my App at Boot?

Q & A - Restart Windows
  I’m running on Windows Server 2016. I have noticed on my most recent install that AlwaysUp doesn’t start at boot, I have to do an interactive/RDP login and then open the AlwaysUp GUI to have the services started. Is there any setting that I need to change to make this happen please?

— Robert

Hi Robert. There could be many reasons why a generic Windows Service doesn’t start at boot. But when AlwaysUp is involved, the failure is usually because your service/application is trying to start too soon. Here are a couple of reasons why:

  1. Your application depends on a Windows Service

    System software will often be deployed as a windows service. Notable examples include the Apache web server, the MySQL relational database and the Redis memory store.

    If your application depends on a service, then you should configure the dependency on the Startup tab. Check the Ensure that the following services have started box and select your service from the list below:

    Set Dependent Services in AlwaysUp

    However, this setting may not work as expected. While it ensures that the critical service has started before AlwaysUp launches your application, there is no guarantee that the service will actually be ready.

    For example, suppose the Redis service takes a minute to initialize before connections are accepted. If your application tries to start before those 60 seconds have elapsed, it will fail to connect to Redis and will likely crash or exit with an error.

  2. You are running AlwaysUp on a Domain Controller (DC)

    Let’s say that your machine is a Domain Controller and you have specified a domain account on the AlwaysUp Logon tab. If Windows tries to kick off AlwaysUp before the DC is fully ready, the AlwaysUp service will fail to start because it can’t log in. You will see a cryptic message like this in the Windows/Application section of the Event Log:

    Windows Service Logon Failure

    To resolve this scenario, add a dependency on the “Workstation” service on the AlwaysUp Startup tab. Some customers have had success with that change but it hasn’t worked for others.

General Solution: Delayed Startup on Boot

Irrespective of the underlying problem, many customers have profited from a simple solution: delaying the startup of your AlwaysUp application. Your application is very likely to start properly once it avoids the “mad rush” of programs straining to start as your PC comes alive.

To delay startup, choose the Automatically, but shortly after the computer boots option on the General tab:

Delay startup on boot in AlwaysUp

With that modification, your application will start 1-2 minutes after your computer boots — when all critical components should be happily running.

Hopefully this easy change will do the trick. Please be sure to get in touch if the problem persists!

Posted in AlwaysUp | Tagged , , , | Leave a comment

Leave a Reply

Your email address will not be published. Required fields are marked *