jwagner010 Posted March 6, 2023 Posted March 6, 2023 @glarsen @bpwwer This morning noticed my Dyson fans were not responding to commands from the DysonPureCool Node Server. Checking PG3 it says they are disconnected and so I went to start the node server and the following error is displayed "Node server start: Automatic Update Failed". So then I check the Node server store and the DysonPureCool node server is no longer listed in the node server store. I also check my purchases on PG3 and DysonPureCool is also missing from my past purchased node servers.
bpwwer Posted March 6, 2023 Posted March 6, 2023 Looks like @glarsendeleted it from the store. He also seems to have removed the node server from github.
Solution glarsen Posted March 6, 2023 Solution Posted March 6, 2023 Oops, sorry, my bad. Accidentally deleted production instead of pre-prod. It was never on github. I'll try to fix it now. 1
jwagner010 Posted March 6, 2023 Author Posted March 6, 2023 (edited) @glarsen @bpwwer I see it in the store now, however, when I do a restart for it to reinstall I still get the message "Node server start: Automatic Update Failed". When I look at my purchased Node servers its still not showing up as one of my purchased node servers anymore so I suspect it could be failing to do the re-install because it thinks I haven't previously purchased it? How do I get that corrected so it appears on my list of purchased node servers again? Also the log (second last entry) seems to suggested the node server has not been added back to the production store still but I do see it in the store. Maybe related when I see it in the store, the information/description about the node server is scrambled so perhaps it hasn't been loaded currently in the store? Either way still not installing / working ]or me. 3/6/2023, 16:27:28 [pg3] info: [XX:XX:XX:XX:XX:XX_2] Retrieved customparams 3/6/2023, 16:27:28 [pg3] info: [XX:XX:XX:XX:XX:XX_2] Retrieved customparamsdoc 3/6/2023, 16:27:28 [pg3] info: [XX:XX:XX:XX:XX:XX_2] Retrieved customtypeddata 3/6/2023, 16:27:28 [pg3] info: [XX:XX:XX:XX:XX:XX_2] Retrieved notices 3/6/2023, 16:27:28 [pg3] info: [XX:XX:XX:XX:XX:XX:a1_2] Retrieved oauth 3/6/2023, 16:27:30 [pg3] info: [DysonPureCool(2)]: Restarting Node Server 3/6/2023, 16:27:30 [pg3] warn: [DysonPureCool(2)]: Was not running. Starting... 3/6/2023, 16:27:33 [pg3] info: startNs:: DysonPureCool 3/6/2023, 16:27:33 [pg3] info: startNs:: DysonPureCool is valid 3/6/2023, 16:27:33 [pg3] info: checkLicense:: DysonPureCool Valid perpetual license found. 3/6/2023, 16:27:33 [pg3] error: updateNs: Node server DysonPureCool has no store entry in Production. 3/6/2023, 16:27:33 [pg3] error: DysonPureCool automatic update failed xx'ed out the UUID Edited March 6, 2023 by jwagner010
bpwwer Posted March 6, 2023 Posted March 6, 2023 It found your license so that's a good thing. But since it's a new entry in the store and has new purchase options, your PG3 can't figure out which purchase option was used to purchase it initially so can't auto-update it. You should be able to go to the node server server store, select the "Install" for the DysonPureCool node server and you'll have an option to re-install it to the existing slot. That should get you the latest version and then PG3 should now which install option was used for future updates. 1
jwagner010 Posted March 6, 2023 Author Posted March 6, 2023 (edited) Where should I see install button I only see a purchase button from within the node server store. See screenshot Edited March 6, 2023 by jwagner010
bpwwer Posted March 6, 2023 Posted March 6, 2023 From the log it looked like it was recognizing the license, but it should have an "Install" button instead of a purchase button so maybe not. I would think it would show up under the Purchases screen as well. So before you do anything else, can you do something from a ssh command line? If you can run the following: sqlite3 /var/polyglot/pg3/pg3.db Then, from the sqlite prompt type: select name,nsid from Node Server where name="DysonPureCool"; This should show one line that looks something like: DysonPureCool|c8cca282-ba32-47a7-b56a-abbc8e25904c But the ID string will be different. I need to see that ID string. To exit sqlite, type ".ex" and it will return the normal ssh command prompt
glarsen Posted March 6, 2023 Posted March 6, 2023 There's something odd about that screenshot too. This is what I see in the node server info display on the production store, and what you should be seeing:
jwagner010 Posted March 6, 2023 Author Posted March 6, 2023 I am at work right now so cannot SSH in. However, I now see what you see when going into the Node Server store, perhaps @glarsen updated it again or perhaps it took a while to refresh through, either way I do see what you see. Two things: 1) So I when I now look at the purchased node servers and see it in there now but the [Free] version, no license number, see screenshot 2) So it now lets me do an install in the old slot and it appears to install (version number goes to 4.01) but the node server doesn't start or connect to the ISY, there isn't even a Dyson log created. The PG3 log is below when I do the install. Short story is the Node Server looks like it updates/installs but doesn't start: 3/6/2023, 17:33:08 [pg3] info: [XX:XX:XX:XX:XX:XX_2] :: Creating Node Server 'DysonPureCool' 3/6/2023, 17:33:08 [pg3] info: DysonPureCool preveously installed, re-installing... 3/6/2023, 17:33:08 [pg3] info: Adding customparams entries to custom database 3/6/2023, 17:33:08 [pg3] info: Adding nsdata, oauth entries to custom database 3/6/2023, 17:33:08 [pg3] info: [XX:XX:XX:XX:XX:XX_2] Set nsdata 3/6/2023, 17:33:08 [pg3] info: [XX:XX:XX:XX:XX:XX_2] Set oauth 3/6/2023, 17:33:08 [pg3] info: checkLicense:: DysonPureCool Valid perpetual license found. 3/6/2023, 17:33:08 [pg3] warn: DysonPureCool home directory exists already. 3/6/2023, 17:33:08 [pg3] error: unhandledRejection REPORT THIS!: [object Promise], reason: Error: Request failed with status code 404
glarsen Posted March 6, 2023 Posted March 6, 2023 (edited) That's odd, there is no 'Free' version. There was a 'Free Trial' version in the Beta store, but not in the Production store. The Beta has been removed. Edited March 6, 2023 by glarsen
bpwwer Posted March 6, 2023 Posted March 6, 2023 Now that you've re-installed, it's overwritten the nsid that I wanted to see so never mind. Do you remember what you originally installed? I'm not entirely sure how the license is linked but since there can be more than one license type associated with a given node server, it needs to have some way to know which purchase option entry was used to purchase the the license. If the purchase option entries change, as they seem to have in this case, then the license may be linked to a non-existent purchase option. This makes it difficult to properly validate a license. I'm not real sure what to do about this since I can't look at license records nor do I know if it's possible to manually update the records to link with the new purchase option. This may be something that @glarsen, UDI will have to work with you to resolve.
jwagner010 Posted March 6, 2023 Author Posted March 6, 2023 Let me take a look when I get home. I have the node server in slots 2 and 3 (two different Dyson fans), I only updated slot 2 right now, and I am pretty sure that slot was initially first installed with the Free version as I was helping @glarsen test an updates to the node server a couple months back in the non production store and he then migrated that to production at which point I updated the version in slot 2 from a free non production version to the licensed production version. Short story is perhaps the nsid is still there for slot 3? Also I found the email confirmation when I purchased the node server and it has a license number on it, will PM it to you.
jwagner010 Posted March 7, 2023 Author Posted March 7, 2023 (edited) When I run the command select name,nsid from Node Server where name="DysonPureCool"; I get an error Parse error: no such column: nsid So I just ran: select name from Node Server where name="DysonPureCool"; and it returned nothing So to check I ran the command with another one of my purchased Node Servers OpenWeatherMap (but without nsid field) select name from Node Server where name="OpenWeatherMap"; and it returned OpenWeatherMap So would appear DysonPureCool is not listed in the table at all? (not sure of nsid field not being defined as a column in the the table?) Thoughts on anything else I can try or do I need to open a ticket with UDI? Quote If you can run the following: sqlite3 /var/polyglot/pg3/pg3.db Then, from the sqlite prompt type: select name,nsid from Node Server where name="DysonPureCool"; This should show one line that looks something like: DysonPureCool|c8cca282-ba32-47a7-b56a-abbc8e25904c But the ID string will be different. I need to see that ID string. To exit sqlite, type ".ex" and it will return the normal ssh command prompt Edited March 7, 2023 by jwagner010
jwagner010 Posted March 7, 2023 Author Posted March 7, 2023 In addition to my post above, not sure if it is just the license causing the issue? I did a fresh install in a new slot for version 4.0.1 of the node server and it does not even start and removes itself. I am running the latest version of PG3 3.1.18 on my POLISY. Here is the PG3 log when I tried to install it in a new slot (slot 6) below. Would appear to be a different/bigger problem than just the odd appearing license, as the node server seems to pass the license test when installing. Are others able to install the node server in a new slot under PG3 version 3.1.18 via the store? 3/7/2023, 06:04:07 [pg3] info: [XX:XX:XX:XX:XX:XX_6] :: Creating Node Server 'DysonPureCool' 3/7/2023, 06:04:07 [pg3] info: Adding customparams entries to custom database 3/7/2023, 06:04:07 [pg3] info: Adding nsdata, oauth entries to custom database 3/7/2023, 06:04:07 [pg3] info: [XX:XX:XX:XX:XX:XX_6] Set nsdata 3/7/2023, 06:04:07 [pg3] info: [XX:XX:XX:XX:XX:XX_6] Set oauth 3/7/2023, 06:04:07 [pg3] info: checkLicense:: DysonPureCool Valid perpetual license found. 3/7/2023, 06:04:07 [pg3] warn: DysonPureCool home directory exists already. 3/7/2023, 06:04:18 [pg3] error: unhandledRejection REPORT THIS!: [object Promise], reason: Error: Request failed with status code 404 3/7/2023, 06:04:39 [pg3] info: [XX:XX:XX:XX:XX:XX_6] Retrieved customparams 3/7/2023, 06:04:39 [pg3] info: [XX:XX:XX:XX:XX:XX_6] Retrieved oauth 3/7/2023, 06:05:01 [pg3] info: [XX:XX:XX:XX:XX:XX_6] Retrieved customparams 3/7/2023, 06:05:01 [pg3] info: [XX:XX:XX:XX:XX:XX_6] Retrieved oauth 3/7/2023, 06:05:31 [pg3] info: [XX:XX:XX:XX:XX:XX_6] Retrieved customparams 3/7/2023, 06:05:31 [pg3] info: [XX:XX:XX:XX:XX:XX_6] Retrieved oauth 3/7/2023, 06:06:01 [pg3] warn: [XX:XX:XX:XX:XX:XX_6] ISY does not have this Node Server. Removing from PG3. 3/7/2023, 06:08:01 [pg3] error: custom.add insert failed SqliteError: FOREIGN KEY constraint failed 3/7/2023, 06:08:01 [pg3] error: custom.add insert failed SqliteError: FOREIGN KEY constraint failed 3/7/2023, 06:08:01 [pg3] info: [XX:XX:XX:XX:XX:XX_6] Set customparams 3/7/2023, 06:08:01 [pg3] info: [XX:XX:XX:XX:XX:XX_6] Set customtypeddata 3/7/2023, 06:08:34 [pg3] error: MQTT on Inbound processFunction: TypeError: Cannot read properties of undefined (reading 'id') at Object.startNs (/var/polyglot/node_modules/@universaldevices/pg3/lib/services/node servers.js:868:27) at Object.startNs [as func] (/var/polyglot/node_modules/@universaldevices/pg3/lib/modules/frontend/ns.js:153:22) at process.processTicksAndRejections (node:internal/process/task_queues:95:5) 3/7/2023, 06:08:45 [pg3] error: MQTT on Inbound processFunction: TypeError: Cannot read properties of undefined (reading 'id') at Object.startNs (/var/polyglot/node_modules/@universaldevices/pg3/lib/services/node servers.js:868:27) at Object.startNs [as func] (/var/polyglot/node_modules/@universaldevices/pg3/lib/modules/frontend/ns.js:153:22) at process.processTicksAndRejections (node:internal/process/task_queues:95:5) 3/7/2023, 06:08:46 [pg3] error: MQTT on Inbound processFunction: TypeError: Cannot read properties of undefined (reading 'id') at Object.startNs (/var/polyglot/node_modules/@universaldevices/pg3/lib/services/node servers.js:868:27) at Object.startNs [as func] (/var/polyglot/node_modules/@universaldevices/pg3/lib/modules/frontend/ns.js:153:22) at process.processTicksAndRejections (node:internal/process/task_queues:95:5) 3/7/2023, 06:08:46 [pg3] error: MQTT on Inbound processFunction: TypeError: Cannot read properties of undefined (reading 'id') at Object.startNs (/var/polyglot/node_modules/@universaldevices/pg3/lib/services/node servers.js:868:27) at Object.startNs [as func] (/var/polyglot/node_modules/@universaldevices/pg3/lib/modules/frontend/ns.js:153:22) at process.processTicksAndRejections (node:internal/process/task_queues:95:5)
bpwwer Posted March 7, 2023 Posted March 7, 2023 Either I wasn't thinking when I typed the sql command or this auto-corrected it for me. It should have been: select name,nsid from Node Server where name="DysonPureCool"; You can also leave off the where name= part and just do select name,nsid from Node Server; which will display all installed node servers. I looked at the store entry and I don't see anything wrong, but something is happening during the install because it shouldn't be throwing the unhandled rejection error. a 404 is a not found error so maybe the .zip package hasn't been uploaded to the server so it can't be found, downloaded, and installed.
bpwwer Posted March 7, 2023 Posted March 7, 2023 Can you try re-installing it now. Do a refresh store first (from the Node Server store page). The problem with the unhandled exception should be fixed so it should install properly. 1
jwagner010 Posted March 8, 2023 Author Posted March 8, 2023 That did the trick, installed and working now. Much appreciated all, I know this stuff is a PIA for all, so do appreciate the support from this community. PS The 'purchased' node servers table still shows as [Free] under the order ID column. Not sure I should worry about that or ignore it, but I definately purchased the NS not the free version and it used to show the Order ID number. Again thanks both for getting back up and running 1
jwagner010 Posted March 8, 2023 Author Posted March 8, 2023 I believe it should be id not nsid. Either way I sent you a PM of the entire table. 8 hours ago, bpwwer said: Either I wasn't thinking when I typed the sql command or this auto-corrected it for me. It should have been: select name,nsid from Node Server where name="DysonPureCool"; You can also leave off the where name= part and just do select name,nsid from Node Server; which will display all installed node servers. I looked at the store entry and I don't see anything wrong, but something is happening during the install because it shouldn't be throwing the unhandled rejection error. a 404 is a not found error so maybe the .zip package hasn't been uploaded to the server so it can't be found, downloaded, and installed.
glarsen Posted March 8, 2023 Posted March 8, 2023 @jwagner010, @bpwwer, thanks for your patience and help in resolving this. A brain **** when cleaning up old node server entries in my dev list caused it all.
Recommended Posts