Skip to Content
Skip Breadcrumb

Customer of openshift/kubernetes which uses NFS as there persistent volume type want sometimes to change the mount options.

update 19.08.2017
In the upstream project kubernetes is the annotation mount-options since 1.7 available.
Since Openshift version 3.6 is this annotations also available Mount Options.

This entry in the RedHat knowledgeable base describes How to specify client version of NFS for persistent volume how you can configure the file /etc/nfsmount.conf to setup your own mount paramters for NFS mounts.

Which options are available is described here or you can just take a look into the /etc/nfsmount.conf file.

On every node, which will run pods with the NFS pv, must have the same /etc/nfsmount.conf.

The easiest way to do this is via ansible’s copy module after the /etc/nfsmount.conf is configured on the master.

$ ansible -m copy \
    -a 'src=/etc/nfsmount.conf dest=/etc/nfsmount.conf backup=yes' \
    nodes

You can contact me for any further questions and orders