sqlite3 Vacuum

53 views
Skip to first unread message

John Schultz

unread,
Dec 15, 2019, 12:04:03 PM12/15/19
to weewx-user
Is it possible to get sqlite "vacuum" as a user selected with a "yes" or "no" in weewx.conf. Intervals could be hourly, daily, weekly etc. The database grows rapidly when the archive interval is set low (1 minute) on a Vantage device. Vacuum helps with this. I could set up a cron job to handle this but then this gets outside the realm of wee.

Thomas Keffer

unread,
Dec 15, 2019, 2:19:57 PM12/15/19
to weewx-user
I'm surprised it would make much of a difference. Vacuum is useful when your data goes through a lot of insertions and deletions, causing the disk file to get very fragmented. See the sqlite documentation for details. WeeWX doesn't work like this: it just adds data, never deletes.

Some of the extensions, "forecast" in particular, delete old data. For them, it might make sense.

If you're still intent on adding vacuum, then you should use a cron job. Make sure you stop WeeWX first.

-tk

On Sun, Dec 15, 2019 at 10:04 AM John Schultz <schul...@gmail.com> wrote:
Is it possible to get sqlite "vacuum" as a user selected with a "yes" or "no" in weewx.conf. Intervals could be hourly, daily, weekly etc. The database grows rapidly when the archive interval is set low (1 minute) on a Vantage device. Vacuum helps with this. I could set up a cron job to handle this but then this gets outside the realm of wee.

--
You received this message because you are subscribed to the Google Groups "weewx-user" group.
To unsubscribe from this group and stop receiving emails from it, send an email to weewx-user+...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/weewx-user/a003dd09-43c4-469b-87f9-ccf7345f2973%40googlegroups.com.

John Schultz

unread,
Dec 16, 2019, 6:45:11 AM12/16/19
to weewx...@googlegroups.com
Thanks for the feedback Tom


You received this message because you are subscribed to a topic in the Google Groups "weewx-user" group.
To unsubscribe from this topic, visit https://groups.google.com/d/topic/weewx-user/0RXRjaRmtjs/unsubscribe.
To unsubscribe from this group and all its topics, send an email to weewx-user+...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/weewx-user/CAPq0zEDACC8U3fOMGpTRRVN6Btp0MYxW6q-NAWiFkG%2B1U-QNkw%40mail.gmail.com.
Reply all
Reply to author
Forward
0 new messages