2016-03-28 15 views
4

私は正確に例を以下、[http://kubernetes.io/docs/hellonode/,]

私が実行した後、[実行kubectlハローノード--image = gcr.io/PROJECT_ID/hello-node:v1 --port = 8080 展開 "hello-node"が作成されました。ポッドは正常に実行されません、私はCrashLoopBackOffステータスを取得しました。私は配備execを持っていません。

すべてのコメントをいただければ幸いです。

Nobert

========================================= =

 


[email protected]:~/hellonode$ kubectl get pods 
NAME       READY  STATUS    RESTARTS AGE 
hello-node-2129762707-hte0f 0/1  CrashLoopBackOff 5   6m 





[email protected]:~/hellonode$ kubectl describe pod hello 
Name:   hello-node-2129762707-hte0f 
Namespace:  default 
Node:   gke-hello-world-16359f5d-node-zkpf/10.140.0.3 
Start Time:  Mon, 28 Mar 2016 20:07:53 +0800 
Labels:   pod-template-hash=2129762707,run=hello-node 
Status:   Running 
IP:    10.16.2.3 
Controllers: ReplicaSet/hello-node-2129762707 
Containers: 
    hello-node: 
    Container ID:  docker://dfae3b1e068a5b0e89b1791f1acac56148fc649ea5894d36575ce3cd46a2ae3d 
    Image:    gcr.io/kubernete-codelab-1264/hello-node:v1 
    Image ID:   docker://1fab5e6a9ef21db5518db9bcfbafa52799c38609738f5b3e1c4bb875225b5d61 
    Port:    8080/TCP 
    Args: 
     deployment 
     hello-node 
     created 
    QoS Tier: 
     cpu:  Burstable 
     memory: BestEffort 
    Requests: 
     cpu:    100m 
    State:    Waiting 
     Reason:   CrashLoopBackOff 
    Last State:   Terminated 
     Reason:   ContainerCannotRun 
     Message:   [8] System error: exec: "deployment": executable file not found in $PATH 
     Exit Code:  -1 
     Started:   Mon, 28 Mar 2016 20:14:16 +0800 
     Finished:   Mon, 28 Mar 2016 20:14:16 +0800 
    Ready:    False 
    Restart Count:  6 
    Environment Variables: 
Conditions: 
    Type   Status 
    Ready   False 
Volumes: 
    default-token-k3zl5: 
    Type:  Secret (a volume populated by a Secret) 
    SecretName: default-token-k3zl5 
Events: 
    FirstSeen  LastSeen  Count From           SubobjectPath     Type   Reason   Message 
    ---------  --------  ----- ----           -------------     --------  ------   ------- 
    6m   6m    1  {kubelet gke-hello-world-16359f5d-node-zkpf} spec.containers{hello-node}  Normal   Pulling   pulling image "gcr.io/kubernete-codelab-1264/hello-node:v1" 
    6m   6m    1  {default-scheduler }               Normal   Scheduled  Successfully assigned hello-node-2129762707-hte0f to gke-hello-world-16359f5d-node-zkpf 
    6m   6m    1  {kubelet gke-hello-world-16359f5d-node-zkpf} spec.containers{hello-node}  Normal   Created   Created container with docker id 41c8fde8f94b 
    6m   6m    1  {kubelet gke-hello-world-16359f5d-node-zkpf} spec.containers{hello-node}  Warning   Failed   Failed to start container with docker id 41c8fde8f94b with error: API error (500): Cannot start container 41c8fde8f94bee697e3f1a3af88e6b347f5b850d9a6a406a5c2e25375e48c87a: [8] System error: exec: "deployment": executable file not found in $PATH 

    6m 6m  1  {kubelet gke-hello-world-16359f5d-node-zkpf}   Warning FailedSync  Error syncing pod, skipping: failed to "StartContainer" for "hello-node" with RunContainerError: "runContainer: API error (500): Cannot start container 41c8fde8f94bee697e3f1a3af88e6b347f5b850d9a6a406a5c2e25375e48c87a: [8] System error: exec: \"deployment\": executable file not found in $PATH\n" 

    6m 6m  1  {kubelet gke-hello-world-16359f5d-node-zkpf} spec.containers{hello-node}  Normal Created Created container with docker id a99c8dc5cc8a 
    6m 6m  1  {kubelet gke-hello-world-16359f5d-node-zkpf} spec.containers{hello-node}  Warning Failed Failed to start container with docker id a99c8dc5cc8a with error: API error (500): Cannot start container a99c8dc5cc8a884d35f7c69e9e1ba91643f9e9ef8815b95f80aabdf9995a6608: [8] System error: exec: "deployment": executable file not found in $PATH 

    6m 6m  1  {kubelet gke-hello-world-16359f5d-node-zkpf}   Warning FailedSync  Error syncing pod, skipping: failed to "StartContainer" for "hello-node" with RunContainerError: "runContainer: API error (500): Cannot start container a99c8dc5cc8a884d35f7c69e9e1ba91643f9e9ef8815b95f80aabdf9995a6608: [8] System error: exec: \"deployment\": executable file not found in $PATH\n" 

    6m 6m  1  {kubelet gke-hello-world-16359f5d-node-zkpf} spec.containers{hello-node}  Normal Pulled   Successfully pulled image "gcr.io/kubernete-codelab-1264/hello-node:v1" 
    6m 6m  1  {kubelet gke-hello-world-16359f5d-node-zkpf}         Warning FailedSync  Error syncing pod, skipping: failed to "StartContainer" for "hello-node" with RunContainerError: "runContainer: API error (500): Cannot start container 977b07a9e5dea5256de4e600d6071e3ac5cc6e9a344cb5354851aab587bff952: [8] System error: exec: \"deployment\": executable file not found in $PATH\n" 

    6m 6m  1  {kubelet gke-hello-world-16359f5d-node-zkpf} spec.containers{hello-node}  Normal Created Created container with docker id 977b07a9e5de 
    6m 6m  1  {kubelet gke-hello-world-16359f5d-node-zkpf} spec.containers{hello-node}  Warning Failed Failed to start container with docker id 977b07a9e5de with error: API error (500): Cannot start container 977b07a9e5dea5256de4e600d6071e3ac5cc6e9a344cb5354851aab587bff952: [8] System error: exec: "deployment": executable file not found in $PATH 

    5m 5m  1  {kubelet gke-hello-world-16359f5d-node-zkpf}   Warning FailedSync  Error syncing pod, skipping: failed to "StartContainer" for "hello-node" with CrashLoopBackOff: "Back-off 20s restarting failed container=hello-node pod=hello-node-2129762707-hte0f_default(b300b749-f4dd-11e5-83ee-42010af0000e)" 

    5m 5m  1  {kubelet gke-hello-world-16359f5d-node-zkpf} spec.containers{hello-node}  Normal Created Created container with docker id f8ad177306bc 
    5m 5m  1  {kubelet gke-hello-world-16359f5d-node-zkpf} spec.containers{hello-node}  Warning Failed Failed to start container with docker id f8ad177306bc with error: API error (500): Cannot start container f8ad177306bc6154498befbbc876ee4b2334d3842f269f4579f762434effe33a: [8] System error: exec: "deployment": executable file not found in $PATH 

    5m 5m  1  {kubelet gke-hello-world-16359f5d-node-zkpf}   Warning FailedSync  Error syncing pod, skipping: failed to "StartContainer" for "hello-node" with RunContainerError: "runContainer: API error (500): Cannot start container f8ad177306bc6154498befbbc876ee4b2334d3842f269f4579f762434effe33a: [8] System error: exec: \"deployment\": executable file not found in $PATH\n" 

    5m 4m  3  {kubelet gke-hello-world-16359f5d-node-zkpf}   Warning FailedSync  Error syncing pod, skipping: failed to "StartContainer" for "hello-node" with CrashLoopBackOff: "Back-off 40s restarting failed container=hello-node pod=hello-node-2129762707-hte0f_default(b300b749-f4dd-11e5-83ee-42010af0000e)" 

    4m 4m  1  {kubelet gke-hello-world-16359f5d-node-zkpf}   Warning FailedSync  Error syncing pod, skipping: failed to "StartContainer" for "hello-node" with RunContainerError: "runContainer: API error (500): Cannot start container d9218f5385cb020c752c9e78e3eda87f04fa0428cba92d14a1a73c93a01c8d5b: [8] System error: exec: \"deployment\": executable file not found in $PATH\n" 

    4m 4m  1  {kubelet gke-hello-world-16359f5d-node-zkpf} spec.containers{hello-node}  Normal Created Created container with docker id d9218f5385cb 
    4m 4m  1  {kubelet gke-hello-world-16359f5d-node-zkpf} spec.containers{hello-node}  Warning Failed Failed to start container with docker id d9218f5385cb with error: API error (500): Cannot start container d9218f5385cb020c752c9e78e3eda87f04fa0428cba92d14a1a73c93a01c8d5b: [8] System error: exec: "deployment": executable file not found in $PATH 

    4m 3m  7  {kubelet gke-hello-world-16359f5d-node-zkpf}   Warning FailedSync  Error syncing pod, skipping: failed to "StartContainer" for "hello-node" with CrashLoopBackOff: "Back-off 1m20s restarting failed container=hello-node pod=hello-node-2129762707-hte0f_default(b300b749-f4dd-11e5-83ee-42010af0000e)" 

    3m 3m  1  {kubelet gke-hello-world-16359f5d-node-zkpf}   Warning FailedSync  Error syncing pod, skipping: failed to "StartContainer" for "hello-node" with RunContainerError: "runContainer: API error (500): Cannot start container 7c3c680f18c4cb7fa0fd02f538dcbf2e8f8ba94661fe2703c2fb42ed0c908f59: [8] System error: exec: \"deployment\": executable file not found in $PATH\n" 

    3m 3m  1  {kubelet gke-hello-world-16359f5d-node-zkpf} spec.containers{hello-node}  Warning Failed Failed to start container with docker id 7c3c680f18c4 with error: API error (500): Cannot start container 7c3c680f18c4cb7fa0fd02f538dcbf2e8f8ba94661fe2703c2fb42ed0c908f59: [8] System error: exec: "deployment": executable file not found in $PATH 

    3m 3m  1  {kubelet gke-hello-world-16359f5d-node-zkpf} spec.containers{hello-node}  Normal Created   Created container with docker id 7c3c680f18c4 
    2m 40s  12  {kubelet gke-hello-world-16359f5d-node-zkpf}         Warning FailedSync  Error syncing pod, skipping: failed to "StartContainer" for "hello-node" with CrashLoopBackOff: "Back-off 2m40s restarting failed container=hello-node pod=hello-node-2129762707-hte0f_default(b300b749-f4dd-11e5-83ee-42010af0000e)" 

    26s 26s  1  {kubelet gke-hello-world-16359f5d-node-zkpf} spec.containers{hello-node}  Warning Failed Failed to start container with docker id dfae3b1e068a with error: API error (500): Cannot start container dfae3b1e068a5b0e89b1791f1acac56148fc649ea5894d36575ce3cd46a2ae3d: [8] System error: exec: "deployment": executable file not found in $PATH 

    26s 26s  1  {kubelet gke-hello-world-16359f5d-node-zkpf} spec.containers{hello-node}  Normal Created   Created container with docker id dfae3b1e068a 
    6m 26s  6  {kubelet gke-hello-world-16359f5d-node-zkpf} spec.containers{hello-node}  Normal Pulled   Container image "gcr.io/kubernete-codelab-1264/hello-node:v1" already present on machine 
    3m 14s  3  {kubelet gke-hello-world-16359f5d-node-zkpf}         Warning FailedSync  (events with common reason combined) 
    5m 3s  26  {kubelet gke-hello-world-16359f5d-node-zkpf} spec.containers{hello-node}  Warning BackOff   Back-off restarting failed docker container 
    3s 3s  1  {kubelet gke-hello-world-16359f5d-node-zkpf}         Warning FailedSync  Error syncing pod, skipping: failed to "StartContainer" for "hello-node" with CrashLoopBackOff: "Back-off 5m0s restarting failed container=hello-node pod=hello-node-2129762707-hte0f_default(b300b749-f4dd-11e5-83ee-42010af0000e)" 

==========================================

+0

私は、ここでkubernetesウォークスルーを行ったのと同じ間違いをしました:http://kubernetes.io/docs/hellonode/。質問を投稿していただきありがとうございます。 –

+0

私もkubernetes hello world walkthrough docsを見ている間に間違いをしました。質問を投稿していただきありがとうございます。 –

+0

あなたは何を知っています、私は同じことをして何時間も間違っていることを見つけるために頭を傷つけました。さらにデバッグした後( 'kubectl describe pods ')に問題を突き止めることができました。私はKubernetesの人たちが自分の文書のフォントを変更する必要があると思う。 –

答えて

6

after I run [kubectl run hello-node --image=gcr.io/PROJECT_ID/hello-node:v1 --port=8080 deployment "hello-node" created]

kubectl run hello-node --image=gcr.io/PROJECT_ID/hello-node:v1 --port=8080 deployment "hello-node" createdを実行していますか?

この場合、deploymentはPATH内の実行可能ファイルではないため、驚きはありません。

+0

ええ、後で、私は[配備]の作成方法を見ていきます。ありがとうございます – norbert

+1

@norbert実行する必要があります 'kubectlを実行するhello-node -image = gcr.io/PROJECT_ID/hello-node:v1 --port = 8080' – zhb

+0

これは実行する必要があります[kubectl hello-node -imageを実行する= gcr.io/PROJECT_ID/hello-node:v1 --port = 8080]を入力します。 – norbert

関連する問題