title: Why does Kubernetes showing the nodes as ready even if they are not reachable?
body: <p>I am running Kubernetes cluster which is configured with a master and 3 nodes.</p>
  
  <pre><code>#kubectl get nodes
  NAME       STATUS    AGE
  minion-1   Ready     46d
  minion-2   Ready     46d
  minion-3   Ready     46d
  </code></pre>
  
  <p>I have launched couple of pods in the cluster and found that the pods are in pending state.</p>
  
  <pre><code># kubectl get pods -o wide
  NAME      READY     STATUS    RESTARTS   AGE       IP        NODE
  httpd     0/1       Pending   0          10m       &lt;none&gt;
  nginx     0/1       Pending   0          11m       &lt;none&gt;
  </code></pre>
  
  <p>One of the pod "httpd" yaml file:</p>
  
  <pre><code># cat http.yaml
  apiVersion: v1
  kind: Pod
  metadata:
    name: httpd
    labels:
      env: test
  spec:
    containers:
    - name: httpd
      image: httpd
  </code></pre>
  
  <p>While debugging the reason for failure found that the couple of nodes configured are not ready. Only one node is reachable from master. </p>
  
  <pre><code># ping minion-1
  PING minion-1 (172.31.24.204) 56(84) bytes of data.
  64 bytes from minion-1 (172.31.24.204): icmp_seq=1 ttl=64 time=0.575 ms
  </code></pre>
  
  <p>Whereas other nodes are not reachable:    </p>
  
  <pre><code># ping minion-2
  PING minion-2 (172.31.29.95) 56(84) bytes of data.
  From master (172.31.16.204) icmp_seq=1 Destination Host Unreachable
  
  # ping minion-3
  PING minion-3 (172.31.17.252) 56(84) bytes of data.
  From master (172.31.16.204) icmp_seq=1 Destination Host Unreachable
  </code></pre>
  
  <p>The queries that I have here is </p>
  
  <blockquote>
    <p>1) Why does Kubernetes showing the nodes as ready even if they are not
    reachable from master?</p>
    
    <p>2) Why are the pods creation failing?</p>
  </blockquote>
  
  <pre><code>  Is it because of unavailability of nodes or any configuration issue in yaml file?
  
  #  kubectl describe pod httpd
  Name:           httpd
  Namespace:      default
  Node:           /
  Labels:         env=test
  Status:         Pending
  IP:
  Controllers:    &lt;none&gt;
  Containers:
    httpd:
      Image:                      httpd
      Port:
      Volume Mounts:              &lt;none&gt;
      Environment Variables:      &lt;none&gt;
  No volumes.
  QoS Class:      BestEffort
  Tolerations:    &lt;none&gt;
  No events.
  </code></pre>
  
  <p>Following are the Kubernetes and etcd versions.</p>
  
  <pre><code>]# kubectl --version
  Kubernetes v1.5.2
  [root@raghavendar1 ~]# et
  etcd        etcdctl     ether-wake  ethtool
  [root@raghavendar1 ~]# etcd --version
  etcd Version: 3.2.5
  Git SHA: d0d1a87
  Go Version: go1.8.3
  Go OS/Arch: linux/amd64
  </code></pre>