Uploaded image for project: 'Puppet Agent'
  1. Puppet Agent
  2. PA-789

puppet-agent packaging on EL 6 (and SLES 11) calls "puppet apply" in RPM post-scripts


    • Type: Bug
    • Status: Closed
    • Priority: Normal
    • Resolution: Duplicate
    • Affects Version/s: puppet-agent 1.8.2, puppet-agent 1.10.5, puppet-agent 1.10.9
    • Fix Version/s: None
    • Component/s: Packaging
    • Labels:
    • Template:
    • Team:
      Platform OS
    • QA Risk Assessment:
      Needs Assessment


      puppet-agent's el6 packages (all versions I have readily available, from 1.5.3 to 1.8.1, seem to work this way) call "puppet apply" in the RPM post-scriptlets. "Puppet apply" also resolves facts (as it must), and we have a fact that called "yum versionlock" without a timeout, so when we upgraded our agents via the puppetlabs/puppet_agent module (which upgrades packages via yum), the yum calls would deadlock. Yum versionlock would block on the parent yum installing the package, and the parent yum installing the package could never finish because the "puppet apply"s in the post scripts couldn't finish their fact gathering phase.

      We eventually put in a workaround in our fact, to call "yum versionlock" with a timeout. But we only discovered what was actually causing the problem by stracing a few generations of processes. It might be a useful enhancement to avoid running "puppet apply" in the post scripts, or at least make it clear that puppet apply will run during post, and to be aware of the possibility of yum deadlocks in case you're running facts that call yum themselves. (I also notice that the SLES 11 packaging works the same way, but the approximate equivalent "zypper locks" command does not block zypper the same way that "yum versionlock" blocks yum upgrade.




            • Assignee:
              mjackson Martin Jackson
            • Votes:
              3 Vote for this issue
              9 Start watching this issue


              • Created:

                Zendesk Support