Announcement

Collapse
No announcement yet.

Windows 10 / HS3 automatic start from a cold boot

Collapse
This is a sticky topic.
X
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

    #46
    Originally posted by RoChess View Post

    The answer is pretty much in the response, just add /F to it, so use:

    taskkill /F /IM HS4Sentry.exe
    pause
    taskkill /F /IM HS4.exe
    pause
    ya know, i'm not sure if you are a smart *** or just smart. you have stated the obvious, but since you have almost 700 posts, i'm betting that happens a lot.

    it was the WISDOM of applying a force to the shutdown that I question, maybe i needed to spell it out for the keyboard warriors out there.

    Comment


      #47
      I have had a persistent startup problem with HS3 and now HS4. The Task Scheduler starts HS4 program as expected but the Speaker.exe never executes unless I log in and manually run it. Even though the Start Speaker checkbox in HS Setup is ticked, it never runs.

      I created a Startup Task with a one minute start delay, allowed it to stop any running copies, run if logged in not, highest permission, startup folder is set C:\HS4
      When I look at the Task Scheduler it shows that the speaker task is running.

      I have tried using the netplwiz but in the advanced settings it warns me that this version of Windows does not support that feature.


      HS4Pro 4.1.9.0
      Win10 Home
      C:\HS4 is the install folder

      Comment


        #48
        Originally posted by aimless View Post

        Any ideas? I wrote the script and tested, got this back (using pause to debug):
        ________________________________________
        taskkill /IM HS4Sentry.exe
        pause
        taskkill /IM HS4.exe
        pause
        ________________________________________
        C:\Windows\system32>taskkill /IM HS4Sentry.exe
        ERROR: The process "HS4Sentry.exe" with PID 1816 could not be terminated.
        Reason: This process can only be terminated forcefully (with /F option).

        C:\Windows\system32>pause
        Press any key to continue . . .

        C:\Windows\system32>taskkill /IM HS4.exe
        ERROR: The process "HS4.exe" with PID 11500 could not be terminated.
        Reason: This process can only be terminated forcefully (with /F option).

        C:\Windows\system32>pause
        Press any key to continue . . .
        ________________________________________
        Are you testing via an actual windows shutdown event? Or testing in just the .cmd?

        I'm not sure why it doesn't work for HS4. I would NOT use the /F switch as that will almost guarantee corruption.

        I don't think there is any need to shut down the Sentry, So I would get rid of everything in except for taskkill /IM HS4.exe. (don't pauses) and try it in an actual shutdown or restart event.
        RJ_Make On YouTube

        Comment


          #49
          Originally posted by aimless View Post
          ya know, i'm not sure if you are a smart *** or just smart.
          The truth often lies in the middle

          It is indeed risky to use /F because it can lead to corruption on open-file handles, such as for example database not closing properly. This can be compensated in SQLite for example with a PRAGMA check, but then it relies on HS4.exe to do that check before it starts. Backups are always a good idea, but that is regardless of you using such a script or not. The other option is to check for open-file handles with an advanced tool such as procexp.exe from SysInternals, which can also be batch-scripted via command-line.

          However, you ommitted a lot of details, because the key question obviously in your case is digging deep to find out why a normal shutdown process isn't working. Do the logs give you any insight? or it is just a matter of patience and that things take a little longer for you? Are there any errors preventing it? Have you looked into launching HomeSeer is a different way so that it shuts down easier?

          Still, power can fail, computers can abruptly halt processing for other reasons, so it is always wise to have the ability to survive such a shut-down, and I've got batch-scripts myself to /F(orce) the close down of applications remotely. For me it is when I RDP into a system via concurrent-RDP and need to shut down an application on the main session. Without /F I cannot do this, because I don't have visual or physical access to 'Okay' the normal shutdown process.

          Have you looked into BLShutdown plugin?

          Comment


            #50
            Originally posted by Kitar View Post
            I have had a persistent startup problem with HS3 and now HS4. The Task Scheduler starts HS4 program as expected but the Speaker.exe never executes unless I log in and manually run it. Even though the Start Speaker checkbox in HS Setup is ticked, it never runs.

            I'm on 20H2 as of a few days, and HomeSeer, SpeakerClient and Sentry load just fine on a single TaskScheduler task to load HS3.exe (no time yet to upgrade) at log-on of the primary Windows 10 user. I've also have it check for "Run whether user is logged on or not", however the primary task itself triggers at "At log on of HOMESEER\HomeSeer" (yes, I was super creative in naming WORKGROUP and User account).

            I've got one extra task added that runs shutdown.exe /l to then immediately log-off the user and keep things somewhat more secure.

            This works well if you can use the 'Netplwiz' method, but I have a feeling you are using "Windows 10 Home" and not the "Windows 10 Pro" that this tool is designed for which might be why you're seeing errors.

            For "Windows 10 Home", use WinKey+R (or right click on Windows 10 Start menu item and select "Run...") try "control userpasswords2" without the quotes and confirm any UAC notice you might get that you wish to allow access. Switch to the "Users" tab if needed.

            If the checkbox for "Users must enter a username and password to use this computer" is already checked then simply uncheck it and click "Apply" button, which will then ask you to enter password and you can verify that your username is listed in the box underneath checkbox. Otherwise re-enable checkbox, and use the "Add..." button to add your username, and then uncheck the checkbox again to ensure Windows will boot into desktop without requiring password.

            PS: HomeSeer > Tools > Setup > On the 'General' tab, the "Launch Speaker Client on Startup" entry is CHECKED, right? Also wise to have the "HSSentry (Software System Monitor)" option checked as well.

            PPS: Are you perhaps trying to boot into the system without a password on a Microsoft account? Far as I know a true local-user-account is needed, so be sure to create one and use that one to boot into the system. Never tried that on a Microsoft account, unless it was tied to a local-user account.

            Comment


              #51
              Thanks for the input. I am on Win10 Home edition. Actually I do have a Win10 Pro key so I am going to see if I can upgrade that machine without a re-install.

              Comment


                #52
                Hi there - hoping this group's collective memory can help with mine. I implemented an early version of the topic of this thread to auto-launch HS3 at boot. In that earlier version, there was a command that would login, then sleep for 30, then launch the HS3 application, sleep 30 and lock the account. Here's my issue and question. I am attempting to turn all of the HS3 auto-launch stuff off in order to implement HS4 service. I can find everything, but the initial command to sleep for 30. It still launches at every login. I seem to recall it being a registry setting created via regedit, but I cannot find it. Any ideas of how to turn this off or from where it was initiated? Thank you!

                Comment


                  #53
                  Can you find it with Autoruns, running as an administrator?

                  Comment


                    #54
                    Originally posted by jjcrowley1 View Post
                    Hi there - hoping this group's collective memory can help with mine. I implemented an early version of the topic of this thread to auto-launch HS3 at boot. In that earlier version, there was a command that would login, then sleep for 30, then launch the HS3 application, sleep 30 and lock the account. Here's my issue and question. I am attempting to turn all of the HS3 auto-launch stuff off in order to implement HS4 service. I can find everything, but the initial command to sleep for 30. It still launches at every login. I seem to recall it being a registry setting created via regedit, but I cannot find it. Any ideas of how to turn this off or from where it was initiated? Thank you!

                    Depends on what method used.

                    Using Windows Key + R, enter "shell:startup" Remove any HS related shortcuts

                    OR

                    Look for a folder called whitelist under windows Scheduler. Disable and HS related tasks.
                    RJ_Make On YouTube

                    Comment


                      #55
                      Search for 'Startup Delayer'. It's a small freeware app that allows you to specify what you'd like to start and how long after Windows has finished with it's startup to delay until it launches whatever you'd like. It has a lot of options and works great under W10. I use it to overcome the issue of the HS Root directory not being set correctly at startup.

                      Comment


                        #56

                        thanks for the ideas. I have already tried the Shell:startup and removed everything there. I did not use the "delayer" application. going from memory - cannot find the instructions originally downloaded from this forum (or find them in the forum). Seems like there was a registry entry to run the sleep 30 command at auto logon - but cannot find it.

                        Comment


                          #57
                          If you use the Startup Delayer, there is no mucking with the registry. Just install, set the HS application and path and the delay and stick it or a link in your Startup Items folder.
                          Easy peezy.

                          Comment


                            #58
                            Originally posted by George View Post
                            If you use the Startup Delayer, there is no mucking with the registry. Just install, set the HS application and path and the delay and stick it or a link in your Startup Items folder.
                            Easy peezy.
                            Yes, thank you. Please note I am not trying to implement this, I am trying to remove it after using the "hack" for three years. I did not use Startup Delayer at the time it was implemented.

                            Comment

                            Working...
                            X