Past Logs

So past logs seems to be a little glitchy for me. If I select all devices I see this.

Seems to be clipping things from individual devices as well - Here is a screen shot of the logs from nest.

and vlcThing

Opened Past Logs this morning to find that the oldest entry was only an hour old. Does it purge the logs at night?

It's a rolling buffer of past events, not a permanent history.

I understand but it's strange that the buffer was less than 1 hour old.

If you have one line that is a lot of data that would be that same as hundreds of lines with very little data.

Its loading up to 256k of logs. Could be a few lines with a lot of data or up to 800+ lines with very little data.

@patrick @bravenel

Is there any idea why my l
Past logs looks so strange in the OP of this thread?

Also, this should help app and driver developers cut down on the log spam. Unnecessary excessive logging slows your system down. Also, logging giant objects like state or other things like images will slow down while the system writes this stuff to logs. BTW, past logs doesn't have any additional performance impact, we just now read the user logs on load of this page.

Hopefully devs can now see this and provide options to turn on logs and have them turn off after x minutes, etc. Or at least cut down on excessive logging.

Just my two cents. I'm loving past logs as I seem to always forget to open live logging until just after I need it.

3 Likes

Yes, we identified an issue with logging using special characters, like tab and returns in logs. This will be addressed in an update shortly.

@patrick

so my current logs now look like this... is this the expected behavior?

Yes, that is what is being returned and is now formatting it as it is set with returns, tabs, etc.

Just for comparison, It looks like my Past Logs are storing approx 30 minutes.
I copy/pasted the Past Logs into Notepad++ and it equated to 1903 lines for me.

Environment:
I have 76 Devices.
I have 15 apps running (and some of those have child apps such as Hubitat Dashboard has 6 child apps, Simple lighting has 10 child apps, Rule Machine has 38 child apps)

I've been modifying apps/drivers to lower the logging. Maybe log.debug should have different levels that is control centrally. That would allow you to turn down/up logging as needed instead of having to modify each app/driver manually. It's a bit fragmented now on how logging is done.

Just a thought...

I just checked my production hub at my house and my earliest log is from 6:36am this morning and my last log is from 4:36pm. 10 hours of logging on a system with 120 devices, including sonos, hue and many automation apps running. This is 2,708 lines of logs.

Granted, most are just informational, like hue "Syncing with Bridge..." which we don't need to be logging out and will address this in the future releases.

Appreciate the feedback and we will look at potentially tweaking these things down the road.

1 Like

It's easy to include a preference setting, then timeout the debug logs, that's how we do our internal drivers. You can see how this is done in our public code.
A global setting, whilst doable is still going to give you way too much logging, as you typically only need to debug one thing at a time.

One just needs to tighten up their code a bit.

I have 4-1/2 hours of logs, 220+ devices, 100+ automations, plus development work on same hub.

1 Like

maybe there is something wrong with my setup. Each time i go look at my past logs, it has only 1/2 hr worth of data. Here are all the devices that is in the past log.

One device should report every minute but all i get is 1/2 hour worth.

Any idea if it would be possible to plug a USB storage drive into the hub and direct logs to write to that for a longer history?

No, this is not possible.

@bravenel

Would it be possible to add into both the logs and past logs the ability to organize the logs based on alphabetical order or execution order? I find a lot of times in the past log scenario I am looking for what happened with a specific device or rule and it is not as easy to find in the execution listing.

1 Like

We have some things in the works to make this better.

3 Likes