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

puppet_agent : move *.dll during an upgrade instead of terminating puppet

    XMLWordPrintable

Details

    • Improvement
    • Status: Closed
    • Normal
    • Resolution: Won't Fix
    • None
    • None
    • Windows
    • None
    • Windows!

    • Needs Assessment

    Description

      An upgrade on Windows executes a batch script to execute msiexec, allowing us to terminate the puppet process and unlock and upgrade the DLL files the process holds open. MODULES-4207 moved the puppetres.dll prior to an upgrade to avoid a similar locked file issue.

      Could we move all of the DLL files, allowing us to upgrade Windows agents without having to terminate the puppet process, and instead send a signal to the puppet process at the end of the run, matching the behavior of an upgrade on Linux?

      https://github.com/puppetlabs/puppetlabs-puppet_agent/blob/master/templates/install_puppet.bat.erb#L43

      SET PUPPETBIN=<%= @env_windows_installdir %>\puppet\bin
      PUSHD %PUPPETBIN%
      REN *.DLL *-%RANDOM%.DLL
      DEL /Q *.DLL
      POPD
      

      Terminating a puppet run always results in an exit code of 0. This obscures the result of the other changes executed by the run prior to the termination and upgrade. At least one customer depends on the exit code being informative during their provisioning process, during which a puppet run often includes both an upgrade to the puppet agent and other changes.

      Attachments

        Issue Links

          Activity

            People

              sean.mcdonald Sean McDonald
              tom.kishel Thomas Kishel
              Votes:
              0 Vote for this issue
              Watchers:
              3 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved:

                Zendesk Support