Log file location for accessing on windows - offline

All,

I currently am using an rpi with openhab2 and am writing my z-wave device DEBUG log to the default /var/log/openhab2 folder. I can access it just fine via the network on my windows machine.

My specific application will require up to 20x rpi with various zwave sensors operating offline. I’d ideally like to just pull the SD card from the rpi and copy the log off to my computer.

  1. I could use Ext2explore but are there easier ways? Storing the file in /boot as its readable by windows natively?

  2. is there a way to only record the OPEN/CLOSE or ON/OFF event rather then everything under debug? DEFAULT doesn’t seem to do it.

Appreciate you taking the time to read this.
-Mike

  1. That partition is very small. You will fill it up pretty quickly if you move the OH logs there.

  2. events.log only stores the state changes of your Items. And you don’t have to run anything in debug. In info (the default logging level) the amount of other logging is minimal. But if you need these logs for debugging errors you will want the openhab.log file in addition to the events.log.

If you have 20x RPis and you are trying to managing the logs by physically plugging in SD cards into a Windows PC I’m going to say you are doing it wrong. I don’t know what requirement is driving the “offline” requirement (plus it isn’t clear to me what exactly you can accomplish with all of these devices offline). But I would really really consider if there is anyway you can make them semi-offline so they “phone home” the logs periodically or something that would probably be well worth your time. Then you can set up rsyslog, splunk, ELK, or something to automate this stuff.

If you are going to be pulling these logs frequently, x20, you are talking about a whole lot of time spent doing “donkey work” copying log files around. You can afford to spend a whole lot of time coming up with a way to make the Pis centralize their logging somehow, even if it is periodically.

Rich,

thanks for taking the time to reply and I agree with your overall comments but for this application the rpis will not be able to access the internet. I can however, make them all access points so someone with a laptop could connect wirelessly and not have to pull out the card to at least same some time.

They don’t have to access the internet, they just all have to access a designated central RPi or some other type of server whose job it is to agregate the logs. This is a case where the extra time and equipment would probably be well worth the effort.