https://voxpupuli.org/ logo
Join Slack
Powered by
# puppet
  • d

    David K.

    10/15/2026, 5:19 PM
    It seems like an auto-vacuum job got stuck which may have been why the data grew uncontrolled until we caught it. Our Postgres DB is external to the PuppetDB application. Checking on the version now. I think the repack is needed now to hopefully reduce that DB size (I'm not a database expert so I'm trying to wrap my head around the situation)
  • d

    David K.

    10/15/2026, 5:21 PM
    Postgresql version 17.5
  • c

    Charlie Sharpsteen

    10/15/2026, 5:26 PM
    Probably not auto-vacuum, but a transaction that gets left open will block auto-vacuum and result in that sort of growth curve.
  • c

    Charlie Sharpsteen

    10/15/2026, 5:27 PM
    And yes, if auto-vaccuum doesn't run, the pile of page files on disk grows because space used by "dead" rows can't be recycled to hold new data. Only way to knock that down is repack.
  • c

    Charlie Sharpsteen

    10/15/2026, 5:34 PM
    And, I don't think Postgres vendored
    pg_repack
    . The upcoming Postgres 19 release has a native implementation of the concept as the
    REPACK
    statement.
  • c

    Charlie Sharpsteen

    10/15/2026, 5:36 PM
    Also, the 8.x releases of OpenVoxDB/PuppetDB have timeouts that help ensure transactions don't get left open for long periods of time.
  • b

    bastelfreak

    10/15/2026, 5:36 PM
    If the db still starts, you cms use the command endpoint to delete old data. You can also drop the partitioned tables for the reports
  • c

    Charlie Sharpsteen

    10/15/2026, 5:38 PM
    Manually deleting dead rows is a bit complicated. Best to let auto-vacuum take care of that. Dropping older report partitions can be a way to quickly free space if the disk is out of room and expanding it is not an option. Repack or
    VACUUM_FULL
    will require enough free space to build a copy of the live data set before dropping the old bloated tables.
  • b

    bastelfreak

    10/15/2026, 5:39 PM
    Yes
  • b

    bastelfreak

    10/15/2026, 5:39 PM
    You can start repack on individual tables. Then it requires less disk space
  • b

    bastelfreak

    10/15/2026, 5:45 PM
    Just for fun, go through https://wiki.postgresql.org/wiki/Disk_Usage to find your biggest tables/partitions. It should be partitions for reports, but you never know. Maybe you have some big binary Blobs in your facts or catalogs
  • a

    Adrian

    10/15/2026, 5:46 PM
    If you've set up the Postgres part of operational dashboards, check that.
  • a

    Adrian

    10/15/2026, 5:47 PM
    Although, it might not work with more recent versions of postgres.
  • d

    David K.

    10/15/2026, 7:23 PM
    https://voxpupuli.slack.com/archives/C07RT1PCZ5H/p1792085780622519 We are running 8.x
  • b

    bastelfreak

    10/15/2026, 7:31 PM
    Did you manage to clean stuff up?
  • c

    Charlie Sharpsteen

    10/15/2026, 7:35 PM
    If you are running 8.x, that makes it less likely to be a hung transaction. Could be a case where the DB service should have canceled something that it didn't. Or, could be a SQL query external to the DB service that got left open. Or, it could just be more data coming in. For example, reports that were previously a handful of kB or MB now coming in much larger due to a cascading failure that repeats run after run.
  • b

    bastelfreak

    10/15/2026, 7:39 PM
    Alllll the flapping resources
  • d

    Dan Mahoney

    10/15/2026, 7:46 PM
    @smortex I didn't think there WAS a released version that includes the json fixes, as stated earlier? They had to backport those fixes into a post-release version, can someone else confirm?
  • c

    Charlie Sharpsteen

    10/15/2026, 7:49 PM
    The
    openvox-agent
    8.31.0 and 9.1.0 releases that went out yesterday have compatibility fixes for
    json
    3.0.
  • b

    bastelfreak

    10/15/2026, 7:58 PM
    nods
  • s

    smortex

    10/15/2026, 8:05 PM
    Yes, github.com/OpenVoxProject/openvox/pull/721 says "This PR hasn't been released yet, judging by its merge commit." but the merge commit itself github.com/OpenVoxProject/openvox/commit/af67c41f2210… shows it is included in 8.31.0. GitHub became a pile of trash 😞.
  • d

    Dan Mahoney

    10/15/2026, 8:10 PM
    ...this is about openvox-server?
  • d

    Dan Mahoney

    10/15/2026, 8:11 PM
    for us, our agent is unaffected unless something else coincidentally pulls in the json gem
  • s

    smortex

    10/15/2026, 8:28 PM
    The server depends on the agent. Some code from the agent is executed in jruby by the server. So they are both connected. I am running my uncommitted work on my systems atm (to check if it works as expected), let me try the packages currently shipped by FreeBSD to see how broken they currently are.
  • d

    Dan Mahoney

    10/15/2026, 8:34 PM
    In our case, specifically, the agent was not the problem, it was only on the server.
  • d

    Dan Mahoney

    10/15/2026, 8:34 PM
    but only by happenstance.
  • d

    Dan Mahoney

    10/15/2026, 8:35 PM
    if we had installed the actual json gem on the client, it would broken things that way too
  • d

    Dan Mahoney

    10/15/2026, 8:42 PM
    the only fix we needed was rolling back the json gem on the server to a prior version from
    /var/cache/pkg
  • d

    Dan Mahoney

    10/15/2026, 8:43 PM
    and
    pkg lock
    ing it.
  • c

    Charlie Sharpsteen

    10/15/2026, 9:03 PM
    There were no json-specific fixes in today's 9.1.0
    openvox-server
    release. I tried to re-produce the duplicate key error yesterday, but couldn't get the server to fail when
    json
    3.1.0 was in use. If someone does have re-production steps and/or a stack trace for the error, please open an issue: github.com/OpenVoxProject/openvox-server/issues