emonBase local emonCMS database and logging

I'm sure you've realized that I'm new here, I promise I have done many searches and read many posts, which have answered a multitude of questions I did have, before posting "new" questions...

From what I have read on the site, am I correct in stating that the emonTX does not cache data and if the base (emonPi/emonBase) is not available, for whatever reason, when the emonTX transmits the data then that data is lost?

Regarding the logging and emonCMS database, I intend getting an emonBase and running the emonCMS locally on it, I'll setup access to it form the Internet via my local server/firewall...
I've seen mention on the forums of running the base from a HDD, if I understood correctly. Would this be to have larger drive space for logging or some other reason (I've also seen mention of SD card lifespan)?
I intend having a emonTX with 4 CTs, 10 second logging, and 5/6 temp sensors, 60 second logging.
Is there a defined database log size per record that can be calculated and can this all be done onto just a larger capacity SD card or is it recommended to go the HDD route?
Is HDD the recommendation or has anyone used SSD with any dis/advantages or even just a large capacity USB stick?

I've also seen mentions of warning about doing proper shutdown on the emonPi and emonBase or you risk loosing data and possibly corrupting the SD card.
Is this still an "issue"? I do intend having my emonBase PSU connected on a UPS feed that is in turn fed by a hybrid inverter (basically a second UPS) so the chances are low that it will power off during one of our regular'ish power failures...

Robert Wall's picture

Re: emonBase local emonCMS database and logging

"am I correct in stating that the emonTX does not cache data"
That is correct.

"... running the base from a HDD .."
As I understand, that's principally for concerns regarding SD card life and the consequent loss of data when it does fail. As I'm sure you've read, many users don't see issues with SD card life or USB sticks, while many others do, reporting lives of anything between weeks and years. I think it's a decision you need to make base on what you perceive the probability and the consequences of a drive failure (whichever sort) to be. The situation is improved significantly with the 'low-write' version.

I can't tell you offhand what the storage requirements are, but when Trystan was developing the databases, he did publish the numbers. So they are out there somewhere - maybe in one of his blogs.

Rhys's picture

Re: emonBase local emonCMS database and logging

Hi Robert,

Thanks for the reply.
For the storage requirements I found this blog entry (hadn't thought of searching the blogs) http://openenergymonitor.blogspot.co.za/2013/05/the-current-emoncms-feed...

Based on that I'd probably need a little under 1Gb to store 10 years of data...
I'll do some more forum searching and decide when my kit arrives.
I wonder if that usb-hdd script that's been mentioned could create a copy of a running USB stick to another USB stick, as a backup that you can do every so often, that you can then just change out if the primary one fails???

Comment viewing options

Select your preferred way to display the comments and click "Save settings" to activate your changes.