title: Read-only file system error in Kubernetes
body: <p>I am getting an error while adding NFS in the Kubernetes cluster. I was able to mount the NFS but not able to add a file or directory in the mount location. </p>
  
  <p>This is my yaml file</p>
  
  <pre><code>kind: Pod
  apiVersion: v1
  metadata:
    name: pod-using-nfs
  spec:
    volumes:
      - name: nfs-volume
        nfs:
          server: 10.01.26.81
          path: /nfs_data/nfs_share_home_test/testuser
    containers:
      - name: app
        image: alpine
        volumeMounts:
          - name: nfs-volume
            mountPath: /home/kube/testuser
  </code></pre>
  
  <p>Then I ran the following commands for building the pod</p>
  
  <pre><code>kubectl apply -f session.yaml
  kubectl exec -it pod-using-nfs sh
  </code></pre>
  
  <p>After I exec to the pod,</p>
  
  <pre><code>/ # cd home/kube/testuser/
  /home/kube/testuser# touch hello
  touch: hello: Read-only file system
  </code></pre>
  
  <p>Expected output is</p>
  
  <pre><code>/ # cd home/kube/testuser/
  /home/kube/testuser# touch hello
  /home/kube/testuser# ls
  hello
  </code></pre>
  
  <p>Should I need to add any securityContext to the yaml for fixing this?
  Any help would be appreciated!</p>