Page 2 of 2
Re: New value item logger implementation!
Posted: Sun Mar 06, 2016 10:42 am
by Don MC
Step by step instructions on how to set this up would be great. My thermometers are set up to log individual text logs (like for my bedroom thermometer: /var/log/nethome/t_bedroom.log).
The graphs do load quite slowly and I'd like to speed that up a little bit, but I can't understand the instructions in this thread.
My NetHome runs on a Raspberry Pi.
Re: New value item logger implementation!
Posted: Sun Mar 06, 2016 7:08 pm
by SourceCodeSourcerer
Hi Don MC!
I've added documentation that integrates with NetHomeServer.
You reach it from the
View online documentation link from the
Create new Item page from within your running NetHomeServer.
Or, you can also reach it from a created H2DatabaseTCPServer home item. It's the link named [H2DatabaseTCPServer] below the home item name.
In any case, the link refers to the following page:
http://wiki.nethome.nu/doku.php/h2databasetcpserver.
Hopefully the
Configure global logging to the database boils down the steps needed to enable the database logging. It's not much to it. However, we would love to hear (positive
) feedback and suggestions for improvements.
Thanks for your input!
/Peter
Re: New value item logger implementation!
Posted: Sun Mar 06, 2016 9:08 pm
by Don MC
Wow, thanks! Now I understand it much better. Will try it out ASAP and will provide feedback as soon as I have it up and running.
Re: New value item logger implementation!
Posted: Mon Mar 07, 2016 9:30 pm
by Don MC
I got it working by following the wiki. Moving the old logs from text files on my R-Pi2 took less than 10 mins, resulting in a db of >70MB. I've got around 10 thermometers and 10 hygrometers with accumulated data from around 2 years back (760 days).
The graphs load fast now. But I'd like to be able to "fast jump" to any given month/date instead of clicking them backwards or forwards one at a time. For example, if I want to see the temperature for June 15th 2015, I have to first open the current month and then step back one month at a time until I get to June 2015. Only then can I drill down to the date I want.
Is there any shortcut to this?
E: Will it still be logging into those text files as well?
Re: New value item logger implementation!
Posted: Mon Mar 07, 2016 10:00 pm
by SourceCodeSourcerer
Hi Don,
Yes, as long as the pathnames are still defined for each home item in the LogFile field, the text logs will still be written to.
About "fast jump" to a month/date, this is one of several things one would want to do with graphs like these, I agree. I don't think Stefan has the time to do this right now, and I'm also busy elsewhere.
Anyone wanting to step up and improve the charts, or create new implementations are welcome to contribute.
We would surely want to add this to the backlog thought.
Thanks for your feedback!
/Peter
Re: New value item logger implementation!
Posted: Wed Oct 04, 2017 8:47 am
by perjarle
Is there any way to make the db file go to a spesific location?
I have mounted a nas folder to /var/log/nethome to minimize writing operations on the rpi sd card.
But the db files are created in /home/pi/nethome.
How can I make the db files go to /var/log/nethome?
Br
Per
Re: New value item logger implementation!
Posted: Thu Oct 05, 2017 9:17 pm
by SourceCodeSourcerer
Hi perjarle!
You should be able to change the DatabasePath, please see the Settings documentation at
http://wiki.nethome.nu/doku.php/h2databasetcpserver.
/Peter