Uploaded image for project: 'Puppet'
  1. Puppet
  2. PUP-7216

hiera_hash doesn't use deeper merge



    • Bug
    • Status: Closed
    • Critical
    • Resolution: Fixed
    • PUP 4.9.2
    • PUP 4.9.3
    • Language
    • Ubuntu 14.04 LTS on all Servers

    • Puppet Developer Experience
    • 1
    • PDE 2017-02-22, PDE 2017-03-08
    • Bug Fix
    • A regression in calls to the hiera_xxx family of functions made them not honour default merge behavior defined in hiera.yaml.
    • Automate
    • high risk; coverage in unit, but regression. acceptance me


      Apache modules which shall be used are defined with hiera files.

      Modules which shall be used by all webservers are defined in the file Ubuntu.yaml.
      In addition modules which are in the individual server configs (hostxyz.yaml) shall be used.

      Until upgrade to 4.9.x everything worked fine.
      Since the upgrade the infomation from Ubuntu.yaml gets ignored if modules in a node.yaml are defined.
      This causes that puppet removes the default modules and the webserver stops working.

      I could confirm, that deeper merge is basically working, but since the upgrade it seems it cannot handle this structured data.

                - mpm_prefork
                - php
                - ssl

      If no modules are defined in nodexyz.yaml I get in this basic demonstrator class (init.pp):

      sudo puppet agent -t -v
      Notice: Apache mod: auth_kerb
      Notice: /Stage[main]/Testmodule/Notify[Apache mod: auth_kerb]/message: defined 'message' as 'Apache mod: auth_kerb'
      Notice: Apache mod: authnz_ldap
      Notice: /Stage[main]/Testmodule/Notify[Apache mod: authnz_ldap]/message: defined 'message' as 'Apache mod: authnz_ldap'
      Notice: Apache mod: cgid
      Notice: /Stage[main]/Testmodule/Notify[Apache mod: cgid]/message: defined 'message' as 'Apache mod: cgid'
      Notice: Apache mod: status
      Notice: /Stage[main]/Testmodule/Notify[Apache mod: status]/message: defined 'message' as 'Apache mod: status'
      Notice: Applied catalog in 3.65 seconds

      As soon as I enable a module in nodexyz.yaml I get:

      Notice: Apache mod: mpm_prefork
      Notice: /Stage[main]/Testmodule/Notify[Apache mod: mpm_prefork]/message: defined 'message' as 'Apache mod: mpm_prefork'
      Notice: Apache mod: php
      Notice: /Stage[main]/Testmodule/Notify[Apache mod: php]/message: defined 'message' as 'Apache mod: php'
      Notice: Apache mod: ssl
      Notice: /Stage[main]/Testmodule/Notify[Apache mod: ssl]/message: defined 'message' as 'Apache mod: ssl'
      Notice: Applied catalog in 3.46 seconds


        1. hiera.yaml
          0.4 kB
          Christopher Siedler
        2. hostxzy.yaml
          0.2 kB
          Christopher Siedler
        3. init.pp
          0.4 kB
          Christopher Siedler
        4. Ubuntu.yaml
          0.9 kB
          Christopher Siedler

        Issue Links



              Unassigned Unassigned
              christopher.siedler@hoerbiger.com Christopher Siedler
              1 Vote for this issue
              11 Start watching this issue



                Zendesk Support