Puppet-reports are using a lot of diskspace in:
/var/lib/puppet/reports
/var/lib/mysql
The assumption is that it stores all reports in the MySQL database, because both paths are about the same size. The resource_statuses table consist of rows that each represent a line in a reports file.
- Can one safely remove the reports in /var/lib/puppet/reports after Puppet-dashboard or PuppetDB has processed them?
- What is the best practice for handling reports?
- Is there a way to make Puppet-dashboard automatically delete the yaml report files after processing them?
Yes you can delete them and I recommend it as well. The docs for Puppet dashboard aren't very opinionated on the ongoing maintenance of the dashboard, but it does need maintenance. I recommend a cron that delete reports in the database after a few days, a second one to remove any orphaned records, and a third to delete processed reports. Mine looks like this:
You can tweak the times to what works best for your system. I don't believe the delayed_job contains any functionality to delete processed reports, but you might be able to add it to code.