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

Autorequire in mount.rb causes dependency cycle with LVM module

    Details

    • Type: Bug
    • Status: Closed
    • Priority: Normal
    • Resolution: Duplicate
    • Affects Version/s: None
    • Fix Version/s: None
    • Component/s: None
    • Labels:
      None
    • Template:

      Description

      Before the change to the mount provider that was committed here: https://github.com/puppetlabs/puppet/commit/747dae17189c9eb1321196642fcdb91b32d3b09b#diff-6cb22546390c0207d2cab18ad531a34b

      You could describe an LVM resource like this:

      file { '/apps':
      ensure => directory,
      }
       
      lvm::logical_volume { 'apps':
      volume_group => 'vg0',
      size => '1G',
      fs_type => 'xfs',
      options => 'relatime',
      before => File['/apps'],
      }
      

      When using a modern version that includes the commit above, this creates a dependency cycle and it is necessary to workaround it by overriding the auto-dependency:

      file { '/apps': 
      ensure => directory, 
      } 
      lvm::logical_volume { 'apps':
      volume_group => 'vg0',
      size => '1G',
      fs_type => 'xfs',
      options => 'relatime',
      } 
      Mount['/apps'] -> File['/apps']
      

        Attachments

          Issue Links

            Activity

              jsd-sla-details-panel

                People

                • Assignee:
                  Unassigned
                  Reporter:
                  erik.hansen Erik Hansen
                • Votes:
                  0 Vote for this issue
                  Watchers:
                  3 Start watching this issue

                  Dates

                  • Created:
                    Updated:
                    Resolved:

                    Zendesk Support