Description of problem: Excessive error logging due to obsolete permission in database. (I think!) Version-Release number of selected component (if applicable): 6.11.1 How reproducible: Always Steps to Reproduce: 1. Upgrade systems to 6.11.0 2. Remove puppet 3. Actual results: Excessive logging due to: 2022-07-31T12:00:12 [W|app|] unknown class ForemanPuppet::HostClass, ignoring 2022-07-31T12:00:12 [I|app|] Backtrace for 'unknown class ForemanPuppet::HostClass, ignoring' error (NameError): uninitialized constant ForemanPuppet | /usr/share/gems/gems/foreman_hooks-0.3.17/lib/foreman_hooks/as_dependencies_hook.rb:4:in `load_missing_constant' Expected results: No Errors Additional info:
JFYI, For a Sat 6.11.3 or 6.11.4, Apart from the Tracebacks related to "ForemanPuppet::HostClass" resource, I get to see the exact same tracebacks for the following resource types as well, flooding the logs. # cat /var/log/foreman/production.log | egrep 'ForemanPuppet::' | grep 'ignoring$' | awk '{ print $5 }' | sort | uniq -c 837 ForemanPuppet::ConfigGroup, 1116 ForemanPuppet::Environment, 1116 ForemanPuppet::Puppetclass, 1116 ForemanPuppet::PuppetclassLookupKey, So I ended up clearing these resources as well. using the following rake sequence ( and by changing the resource type ) cat << EOF | foreman-rake console perms = Permission.where(:resource_type => 'ForemanPuppet::HostClass') perms.each { |perm| perm.filters.destroy_all } perms.destroy_all EOF And finally a restart of services. Since we provide the option to run the "satellite-maintain plugin purge-puppet" command without "--remove-all-data" , It needs to be clean and there should be no huge tracebacks related to that many resources in the production log filling it up completely.
Adding to Sayan's update, one also has to disable puppet after running "satellite-maintain plugin purge-puppet --remove-all-data": systemctl disable --now puppet Otherwise messages on sat and capsules will be filled with: Dec 14 11:22:18 puppet-agent[1301]: Failed to open TCP connection to puppet:8140 (getaddrinfo: Name or service not known) Dec 14 11:22:18 puppet-agent[1301]: No more routes to ca Needs more QA..