<p>I'm trying to get persistent local storage working, i've created the following PV,PVC,Deployment. But the pod gets stuck in pending with the error:</p>
<pre><code>Type     Reason            Age                 From               Message
  ----     ------            ----                ----               -------
  Warning  FailedScheduling  63s (x7 over 8m8s)  default-scheduler  0/3 nodes are available: 1 node(s) had taint {node-role.kubernetes.io/master: }, that the pod didn't tolerate, 2 node(s) didn't find available persistent volumes to bind.
</code></pre>
<pre><code>apiVersion: storage.k8s.io/v1
kind: StorageClass
metadata:
  name: standard
provisioner: kubernetes.io/no-provisioner
volumeBindingMode: WaitForFirstConsumer
---
apiVersion: v1
kind: PersistentVolume
metadata:
  name: plex-config-volume
spec:
  capacity:
    storage: 400Gi
  volumeMode: Filesystem
  accessModes:
  - ReadWriteOnce
  persistentVolumeReclaimPolicy: Delete
  storageClassName: standard
  local:
    path: /mnt/kube-storage/plex
  nodeAffinity:
    required:
      nodeSelectorTerms:
      - matchExpressions:
        - key: kubernetes.io/hostname
          operator: In
          values:
          - r720
---
apiVersion: v1
kind: PersistentVolumeClaim
metadata:
  name: plex-config-claim
spec:
  storageClassName: standard
  accessModes:
  - ReadWriteOnce
  resources:
    requests:
      storage: 200Gi
  selector:
    matchExpressions:
    - key: name
      operator: In
      values: [&quot;plex-config-volume&quot;]
---
apiVersion: apps/v1
kind: Deployment
metadata:
  labels:
    app: nginx
  name: nginx
spec:
  replicas: 1
  selector:
    matchLabels:
      app: nginx
  template:
    metadata:
      labels:
        app: nginx
      name: nginx
    spec:
      containers:
      - image: maersk/nginx
        imagePullPolicy: Always
        name: nginx
        ports:
        - containerPort: 80
          protocol: TCP
        volumeMounts:
        - mountPath: /config
          name: config-nfs
        - mountPath: /data
          name: data-nfs
      volumes:
      - name: config-nfs
        emptyDir: {}
      - name: data-nfs
        persistentVolumeClaim:
          claimName: plex-config-claim
</code></pre>
<p>I have 3 nodes -&gt; 1 master, 2 worker nodes.</p>
<pre><code>NAME        STATUS   ROLES    AGE   VERSION   LABELS
elitedesk   Ready    master   40d   v1.18.6   beta.kubernetes.io/arch=amd64,beta.kubernetes.io/os=linux,kubernetes.io/arch=amd64,kubernetes.io/hostname=elitedesk,kubernetes.io/os=linux,node-role.kubernetes.io/master=
optiplex    Ready    &lt;none&gt;   40d   v1.18.6   beta.kubernetes.io/arch=amd64,beta.kubernetes.io/os=linux,kubernetes.io/arch=amd64,kubernetes.io/hostname=optiplex,kubernetes.io/os=linux
r720        Ready    &lt;none&gt;   40d   v1.18.6   beta.kubernetes.io/arch=amd64,beta.kubernetes.io/os=linux,kubernetes.io/arch=amd64,kubernetes.io/hostname=r720,kubernetes.io/os=linux
</code></pre>
<p>Not sure what I'm doing wrong here.
The Path for the PersistentVolume is just a directory, not a mounted storage device.</p>

Xerofuzzion
<p>My issue was the <code>selector</code> part of my PersistentVolumeClaim.
Adding a label to my PV and selecting that label in my PVC fixed my issue.</p>
<pre><code>apiVersion: storage.k8s.io/v1
kind: StorageClass
metadata:
  name: standard
provisioner: kubernetes.io/no-provisioner
volumeBindingMode: WaitForFirstConsumer
---
apiVersion: v1
kind: PersistentVolume
metadata:
  name: plex-config-volume
  labels:
    storage-type: plex-config-volume
spec:
  capacity:
    storage: 400Gi
  volumeMode: Filesystem
  accessModes:
  - ReadWriteOnce
  persistentVolumeReclaimPolicy: Delete
  storageClassName: standard
  local:
    path: /mnt/kube-storage/plex
  nodeAffinity:
    required:
      nodeSelectorTerms:
      - matchExpressions:
        - key: kubernetes.io/hostname
          operator: In
          values:
          - r720
---
apiVersion: v1
kind: PersistentVolumeClaim
metadata:
  name: plex-config-claim
spec:
  storageClassName: standard
  accessModes:
  - ReadWriteOnce
  resources:
    requests:
      storage: 200Gi
  selector:
    matchLabels:
      storage-type: plex-config-volume
---
apiVersion: apps/v1
kind: Deployment
metadata:
  labels:
    app: nginx
  name: nginx
spec:
  replicas: 1
  selector:
    matchLabels:
      app: nginx
  template:
    metadata:
      labels:
        app: nginx
      name: nginx
    spec:
      containers:
      - image: maersk/nginx
        imagePullPolicy: Always
        name: nginx
        ports:
        - containerPort: 80
          protocol: TCP
        volumeMounts:
        - mountPath: /config
          name: config-nfs
        - mountPath: /data
          name: data-nfs
      volumes:
      - name: config-nfs
        emptyDir: {}
      - name: data-nfs
        persistentVolumeClaim:
          claimName: plex-config-claim
</code></pre>
