Issue #18296 has been updated by Paul Hinze. Status changed from Unreviewed to Rejected Assignee set to Paul Hinze
I set up an NFS server and used your exact code and I too could not reproduce this issue. I was using Ubuntu 12.04 systems and the latest version of puppet. I'm going to tentatively set this to Rejected since mount seems to be behaving properly and we have two people confirming this. Will, if you want to provide more specific information about your system to help us reproduce, I'd be happy to reopen and investigate further. Until then, let's call this closed. ---------------------------------------- Bug #18296: Puppet only passes location to 'mount', not device and location, so bind mounts do not work correctly after the inital run. https://projects.puppetlabs.com/issues/18296#change-94710 * Author: Will Marler * Status: Rejected * Priority: Normal * Assignee: Paul Hinze * Category: mount * Target version: * Affected Puppet version: * Keywords: bind, mount, * Branch: ---------------------------------------- Consider the following manifest: <pre> $server = nas.test.com $path = nas_export $fstype = nfs #(In our real-world issue it's gluster, but any fstype works to reproduce) mount {'/mnt/test': ensure => 'mounted', device => "$server:$path", fstype => $fstype, options => 'defaults', atboot => true, require => File['/mnt/test']; } } mount{ '/var/mnt': ensure => 'mounted', device => "/mnt/test", fstype => 'none', options => 'rw,bind', atboot => 'true', require => [Mount['/mnt/test'],File['/var/mnt']]; } </pre> When run on a clean system, it correctly creates & executes the mounts and the entries in /etc/fstab. This is good. However, if one unmounts /mnt/test and /var/mnt, and re-runs puppet, the NFS mount /mnt/test is not re-mounted. Only the bind mount /var/mnt to /mnt/test is re-mounted. Puppet throws no errors. This occurs because puppet calls the mount command in the above scenario as "debug: Puppet::Type::Mount::ProviderParsed: Executing '/bin/mount -o defaults /mnt/test'". mount interprets "/mnt/test" as the *device* to be mounted and performs the bind mount (which works, so no error is thrown), rather than as the *location* which should be attached to nas.test.com:nfs_export. This is probably "mount" default behavior. A solution would be for puppet to call the "mount -o <options> <device> <mount point>" removing the ambiguity of "/mnt/test". -- You have received this notification because you have either subscribed to it, or are involved in it. To change your notification preferences, please click here: http://projects.puppetlabs.com/my/account -- You received this message because you are subscribed to the Google Groups "Puppet Bugs" group. To unsubscribe from this group and stop receiving emails from it, send an email to [email protected]. To post to this group, send email to [email protected]. Visit this group at http://groups.google.com/group/puppet-bugs. For more options, visit https://groups.google.com/groups/opt_out.
