<p>I am following <a href="https://github.com/kubernetes-incubator/cri-containerd/blob/master/docs/crictl.md#run-a-pod-sandbox-using-a-config-file" rel="nofollow noreferrer">Run a pod sandbox</a> link to create a sandbox using crictl. I am getting below error</p>

<pre><code>root@cri-master:~# crictl runs sandbox-config.json
FATA[0000] run pod sandbox failed: rpc error: code = Unknown desc =failed to setup network for sandbox     "3ad790c715c817d22e6f6df95bf612dbc0ceaf05d2d94f94e62aa4b57234ea57": pods "nginx-sandbox" not found 
</code></pre>

<p>Please could someone tell me what is being done wrong here</p>

<p>So I posted same question in the cri-containerd github issue and I got this answer. This explains everything</p>
<p><a href="https://github.com/kubernetes-incubator/cri-containerd/issues/520" rel="nofollow noreferrer">Unable to create sandbox</a></p>
<blockquote>
<p>IIRC, calico daemonset watch apiserver to get a list of pods, and apply network configuration based on the pod spec. I think this is the problem.</p>
<p>If you use <code>crictl create</code> a sandbox yourself, there won't be corresponding pod on apiserver, thus calico reports that error.</p>
<p>In fact, we don't recommend user to run <code>crictl runs</code> and <code>crictl create</code> on a Kubernetes node , those commands are there just for some special debug case. And that's also why we make the command so hard to use (user need to prepare for a configuration file to create a sandbox/container).</p>
<p>In fact, even if you are able to create the sandbox, <code>kubelet</code> will eventually stop and delete it because it doesn't see the corresponding pod on apiserver.</p>
<p>If you just want to try crictl, the error is caused by the reason above.<br />
If you just want to try create a pod, use kubectl instead. :)</p>
</blockquote>
