For years I’ve been sending data to my emoncms system from a TP-Link HS110 power switch that I control and monitor using a perl program that calls a python program to communicate with the HS110 (the HS110 has some old firmware that permits this). The data has been submitted to emoncms using HTTP like the following:
We went away for a few days over Xmas and when I got back various things were broken I’ve fixed most but this data input is still not working and I don’t understand why. I looked at the docs online and see they say to use a URL that doesn’t include the ‘emoncms/’ part. So I tried deleting that and now I see data being posted to the right device with the right input names, but not to the right inputs (see the screenshot):
So I’m confused! I haven’t updated my system recently so I don’t understand why it ‘works’ without emoncms/ but has been working up until now with the emoncms/ ? And how do I most easily get the system back to a state where the data is being sent to the correct inputs so my feeds get updated properly?
@djh - have you updated in the last day or so? Did you do that in an attempt to get it working?
@TrystanLea - could the fix for duplicate inputs have caused this?
@djh - I note you use the http://emonpi/ URI rather than the IP address. My suspicion is that something happened to your Hub that caused the mDNS name to not be found.
What other things were ‘broken’? Could it be an issue with your Router/Hub etc?
I don’t remember exactly why I use emonpi - the example in the docs now uses emonpi.local - but it’s worked like that for years and it still works now sometimes, but with the modified path. The script doing the posting is running on the same pi, so I could have used localhost instead I suppose. What do you mean by my Hub ?
Other completely irrelevant things. And no, there’s no hint of any evidence of a problem with my router.
But that was caused by the integration using JSON instead of FullJSON. Using the latter fixed it for the HA component. I was meaning the MQTT input duplicates issue.
Perl doesn’t arbitrarily insert spaces and I didn’t edit the source except to delete the ‘emoncms/’ from the URL I cut and pasted here.
The situation has changed now though, so I can’t investigate any further at the moment. I can’t ssh into the pi, so I suspect something corrupted/died on the SD card.
It’s annoying that pi’s just sort of die without giving any kind of warning.
Yup. I don’t use them for anything that is disk write intensive. I’ve found old Laptops with PVE installed and running emoncms in a container or VM is a good and cheap solution.
Our general impression is that Pi SD card corruption issues have become very rare. I cant remember the last time I changed an SD card now. Switching to industrial SD cards around 2021 certainly seemed to help emonSD Industrial - Pre-loaded SD card - Shop | OpenEnergyMonitor .
So I’ve installed emoncms on another machine, and I’m hoping to connect it to my existing pi running emonhub, so it gets data. And I’m also hoping to copy my existing feed definitions and data and graphs from the pi or from a backup I regularly make into the new copy of emoncms.
Are these actions documented anywhere or at least the basic steps described, or will I need to dig through lots of code and docs to figure something out?