<p>I have 3 nodes, running all kinds of pods. I would like to have a list of nodes and pods, for an example:</p>
<pre><code>NODE1 POD1
NODE1 POD2
NODE2 POD3
NODE3 POD4
</code></pre>
<p>How can this please be achieved?</p>
<p>Thanks.</p>

<p>You can do that with <a href="https://kubernetes.io/docs/reference/kubectl/overview/#custom-columns" rel="noreferrer">custom columns</a>:</p>

<pre><code>kubectl get pod -o=custom-columns=NAME:.metadata.name,STATUS:.status.phase,NODE:.spec.nodeName --all-namespaces
</code></pre>

<p>or just:</p>

<pre><code>kubectl get pod -o=custom-columns=NODE:.spec.nodeName,NAME:.metadata.name --all-namespaces
</code></pre>
