Hi Itamar,

I launched a GKE 1.6.2 and created a PV with StorageClassName using both
kubectl create and apply commands.  They both seemed to work.

Can you double check your kubectl version?

Thanks,
Michelle

On Wed, May 17, 2017 at 8:28 AM, Itamar O <itamar...@gmail.com> wrote:

> It appears that the storageClassName attribute in the YAML is not being
> propagated correctly to the API server, or something of that sort.
>
> Here's my YAML:
>
> apiVersion: v1
> kind: PersistentVolume
> metadata:
>   name: postgresql-data-stage
>   labels:
>     data_for: postgres
>     env: stage
> spec:
>   capacity:
>     storage: 200Gi
>   accessModes:
>     - ReadWriteOnce
> *  storageClassName: standard*
>   gcePersistentDisk:
>     # This GCE persistent disk must already exist.
>     pdName: postgresql-stage-data
>     fsType: ext4
>
> Applied using kubectl:
> kubectl apply -f stage/volumes.yaml --record
>
> The PV is created, but without the Storage Class:
> >kubectl describe pv postgresql-data-stage
> Name: postgresql-data-stage
> Labels: data_for=postgres
> env=stage
> failure-domain.beta.kubernetes.io/region=us-central1
> failure-domain.beta.kubernetes.io/zone=us-central1-f
> *StorageClass:*
> Status: Available
> Claim:
> Reclaim Policy: Retain
> Access Modes: RWO
> Capacity: 200Gi
> Message:
> Source:
>     Type: GCEPersistentDisk (a Persistent Disk resource in Google Compute
> Engine)
>     PDName: postgresql-stage-data
>     FSType: ext4
>     Partition: 0
>     ReadOnly: false
> No events.
>
> Running on GKE, k8s version 1.6.2 (both master and node pool).
> Editing the PV object in the k8s UI seems to help (the PVC is able to
> bind).
> Any idea?
>
> --
> You received this message because you are subscribed to the Google Groups
> "Kubernetes user discussion and Q&A" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to kubernetes-users+unsubscr...@googlegroups.com.
> To post to this group, send email to kubernetes-users@googlegroups.com.
> Visit this group at https://groups.google.com/group/kubernetes-users.
> For more options, visit https://groups.google.com/d/optout.
>

-- 
You received this message because you are subscribed to the Google Groups 
"Kubernetes user discussion and Q&A" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to kubernetes-users+unsubscr...@googlegroups.com.
To post to this group, send email to kubernetes-users@googlegroups.com.
Visit this group at https://groups.google.com/group/kubernetes-users.
For more options, visit https://groups.google.com/d/optout.

Reply via email to