Announcement

Collapse
No announcement yet.

Doesn't cache password for devices and causes HomeTroller Pi to lock up/corrup config

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

    Doesn't cache password for devices and causes HomeTroller Pi to lock up/corrup config

    I've been using this for quite a while on a PC and am migrating to a HomeTroller Pi. I've actually have 3 of them and can barely make it work on one. It seems to discover well in the auto mode but with authentication enabled I can only enter the info for 3 Shelly1's before it locks up and corrupts the config on the Pi. If I back up after each device I can get all 4 entered but upon restart the user name and password for the devices both show the username so after every restart I have to go in and re-enter the password. Also, it will randomly cause the Pi to lock up. It worked fine on HS3 but I upgraded one Pi to HS4 with the same results. I gave up on that one figuring it was the upgrade. I have since bought 2 more and the HS4 plugin and have the same result fresh out of the box. Any ideas?

    #2
    Also, when I try to add a Shelly1 that is at my other residence over a VPN it seems to discover and add fine when I put in the IP address but loses the config and and the Shelly tab (as well as locking up). I have to turn off auto discovery and add it manually (and of course authentication must be turned off on the Shelly)
    Click image for larger version  Name:	Screenshot 2021-11-28 085930.png Views:	17 Size:	274.1 KB ID:	1510666

    Comment


      #3
      Started migrating my other instance of HS to a Pi and have the same issues only worse. I have multiple VLANs (to isolate IoT devices). I can discover the device manually, however, if reboot, the plugin loses track of it. There must be something in the plugin that does not allow it to work across VLANs.

      Comment


        #4
        Please enable the deviceLog (not the Do Not Log in the above screenshot) - and post the logs, I need more info.

        Also post info from Tools => Help.

        Comment


          #5
          As you can see from the log, I installed the plugin and clicked the + to add the device. It created an unknown device at the loopback address. I went into the Shelly tab and corrected the IP address. It then came back requesting authorization with the user name prepopulated in both the user name and password. I then corrected the password. You can see from the log it then immediately rebooted the htpi. When I go to the device the AKShelly tab is gone. It also does not show up in the My Devices of the plugin.

          Code:
          Date/time=11/29/2021 3:04:12 PM CST
          Version=HomeSeer HS4 Pi Hub G2 Lite Edition 4.2.6.0 (Linux)
          MONO Version=Mono JIT compiler version 6.12.0.122 (tarball Mon Feb 22 17:44:05 UTC 2021)
          
          License=Registered
          License ID=696750
          MyHS Subscription=Premium
          MyHS Subscription Backup Interval=Monthly
          MyHS Subscription Max Cameras=1
          MyHS Subscription Backup Time=12:00 AM
          MyHS Subscription Backup Day=1
          Confguration File=/usr/local/HomeSeer/Data/HomeSeerData.json
          Uptime=0 Days 0 Hours 32 Minutes 54 Seconds
          User/Access=Bill (Admin)
          Lan IP=192.168.0.244 (HTPiHubG2v2)
          Client IP=192.168.0.206 (192.168.0.206)
          WAN IP=216.71.3.251 ()
          Device Count=5
          Event Count=2
          Last Event Ran=, Ran at 1/1/0001 12:00:00 AM
          # of unique event scripts=0
          Plugins Enabled=Z-Wave UI:,Z-Wave:,Global Cache Pro:,AK Shelly:
          Modules/Threads=77 Modules, 54 Threads
          Available Threads=399
          HomeSeer Memory Used=91 Mbytes
          Plugins Installed=AK Shelly 4.0.0.73,Global Cache Pro 5.0.0.59,TPLinkSmartHome4 2021.4.30.0,Z-Wave 3.0.9.0,Z-Wave UI 1.0.0.0
          Disk Size=28.33GB
          Attached Files

          Comment


            #6
            Since I didn't see a whole lot of anything in the Pi logs (Homeseer needs to work on that) I figured I'd try the HS4 plugin on my PC version.

            The log for the auth isue didn't show anything useful but the VLAN log turned out much better and you may find it useful.

            First I upgraded the plugin from 3 (which worked fine both with auth and across VLANs) to the HS4 plugin.
            First thing was it failed on auth. I added the passwords back in and came up with the same result as the Pi. The device had the user name in both the username and password fields in the plugin after reboot. That info is in the auth.txt file.

            I then figured I'd try adding the Shelly without auth on a different VLAN. Same result there. I can add it but after restarting HS4 there is no AK Shelly tab and it obviously doesn't work. VLAN.txt Hope that helps.

            Also hope I can successfully revert to the HS3 plugin...

            Again 2 issues. 1)user auth breaks upon HS restart 2) can manually add a Shelly on a different VLAN but it goes away upon HS restart.
            Attached Files

            Comment


              #7
              Thank you.

              So the last message before reboot is this?

              11/29/2021 2:57:33 PM AK Shelly Warning [20] Unknown: Execute(sync) {ShellySettingsBase} [settings]: The remote server returned an error: (401) Unauthorized. [response = 401 Unauthorized]

              And after that it causes reboot?

              Comment


                #8
                It looks like HS throws an exception when I try to create a device, but it's not clear what exactly HS doesn't like.

                I'll add exception handler and log

                Code:
                11/30/2021 11:02:53
                AK Shelly
                Error
                System.NullReferenceException: Object reference not set to an instance of an object.
                at: [B]Scheduler.hsapplication.CreateFeatureForDevice[/B](NewFeatureDat a featureData)
                11/30/2021 11:02:53
                AK Shelly
                Error
                Inner Exception: Object reference not set to an instance of an object.
                11/30/2021 11:02:53
                AK Shelly
                Error
                HSCF.Communication.ScsServices.Communication.Messages.ScsRem oteException: Object reference not set to an instance of an object. ---> System.NullReferenceException: Object reference not set to an instance of an object.
                at: Scheduler.hsapplication.CreateFeatureForDevice(NewFeatureDat a featureData)
                --- End of inner exception stack trace --- Server stack trace: Exception rethrown
                at: [0]:
                at: System.Runtime.Remoting.Proxies.RealProxy.HandleReturnMessag e(IMessage reqMsg, IMessage retMsg)
                at: System.Runtime.Remoting.Proxies.RealProxy.PrivateInvoke(Mess ageData& msgData, Int32 type)
                at: HomeSeer.PluginSdk.IHsController.CreateFeatureForDevice(NewF eatureData featureData)
                at: PluginLib.DeviceBase.CreateDevice(String name, String addr)
                at: PluginLib.DeviceBase.Create(String addr, String full_type, Int32 Device_Type, Int32 Device_SubType, String Device_SubType_Description, String dev_name)

                Comment


                  #9
                  It doesn't always reboot but becomes sluggish. I'm sure this has more to do with the htpi than your plugin. Global Cache doesn't work and neither does Envisalink. I'm taking them one at a time. Let me know what I can do to help!

                  Comment


                    #10
                    Originally posted by LikeAutomation View Post
                    It doesn't always reboot but becomes sluggish. I'm sure this has more to do with the htpi than your plugin. Global Cache doesn't work and neither does Envisalink. I'm taking them one at a time. Let me know what I can do to help!
                    Can you check in task manager which app uses CPU?

                    Normal process CPU usage should be next to 0

                    Comment


                      #11
                      This is on a HomeTroller Pi G2, not windows.

                      Comment


                        #12
                        Originally posted by LikeAutomation View Post
                        This is on a HomeTroller Pi G2, not windows.
                        htop then

                        Comment


                          #13
                          I think if you solve the authentication/VLAN problem you'll fix the resource issue; please concentrate on those so people can upgrade to the HS4 plugin on all platforms.

                          First I upgraded the plugin from 3 (which worked fine both with auth and across VLANs) to the HS4 plugin.
                          First thing was it failed on auth. I added the passwords back in and came up with the same result as the Pi. The device had the user name in both the username and password fields in the plugin after reboot. That info is in the auth.txt file.

                          I then figured I'd try adding the Shelly without auth on a different VLAN. Same result there. I can add it but after restarting HS4 there is no AK Shelly tab and it obviously doesn't work. VLAN.txt Hope that helps. (This is from the post above)

                          Comment


                            #14
                            ок

                            Comment


                              #15
                              Ver 4.0.0.76 - Fix saving user / password

                              Sorry, took me awhile. Please test.

                              I'll check adding device manually too

                              Comment

                              Working...
                              X