{"id":4694,"date":"2018-04-21T21:01:07","date_gmt":"2018-04-22T04:01:07","guid":{"rendered":"https:\/\/www.coretechnologies.com\/blog\/?p=4694"},"modified":"2019-12-16T09:13:03","modified_gmt":"2019-12-16T17:13:03","slug":"start-app-at-boot","status":"publish","type":"post","link":"https:\/\/www.coretechnologies.com\/blog\/alwaysup\/start-app-at-boot\/","title":{"rendered":"Q &#038; A: What Setting will Help AlwaysUp Start my App at Boot?"},"content":{"rendered":"<div align=\"center\"><img loading=\"lazy\" decoding=\"async\" src=\"\/blog\/images\/qa-starting-windows.png\" width=\"380\" height=\"154\" title=\"Q &#038; A - Restart Windows\" alt=\"Q &#038; A - Restart Windows\" border=\"0\" ><\/div>\n<div class=\"blog-qa-question-box\">\n<img decoding=\"async\" src=\"\/images\/quotes-transparent-21x21.png\">&nbsp;&nbsp;I\u2019m running on Windows Server 2016. I have noticed on my most recent install that AlwaysUp doesn\u2019t 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? <\/p>\n<p align=\"right\">&#8212; Robert<\/p>\n<\/div>\n<p>\nHi Robert. There could be many reasons <a href=\"\/blog\/windows-services\/windows-service-start-at-boot\/\">why a generic Windows Service doesn&#8217;t start at boot<\/a>. But when AlwaysUp is involved, the failure is usually because <b>your service\/application is trying to start too soon<\/b>. Here are a couple of reasons why:<\/p>\n<ol>\n<li>\n<h2><b>Your application depends on a Windows Service<\/b><\/h2>\n<p>System software will often be deployed as a windows service. Notable examples include the <a href=\"\/products\/ServiceProtector\/Services\/KeepApacheWindowsServiceRunning24x7.html\">Apache web server<\/a>, the <a href=\"\/products\/ServiceProtector\/Services\/KeepMySQLWindowsServiceRunning24x7.html\">MySQL relational database<\/a> and the <a href=\"\/products\/ServiceProtector\/Services\/KeepRedisWindowsServiceRunning.html\">Redis memory store<\/a>.<\/p>\n<p>If your application depends on a service, then you should configure the dependency on the Startup tab. Check the <b>Ensure that the following services have started<\/b> box and select your service from the list below:<\/p>\n<div class=\"image-padding\" align=\"center\"><a href=\"\/blog\/images\/set-service-dependencies-alwaysup.png\" class=\"zoomPopup\" title=\"Set Dependent Services in AlwaysUp\" target=\"_blank\" rel=\"noopener noreferrer\"><img decoding=\"async\" src=\"\/blog\/images\/set-service-dependencies-alwaysup.png\" title=\"Set Dependent Services in AlwaysUp (click to enlarge)\" alt=\"Set Dependent Services in AlwaysUp\" border=\"0\" ><\/a><\/div>\n<p>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 <i>ready<\/i>. <\/p>\n<p>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.\n<\/li>\n<li>\n<h2><b>You are running AlwaysUp on a Domain Controller (DC)<\/b><\/h2>\n<p>Let&#8217;s say that your machine is a <a href=\"https:\/\/en.wikipedia.org\/wiki\/Domain_controller_(Windows)\" target=\"_blank\" rel=\"noopener noreferrer\">Domain Controller<\/a> 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&#8217;t log in. You will see a cryptic message like this in the Windows\/Application section of the <a href=\"\/blog\/windows-services\/event-viewer-troubleshoot-windows-services\/\">Event Log<\/a>:<\/p>\n<div class=\"image-padding\" align=\"center\"><a href=\"\/blog\/images\/windows-service-logon-failure-error.png\" class=\"zoomPopup\" title=\"Windows Service Logon Failure\" target=\"_blank\" rel=\"noopener noreferrer\"><img decoding=\"async\" src=\"\/blog\/images\/windows-service-logon-failure-error.png\" title=\"Windows Service Logon Failure (click to enlarge)\" alt=\"Windows Service Logon Failure\" border=\"0\" width=\"520\" ><\/a><\/div>\n<p>To resolve this scenario, add a dependency on the &#8220;Workstation&#8221; service on the AlwaysUp Startup tab. Some customers have had success with that change but it hasn&#8217;t worked for others.\n<\/li>\n<\/ol>\n<h2><b>General Solution: Delayed Startup on Boot<\/b><\/h2>\n<p>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 &#8220;mad rush&#8221; of programs straining to start as your PC comes alive.<\/p>\n<p>To delay startup, choose the <b>Automatically, but shortly after the computer boots<\/b> option on the General tab:<\/p>\n<div class=\"image-padding\" align=\"center\"><a href=\"\/blog\/images\/delay-alwaysup-startup.png\" class=\"zoomPopup\" title=\"Delay startup on boot in AlwaysUp\" target=\"_blank\" rel=\"noopener noreferrer\"><img decoding=\"async\" src=\"\/blog\/images\/delay-alwaysup-startup.png\" title=\"Delay startup on boot in AlwaysUp (click to enlarge)\" alt=\"Delay startup on boot in AlwaysUp\" border=\"0\" ><\/a><\/div>\n<p>With that modification, your application will start <a href=\"https:\/\/superuser.com\/questions\/285653\/what-does-delayed-start-do-in-startup-type-for-a-windows-service\" target=\"_blank\" rel=\"noopener noreferrer\">1-2 minutes after your computer boots<\/a> &#8212; when all critical components should be happily running.<\/p>\n<p>Hopefully this easy change will do the trick. Please be sure to <a href=\"\/support\">get in touch<\/a> if the problem persists!<\/p>\n<!-- relpost-thumb-wrapper --><div class=\"relpost-thumb-wrapper\"><!-- filter-class --><div class=\"relpost-thumb-container\"><style>.relpost-block-single-image, .relpost-post-image { margin-bottom: 10px; }<\/style><h3>You may also like...<\/h3><div style=\"clear: both\"><\/div><div style=\"clear: both\"><\/div><!-- relpost-block-container --><div class=\"relpost-block-container relpost-block-column-layout\" style=\"--relposth-columns: 3;--relposth-columns_t: 2; --relposth-columns_m: 2\"><a href=\"https:\/\/www.coretechnologies.com\/blog\/alwaysup\/run-java-exe-from-path\/\"class=\"relpost-block-single\" ><div class=\"relpost-custom-block-single\"><img decoding=\"async\" loading=\"lazy\" class=\"relpost-block-single-image\" alt=\"Q &amp; A: How do I get AlwaysUp to run Java.exe in the PATH?\"  src=\"https:\/\/www.coretechnologies.com\/blog\/wp-content\/uploads\/qa-150x150.png\" style=\"aspect-ratio:1\/1\" style=\"aspect-ratio:1\/1\"><\/img><div class=\"relpost-block-single-text\"  style=\"height: 75px;font-family: Arial;  font-size: 12px;  color: #333333;\"><h2 class=\"relpost_card_title\">Q &amp; A: How do I get AlwaysUp to run Java.exe in the PATH?<\/h2><\/div><\/div><\/a><a href=\"https:\/\/www.coretechnologies.com\/blog\/alwaysup\/import-windows-service-applications\/\"class=\"relpost-block-single\" ><div class=\"relpost-custom-block-single\"><img decoding=\"async\" loading=\"lazy\" class=\"relpost-block-single-image\" alt=\"Moving your AlwaysUp Applications\/Services? Easily Import Them All at Once\"  src=\"https:\/\/www.coretechnologies.com\/blog\/wp-content\/uploads\/alwaysup-bulk-import-logo-150x150-1.png\" style=\"aspect-ratio:1\/1\" style=\"aspect-ratio:1\/1\"><\/img><div class=\"relpost-block-single-text\"  style=\"height: 75px;font-family: Arial;  font-size: 12px;  color: #333333;\"><h2 class=\"relpost_card_title\">Moving your AlwaysUp Applications\/Services? Easily Import Them All at Once<\/h2><\/div><\/div><\/a><a href=\"https:\/\/www.coretechnologies.com\/blog\/alwaysup\/find-process-task-manager\/\"class=\"relpost-block-single\" ><div class=\"relpost-custom-block-single\"><img decoding=\"async\" loading=\"lazy\" class=\"relpost-block-single-image\" alt=\"Find your Application in Task Manager\"  src=\"https:\/\/www.coretechnologies.com\/blog\/wp-content\/uploads\/find-it-150x150.png\" style=\"aspect-ratio:1\/1\" style=\"aspect-ratio:1\/1\"><\/img><div class=\"relpost-block-single-text\"  style=\"height: 75px;font-family: Arial;  font-size: 12px;  color: #333333;\"><h2 class=\"relpost_card_title\">How do I Find my AlwaysUp Application in Task Manager?<\/h2><\/div><\/div><\/a><\/div><!-- close relpost-block-container --><div style=\"clear: both\"><\/div><\/div><!-- close filter class --><\/div><!-- close relpost-thumb-wrapper -->","protected":false},"excerpt":{"rendered":"<p>&nbsp;&nbsp;I\u2019m running on Windows Server 2016. I have noticed on my most recent install that AlwaysUp doesn\u2019t start at boot, I have to do an interactive\/RDP login and then open the AlwaysUp GUI to have the services started. Is there &hellip; <a href=\"https:\/\/www.coretechnologies.com\/blog\/alwaysup\/start-app-at-boot\/\">Continue reading <span class=\"meta-nav\">&rarr;<\/span><\/a><\/p>\n","protected":false},"author":1,"featured_media":3560,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[2],"tags":[26,127,170,193],"class_list":["post-4694","post","type-post","status-publish","format-standard","has-post-thumbnail","hentry","category-alwaysup","tag-alwaysup-tag","tag-qa","tag-troubleshooter","tag-windows-server-2016"],"_links":{"self":[{"href":"https:\/\/www.coretechnologies.com\/blog\/wp-json\/wp\/v2\/posts\/4694","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/www.coretechnologies.com\/blog\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/www.coretechnologies.com\/blog\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/www.coretechnologies.com\/blog\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/www.coretechnologies.com\/blog\/wp-json\/wp\/v2\/comments?post=4694"}],"version-history":[{"count":0,"href":"https:\/\/www.coretechnologies.com\/blog\/wp-json\/wp\/v2\/posts\/4694\/revisions"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/www.coretechnologies.com\/blog\/wp-json\/wp\/v2\/media\/3560"}],"wp:attachment":[{"href":"https:\/\/www.coretechnologies.com\/blog\/wp-json\/wp\/v2\/media?parent=4694"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/www.coretechnologies.com\/blog\/wp-json\/wp\/v2\/categories?post=4694"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/www.coretechnologies.com\/blog\/wp-json\/wp\/v2\/tags?post=4694"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}