<p>I'm trying to specify Local SSD in a Google Cloud as a <code>PersistedVolume</code>. I followed the <a href="https://cloud.google.com/kubernetes-engine/docs/how-to/persistent-volumes/local-ssd#example_local_pvs" rel="nofollow noreferrer">docs</a> to set up the <a href="https://cloud.google.com/kubernetes-engine/docs/how-to/persistent-volumes/local-ssd#running_the_local_volume_static_provisioner" rel="nofollow noreferrer">automated SSD provisioning</a>, and running <code>kubectl get pv</code> returns a valid volume:</p>

<pre><code>NAME                CAPACITY   ACCESS MODES   RECLAIM POLICY   STATUS      CLAIM     STORAGECLASS   REASON    AGE
local-pv-9721c951   368Gi      RWO            Delete           Available             local-scsi               1h
</code></pre>

<p>The problem is that I cannot get my pod to bind to it. The <code>kubectl get pvc</code> keeps showing this:</p>

<pre><code>NAME      STATUS    VOLUME    CAPACITY   ACCESS MODES   STORAGECLASS   AGE
mapdata   Pending                                       local-scsi     7m
</code></pre>

<p>and <code>kubectl get events</code> gives me these:</p>

<pre><code>LAST SEEN   FIRST SEEN   COUNT     NAME                                                KIND                    SUBOBJECT   TYPE      REASON                 SOURCE                        MESSAGE
7m          7m           1         v3tiles.1551c0bbcb23d983                            Service                             Normal    EnsuredLoadBalancer    service-controller            Ensured load balancer
2m          8m           24        maptilesbackend-8645566545-x44nl.1551c0ae27d06fca   Pod                                 Warning   FailedScheduling       default-scheduler             0/1 nodes are available: 1 node(s) didn't find available persistent volumes to bind.
2m          8m           26        mapdata.1551c0adf908e362                            PersistentVolumeClaim               Normal    WaitForFirstConsumer   persistentvolume-controller   waiting for first consumer to be created before binding
</code></pre>

<p>What would i need to do to bind that SSD to my pod?  Here's the code I have been experimenting with:</p>

<pre><code>apiVersion: extensions/v1beta1
kind: Deployment
metadata:
  name: maptilesbackend
  namespace: default
spec:
  selector:
    matchLabels:
      app: maptilesbackend
  strategy:
    type: RollingUpdate
  template:
    metadata:
      labels:
        app: maptilesbackend
    spec:
      containers:
      - image: klokantech/openmaptiles-server
        imagePullPolicy: Always
        name: maptilesbackend
        volumeMounts:
          - mountPath: /data
            name: mapdata
            readOnly: true
      volumes:
        - name: mapdata
          persistentVolumeClaim:
            claimName: mapdata
            readOnly: true
---
apiVersion: storage.k8s.io/v1
kind: StorageClass
metadata:
  name: "local-scsi"
provisioner: "kubernetes.io/no-provisioner"
volumeBindingMode: "WaitForFirstConsumer"
---
apiVersion: v1
kind: PersistentVolumeClaim
metadata:
  name: mapdata
spec:
  storageClassName: local-scsi
  accessModes:
    - ReadOnlyMany
  resources:
    requests:
      storage: 300Gi
</code></pre>

Yuri Astrakhan
<p><code>ReadOnlyMany</code> doesn't make sense for local SSDs</p>

<p>As per the docs:</p>

<blockquote>
  <p>ReadOnlyMany – the volume can be mounted read-only by many nodes</p>
</blockquote>

<p>You can't mount a local SSD on many nodes because it's local to one node only.</p>
