Details
-
Bug
-
Status: Resolved
-
Normal
-
Resolution: Fixed
-
PUP 6.13.0
-
None
-
Coremunity
-
Platform Core KANBAN
-
Needs Assessment
-
Bug Fix
-
The puppet_gem provider can now uninstall a gem during an agent run
-
Needs Assessment
Description
Puppet Version: 6.13.0
Puppet Server Version: 6.8.0
OS Name/Version: RHEL 7
Gems can be installed into the puppet agent's ruby environment for use in providers etc.
When they're no longer required, it should be possible to remove them.
eg.
package { 'redis_gem':
|
ensure => absent,
|
name => 'redis',
|
provider => 'puppet_gem',
|
}
|
Whilst the puppet_gem provider does successfully uninstall the gem, subsequent File/Concat resources fail. (I imagine other stuff might fail too, but this was the first thing I hit)
Info: Applying configuration version 'puppet6server1-redis_gem_test-79e063b8d35'
|
Notice: /Stage[main]/Profile::Redis_keepalived/Package[redis gem]/ensure: removed (corrective)
|
Notice: /Stage[main]/Keepalived::Config/Concat[/etc/keepalived/keepalived.conf]/File[/etc/keepalived/keepalived.conf]/content:
|
--- /etc/keepalived/keepalived.conf 2020-02-28 11:27:08.821195162 +0000
|
+++ /tmp/puppet-file20200228-21277-1uxs10h 2020-02-28 11:28:30.905963796 +0000
|
@@ -1,4 +1,4 @@
|
-## Managed by Puppet
|
+# Managed by Puppet
|
vrrp_script check_redis {
|
script "/usr/libexec/keepalived/check_redis.sh"
|
interval 2
|
|
Info: Computing checksum on file /etc/keepalived/keepalived.conf
|
Error: Could not back up /etc/keepalived/keepalived.conf: pid: 21277 nil spec! included in [#<Gem::StubSpecifi...
|
--- SNIP --- (The array printed is ~150KB long, so I've not included it here and continue with the stack trace)
|
/opt/puppetlabs/puppet/lib/ruby/2.5.0/rubygems/specification.rb:743:in `_all'
|
/opt/puppetlabs/puppet/lib/ruby/2.5.0/rubygems/specification.rb:1153:in `latest_specs'
|
/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/util/rubygems.rb:44:in `directories'
|
/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/util/autoload.rb:142:in `gem_directories'
|
/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/util/autoload.rb:172:in `search_directories'
|
/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/util/autoload.rb:98:in `get_file'
|
/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/util/autoload.rb:62:in `load_file'
|
/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/util/autoload.rb:201:in `load'
|
/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/util/instance_loader.rb:51:in `loaded_instance'
|
/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/indirector/terminus.rb:112:in `terminus_class'
|
/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/indirector/indirection.rb:366:in `make_terminus'
|
/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/indirector/indirection.rb:140:in `terminus'
|
/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/indirector/file_bucket_file/selector.rb:16:in `get_terminus'
|
/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/indirector/file_bucket_file/selector.rb:20:in `head'
|
/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/indirector/indirection.rb:260:in `head'
|
/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/file_bucket/dipper.rb:48:in `backup'
|
/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/util/backups.rb:82:in `backup_file_with_filebucket'
|
/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/util/backups.rb:28:in `perform_backup_with_bucket'
|
/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/util/backups.rb:15:in `perform_backup'
|
/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/type/file.rb:1024:in `backup_existing'
|
/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/type/file.rb:761:in `remove_existing'
|
/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/type/file.rb:888:in `write'
|
/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/type/file/data_sync.rb:93:in `contents_sync'
|
/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/type/file/content.rb:136:in `sync'
|
/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/transaction/resource_harness.rb:241:in `sync'
|
/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/transaction/resource_harness.rb:136:in `sync_if_needed'
|
/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/transaction/resource_harness.rb:90:in `block in perform_changes'
|
/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/transaction/resource_harness.rb:89:in `each'
|
/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/transaction/resource_harness.rb:89:in `perform_changes'
|
/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/transaction/resource_harness.rb:21:in `evaluate'
|
/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/transaction.rb:267:in `apply'
|
/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/transaction.rb:287:in `eval_resource'
|
/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/transaction.rb:191:in `call'
|
/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/transaction.rb:191:in `block (2 levels) in evaluate'
|
/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/util.rb:521:in `block in thinmark'
|
/opt/puppetlabs/puppet/lib/ruby/2.5.0/benchmark.rb:308:in `realtime'
|
/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/util.rb:520:in `thinmark'
|
/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/transaction.rb:191:in `block in evaluate'
|
/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/graph/relationship_graph.rb:122:in `traverse'
|
/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/transaction.rb:178:in `evaluate'
|
/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/resource/catalog.rb:240:in `block (2 levels) in apply'
|
/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/util.rb:521:in `block in thinmark'
|
/opt/puppetlabs/puppet/lib/ruby/2.5.0/benchmark.rb:308:in `realtime'
|
/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/util.rb:520:in `thinmark'
|
/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/resource/catalog.rb:239:in `block in apply'
|
/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/util/log.rb:161:in `with_destination'
|
/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/transaction/report.rb:146:in `as_logging_destination'
|
/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/resource/catalog.rb:238:in `apply'
|
/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/configurer.rb:187:in `block (2 levels) in apply_catalog'
|
/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/util.rb:521:in `block in thinmark'
|
/opt/puppetlabs/puppet/lib/ruby/2.5.0/benchmark.rb:308:in `realtime'
|
/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/util.rb:520:in `thinmark'
|
/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/configurer.rb:186:in `block in apply_catalog'
|
/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/util.rb:233:in `block in benchmark'
|
/opt/puppetlabs/puppet/lib/ruby/2.5.0/benchmark.rb:308:in `realtime'
|
/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/util.rb:232:in `benchmark'
|
/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/configurer.rb:185:in `apply_catalog'
|
/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/configurer.rb:394:in `run_internal'
|
/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/configurer.rb:235:in `block in run'
|
/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/context.rb:62:in `override'
|
/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet.rb:289:in `override'
|
/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/configurer.rb:212:in `run'
|
/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/agent.rb:59:in `block (5 levels) in run'
|
/opt/puppetlabs/puppet/lib/ruby/2.5.0/timeout.rb:93:in `block in timeout'
|
/opt/puppetlabs/puppet/lib/ruby/2.5.0/timeout.rb:103:in `timeout'
|
/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/agent.rb:58:in `block (4 levels) in run'
|
/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/agent/locker.rb:21:in `lock'
|
/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/agent.rb:52:in `block (3 levels) in run'
|
/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/agent.rb:130:in `with_client'
|
/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/agent.rb:49:in `block (2 levels) in run'
|
/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/agent.rb:87:in `run_in_fork'
|
/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/agent.rb:48:in `block in run'
|
/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/application.rb:179:in `controlled_run'
|
/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/agent.rb:46:in `run'
|
/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/application/agent.rb:410:in `onetime'
|
/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/application/agent.rb:370:in `block in run_command'
|
/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/context.rb:62:in `override'
|
/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet.rb:289:in `override'
|
/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/application/agent.rb:368:in `run_command'
|
/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/application.rb:382:in `block in run'
|
/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/util.rb:710:in `exit_on_fail'
|
/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/application.rb:382:in `run'
|
/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/util/command_line.rb:143:in `run'
|
/opt/puppetlabs/puppet/lib/ruby/vendor_ruby/puppet/util/command_line.rb:77:in `execute'
|
/opt/puppetlabs/puppet/bin/puppet:5:in `<main>'
|