Check the performance of Puppet Enterprise by reviewing the PuppetDB dashboard. If large facts are causing performance issues, find and disable them.
Version and installation information
PE version: All supported versions
Solution
Review HTTP metrics from the PuppetDB dashboard.
For example: example-com-facts.find
takes a long time to retrieve facts from the PuppetDB. These facts might be large enough to cause performance issues.
Check for large facts
To check for large facts, run the following query on the PuppetDB node:
runuser -u pe-postgres -- /opt/puppetlabs/server/bin/psql -d pe-puppetdb -c 'select certname, j, pg_column_size(j) from ( select jsonb_each(stable) j, id from factsets union all select jsonb_each(volatile) j, id from factsets ) a join certnames on certnames.id = a.id order by 3 desc;' >/tmp/largest_facts.txt
Disable large facts
If you have facts larger than 500 KB, improve performance by disabling them.
- Disable custom facts by removing them from your module or overriding their value
- Disable ec2 or filesystem built-in facts by blocking them using factor.conf
- Disable other built-in facts by overriding or disabling them
After disabling facts, review HTTP metrics again to see if performance improves.
How can we improve this article?
0 comments
Please sign in to leave a comment.
Related articles