当我运行docker restart时,会收到如下响应:
Error response from daemon: Cannot restart container 97dea473cc0e: container "97dea473cc0e44bb3dfeb773cc6e3b7766fb45cb01e8cba5646bd319974da7ce": already exists
答案 0 :(得分:1)
如果您运行
docker-containerd-ctr --address /run/docker/containerd/docker-containerd.sock --namespace moby c rm <containerd id>
它将允许您重新启动容器。因此,在这种情况下,请运行:
docker-containerd-ctr --address /run/docker/containerd/docker-containerd.sock --namespace moby c rm 97dea473cc0e44bb3dfeb773cc6e3b7766fb45cb01e8cba5646bd319974da7ce
docker restart 97dea473cc0e