Mount Resource Fstab Updates


#1

Hey All,

I recently have been testing the mount resource for managing static NFS file shares in Linux. I have noticed that when I change the “options” attribute for my resource definition in a recipe and the mount resource executes during a chef-client run, the fstab entry for that particular mount is not updated with the new mount options. Just curious if this is intentional? And if not why is the :enable action for the mount resource not adding a newly defined fstab entry?

My use case is that I want to manage the /etc/fstab’s custom NFS mount entries without having to template every fstab entry across all nodes and also to automatically update fstab entry mount options if they need to be redefined.

Thanks,
Shane Sofos


#2

On Tue, May 7, 2013 at 7:06 AM, Shane Sofos ssofos@fb.com wrote:

Just curious if this is intentional? And
if not why is the :enable action for the mount resource not adding a newly
defined fstab entry?

We were bitten by this over the weekend as well (although using CIFS).
We have hacked it together by using the /etc/fstab.d/ dir under ubuntu
combined with a idempotent bash resource to fix this in our very
limited scenario. (Essentially we chained notifies off the template
that did a remount).

Ugly and hacky but a good quick fix until it gets fixed upstream :wink:


Cheers,

Peter Donald