Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Output: mount.nfs: requested NFS version or transport protocol is not supported

I am trying out the Kubernetes NFS volume claim in a replication controller example [1].

I have setup the NFS server, PV and PVC. And my replication controller looks like this

apiVersion: v1
kind: ReplicationController
metadata:
  name: node-manager
  labels:
    name: node-manager
spec:
  replicas: 1
  selector:
    name: node-manager
  template:
    metadata:
      labels:
        name: node-manager
    spec:
      containers:
      -
        name: node-manager
        image: org/node-manager-1.0.0:1.0.0
        ports:
        -
          containerPort: 9763
          protocol: "TCP"
        -
          containerPort: 9443
          protocol: "TCP"
        volumeMounts:
          - name: nfs
            mountPath: "/mnt/data"
      volumes:
      - name: nfs
        persistentVolumeClaim:
          claimName: nfs

When I try to deploy the Replication Controller, the container is in the ContainerCreating status and I can see the following error in the journal of the minion

Feb 26 11:39:41 node-01 kubelet[1529]: Mounting arguments: 172.17.8.102:/ /var/lib/kubelet/pods/0e66affa-dc79-11e5-89b3-080027f84891/volumes/kubernetes.io~nfs/nfs nfs []
Feb 26 11:39:41 node-01 kubelet[1529]: Output: mount.nfs: requested NFS version or transport protocol is not supported
Feb 26 11:39:41 node-01 kubelet[1529]: E0226 11:39:41.908756    1529 kubelet.go:1383] Unable to mount volumes for pod "node-manager-eemi2_default": exit status 32; skipping pod
Feb 26 11:39:41 node-01 kubelet[1529]: E0226 11:39:41.923297    1529 pod_workers.go:112] Error syncing pod 0e66affa-dc79-11e5-89b3-080027f84891, skipping: exit status 32
Feb 26 11:39:51 node-01 kubelet[1529]: E0226 11:39:51.904931    1529 mount_linux.go:103] Mount failed: exit status 32

Used [2] Kubernetes-cluster-vagrant-cluster to setup my Kubernetes cluster.

my minion details:

core@node-01 ~ $ cat /etc/lsb-release
DISTRIB_ID=CoreOS
DISTRIB_RELEASE=969.0.0
DISTRIB_CODENAME="Coeur Rouge"
DISTRIB_DESCRIPTION="CoreOS 969.0.0 (Coeur Rouge)"

[1] - https://github.com/kubernetes/kubernetes/tree/master/examples/nfs

[2] - https://github.com/pires/kubernetes-vagrant-coreos-cluster

like image 895
Vishanth Avatar asked Feb 26 '16 11:02

Vishanth


People also ask

What ports are needed for NFS?

NFS uses port 2049. NFSv3 and NFSv2 use the portmapper service on TCP or UDP port 111.


1 Answers

I had the same problem then realized that nfs-server.service status is disabled. After activating, the problem has been solved.

like image 124
flyingcircus-bot Avatar answered Oct 04 '22 13:10

flyingcircus-bot