On Monday, December 1, 2014 4:11:31 PM UTC-6, Clay Stuckey wrote:
>
> I wrote two manifests for RHEL systems. One removed syslog. The other 
> installed rsyslog. The syslog removal followed a tragic dependency tree 
> removing RPMs such as coreutils, rpm, yum and pam. Once the servers 
> rebooted, they were left in an unusable state. I had to boot in rescue 
> mode, manually install files to get RPM going and reinstall about 300 RPMs 
> that were removed.
>
>

And this is why you should never ensure a package 'purged' unless you're 
really, *really* sure you know what you're doing.  It's also a good 
argument for testing your configs on non-critical dev systems before 
rolling them out to production systems.

 

> Is there some way to blacklist the removal of certain critical RPMs that 
> might be found in a dependency tree?
>


The 'yum' package provider never removes any dependencies when you ensure 
'absent' (it doesn't even use 'yum' itself in that case -- it uses 'rpm' 
directly instead).  If you ensure 'purged', however, you're telling it "do 
whatever it takes to get rid of the package".  Unfortunately, 'purged' has 
somewhat different meanings to some other package providers, which is 
another reason to avoid it.

Anyway, any blacklisting would be in the province of yum, not of Puppet.  
When Puppet's 'yum' provider purges a package, it does not manually 
identify or remove dependencies; rather, it just uses "yum remove -y".  
With that said, yum supports plugins.  I don't see an available one to do 
what you want, but I'm guessing that it would be relatively straightforward 
to create one.


John

-- 
You received this message because you are subscribed to the Google Groups 
"Puppet Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to puppet-users+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/puppet-users/1b2ad7be-7e92-45ad-82dd-b5c2d9066ec8%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

Reply via email to