Can you change mount() to mount NFS with -o nolock on RedHat 6.6?


#1

I created a chef script using the mount() function. However, I need to have Chef mount the equivalent:
mount HOST:DIR MOUNT -o nolock
This prevents a number of errors in the application IBM WAS 8.5.5.5 FixPack 5. Is there a way to override the parameters sent to include -o nolock? Perhaps a way to issue the raw command in worse case?

Here’s the current call that causes the application installation to blow up later down the road.

mount “/mnt/software” do
device dev
fstype "nfs"
action :mount
end


#2

OMG. Nevermind. I played around with the “options” option and got it. The doc was here:
https://docs.chef.io/resource_mount.html

The solution ended up being:

mount “/mnt/software” do
device dev
fstype "nfs"
options "nolock"
action :mount
end