[Pkg-puppet-devel] Bug#1078911: missing reports cleanup job
Antoine Beaupré
anarcat at debian.org
Sat Aug 17 16:38:35 BST 2024
On 2024-08-17 11:35:52, Antoine Beaupré wrote:
> Actually, my investigation wasn't quite correct there: I was looking in
> the "old" /var/lib/puppet/reports directory, which is now
> /var/lib/puppetserver/reports directory...
>
> So we should do this:
>
> 1. make sure we either move /var/lib/puppet/reports to
> /var/lib/puppetserver/reports on upgrade (or destroy the former when
> puppet-master is purged)
>
> 2. add a cron job to automatically cleanup
> /var/lib/puppetserver/reports
>
> The results from the three commands where still similar, but yielded a
> *lot* more reports, 93080 to be exact. The cleanup ended up releasing
> more than 40GB of disk space, with 3GB remaining.
And for now I have added this cron job:
root at marcos:/etc/cron.daily# cat puppetserver
#!/bin/sh
if [ -e /var/lib/puppet/reports ] ; then
find /var/lib/puppet/reports -type f -ctime +30 -delete
find /var/lib/puppet/reports -type d -empty -delete
fi
--
You can't get to the moon by climbing successively taller trees.
- Akin's Laws of Spacecraft Design
More information about the Pkg-puppet-devel
mailing list