[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]

Re: Vagrant VM - Adding MySQL pod to project fails



i'm guessing you have no persistent volumes defined in your cluster, so the persistent volume claim is stuck in pending waiting for a volume to become available.

https://docs.openshift.org/latest/install_config/persistent_storage/index.html

On Wed, Feb 17, 2016 at 11:20 AM, Marc Boorshtein <mboorshtein gmail com> wrote:
I'm new to OS so forgive anything i mis-state.  I setup the vagrant box based on https://www.openshift.org/vm/ with vagrant and virtual box running on osx el capitan.  


​what do you mean by go to storage?

Once logged into the console, I go to my project and under "Browse" I click "Storage" which is where i see the pending going
 

how did you create the mysql pod?  Sounds like you might be using a persistent volume?  Can you try with an EmptyDir volume instead to narrow down the problem?


Once the VM was up and running I went to the console on https://10.2.2.2:8443/console and created a new project.  Once the project was created:

1.  Clicked on "Add to Project"
2.  Under databases I chose the mysql-persistent template
3.  Filled out the template and clicked "Create"

I tried using the mysql-ephemeril template that appears to be working
 
Also can you oc describe the pod?  that might provide more details/event messages.


Here's what I get when I run oc describe pods

$ ./oc describe pods
Name: mysql-1-deploy
Namespace: openunison
Image(s): openshift/origin-deployer:latest
Node: origin/10.0.2.15
Start Time: Wed, 17 Feb 2016 10:43:44 -0500
Status: Failed
Reason:
Message:
IP:
Replication Controllers: <none>
Containers:
  deployment:
    Container ID: docker://d014ecb17d88ee6694b8950c4e21dd3516e4dd47d7950f3fc5e5f0d263b32304
    Image: openshift/origin-deployer:latest
    Image ID: docker://8df384312c636a4d6320dec6e8ded33cb33a78b8eb3076b25e31a4b8f9bb669f
    QoS Tier:
      cpu: BestEffort
      memory: BestEffort
    State: Terminated
      Reason: Error
      Exit Code: 255
      Started: Wed, 17 Feb 2016 10:43:46 -0500
      Finished: Wed, 17 Feb 2016 10:53:49 -0500
    Ready: False
    Restart Count: 0
    Environment Variables:
      KUBERNETES_MASTER: https://10.2.2.2:8443
      OPENSHIFT_MASTER: https://10.2.2.2:8443
      BEARER_TOKEN_FILE: /var/run/secrets/k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5B
-----END CERTIFICATE-----

      OPENSHIFT_DEPLOYMENT_NAME: mysql-1
      OPENSHIFT_DEPLOYMENT_NAMESPACE: openunison
Conditions:
  Type Status
  Ready False 
Volumes:
  deployer-token-988ze:
    Type: Secret (a secret that should populate this volume)
    SecretName: deployer-token-988ze
Events:
  FirstSeen LastSeen Count From SubobjectPath Type Reason Message
  --------- -------- ----- ---- ------------- -------- ------ -------
  34m 34m 1 {scheduler } Normal Scheduled Successfully assigned mysql-1-deploy to origin
  34m 34m 1 {kubelet origin} spec.containers{deployment} Normal Pulled Container image "openshift/origin-deployer:latest" already present on machine
  34m 34m 1 {kubelet origin} spec.containers{deployment} Normal Created Created container with docker id d014ecb17d88
  34m 34m 1 {kubelet origin} spec.containers{deployment} Normal Started Started container with docker id d014ecb17d88


Name: mysql-openunison-1-deploy
Namespace: openunison
Image(s): openshift/origin-deployer:latest
Node: origin/10.0.2.15
Start Time: Wed, 17 Feb 2016 09:06:41 -0500
Status: Failed
Reason:
Message:
IP:
Replication Controllers: <none>
Containers:
  deployment:
    Container ID: docker://9f0bb8e9cdf49db1971b14d2b7922d76e97e8263c9141277c24f9d56b23a1f5b
    Image: openshift/origin-deployer:latest
    Image ID: docker://8df384312c636a4d6320dec6e8ded33cb33a78b8eb3076b25e31a4b8f9bb669f
    QoS Tier:
      cpu: BestEffort
      memory: BestEffort
    State: Terminated
      Reason: Error
      Exit Code: 255
      Started: Wed, 17 Feb 2016 09:06:42 -0500
      Finished: Wed, 17 Feb 2016 09:16:45 -0500
    Ready: False
    Restart Count: 0
    Environment Variables:
      KUBERNETES_MASTER: https://10.2.2.2:8443
      OPENSHIFT_MASTER: https://10.2.2.2:8443
      BEARER_TOKEN_FILE: /var/run/secrets/kubernetes.io/serviceaccount/token
      OPENSHIFT_CA_DATA: -----BEGIN CERTIFICATE-----
MIIC6jCCAdKgAwIBAgIBATANBgkqhkiG9w0BAQsFADAmMSQwIgYDVQQDDBtvcGVu
c2hpZnQtc2lnbmVyQDE0NTU1NjgzMTYwHhcNMTYwMjE1MjAzMTU1WhcNMjEwMjEz
MjAzMTU2WjAmMSQwIgYDVQQDDBtvcGVuc2hpZnQtc2lnbmVyQDE0NTU1NjgzMTYw
ggEiMA0GCSqGSIb3DQEBAQUAA4IBDwAwggEKAoIBAQDAc+jOXskorOuZNP629N0z
s/RTjuUHVfQeYHQ3PTMYoaa7vBOCUPehH6BBcD0xUrIh7NwoJopvC2Jl+Kb1Niw4
JlOIQUHK9Ub2Gf43sXJqDgXmpwrWv2BZBPYYjE7dpdl1z1XD12x3RurRlmrdhYBA
bOo2SQ4l6vFC1YXeaeYB6k5g5S4MxisDiQBqg7EBpZEInbOglUhBHMmZGiTTQoGm
hF2W9qNboal7WLRSsaJr6I2cw3ckkWRcD1qJuakkiSSd77cYlj/dbMpKdNUJBT1Z
br9/jBIIvzRYYO5QPkU9kE6Qo7tleafnsG2CTRjXoiv7ihYBB6JkZ/2JPIsx68rr
AgMBAAGjIzAhMA4GA1UdDwEB/wQEAwICpDAPBgNVHRMBAf8EBTADAQH/MA0GCSqG
SIb3DQEBCwUAA4IBAQAmtC1nKF3qYOSw/f3w4FEevFRHSbU8Iw8L0ufczmD56AIP
q45FBu6jciy28Hvsi7G/FJrex/9AYXc7rYEpiVlaj14PqEapk57H/xP2bwzG47tc
qT2cQUPKhOZJi+DrFXdf7ftde++OW0xUC7yjVx9mQ6Vf5G6HUHAMXB5a28STsVSm
rEy9FECffasDttCGukhQ1nLd8y2AXyIvl18Jeq0e1CCsNd6FFb/N/hvx/ON2u7sx
e6Ys4Aw2HMX2GL857rD8b14o4Yt4AGm515St63riI1mNlirm3wi3dZxBHPkkF5mI
fSQUUUHn+xBy2qR9eHvxzilG7MDmzDHJIah2kU5B
-----END CERTIFICATE-----

      OPENSHIFT_DEPLOYMENT_NAME: mysql-openunison-1
      OPENSHIFT_DEPLOYMENT_NAMESPACE: openunison
Conditions:
  Type Status
  Ready False 
Volumes:
  deployer-token-988ze:
    Type: Secret (a secret that should populate this volume)
    SecretName: deployer-token-988ze
No events.

Name: mysqltest-1-xwgdq
Namespace: openunison
Image(s): centos/mysql-56-centos7 sha256:5a1d4c653e953c75a2834444cfecb1016ae57023b52ea12ad35ec0d1f861adb1
Node: origin/10.0.2.15
Start Time: Wed, 17 Feb 2016 11:14:04 -0500
Labels: deployment=mysqltest-1,deploymentconfig=mysqltest,name=mysqltest
Status: Running
Reason:
Message:
IP: 172.17.0.10
Replication Controllers: mysqltest-1 (1/1 replicas created)
Containers:
  mysql:
    Container ID: docker://6a92914ef0f2eb62ca9fb2408765aa48dcf8bddb5c70ec7b13596bd334e22f40
    Image: centos/mysql-56-centos7 sha256:5a1d4c653e953c75a2834444cfecb1016ae57023b52ea12ad35ec0d1f861adb1
    Image ID: docker://ef372ffa6bf3d88aefb7e499438136bb7e9c71000d967fad7a17ac33ebe4d8aa
    QoS Tier:
      cpu: BestEffort
      memory: BestEffort
    State: Running
      Started: Wed, 17 Feb 2016 11:15:20 -0500
    Ready: True
    Restart Count: 0
    Environment Variables:
      MYSQL_USER: test
      MYSQL_PASSWORD: test
      MYSQL_DATABASE: sampledb
Conditions:
  Type Status
  Ready True 
Volumes:
  mysqltest-data:
    Type: EmptyDir (a temporary directory that shares a pod's lifetime)
    Medium:
  default-token-krn8s:
    Type: Secret (a secret that should populate this volume)
    SecretName: default-token-krn8s
Events:
  FirstSeen LastSeen Count From SubobjectPath Type Reason Message
  --------- -------- ----- ---- ------------- -------- ------ -------
  4m 4m 1 {scheduler } Normal Scheduled Successfully assigned mysqltest-1-xwgdq to origin
  4m 4m 1 {kubelet origin} spec.containers{mysql} Normal Pulling pulling image "centos/mysql-56-centos7 sha256:5a1d4c653e953c75a2834444cfecb1016ae57023b52ea12ad35ec0d1f861adb1"
  3m 3m 1 {kubelet origin} spec.containers{mysql} Normal Pulled Successfully pulled image "centos/mysql-56-centos7 sha256:5a1d4c653e953c75a2834444cfecb1016ae57023b52ea12ad35ec0d1f861adb1"
  3m 3m 1 {kubelet origin} spec.containers{mysql} Normal Created Created container with docker id 6a92914ef0f2
  3m 3m 1 {kubelet origin} spec.containers{mysql} Normal Started Started container with docker id 6a92914ef0f2
  3m 3m 1 {kubelet origin} Warning FailedSync Error syncing pod, skipping: not all containers have started: 0 != 1




Thanks
Marc 




--
Ben Parees | OpenShift


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]