Is this a BUG REPORT or FEATURE REQUEST? (leave only one on its own line)
/kind bug
Description
Podman sometimes complains about improper state while removing pod.
Steps to reproduce the issue:
start pod with play kube
remove pod
podman pod rm -f awx
Describe the results you received:
[root@ikke-fedora ~]# podman ps -a
CONTAINER ID IMAGE COMMAND CREATED STATUS PORTS NAMES
64acc9be331b docker.io/ansible/awx_rabbitmq:3.7.4 docker-entrypoint... 9 minutes ago Up 9 minutes ago 0.0.0.0:8052->8052/tcp rabbitmq
2985effc04ed docker.io/ansible/awx_task:latest /tini -- /bin/sh ... 9 minutes ago Up 9 minutes ago 0.0.0.0:8052->8052/tcp awxtask
ff85a508a08b docker.io/ansible/awx_web:latest /tini -- /bin/sh ... 9 minutes ago Up 9 minutes ago 0.0.0.0:8052->8052/tcp awxweb
9f49483fb6ae docker.io/library/memcached:alpine docker-entrypoint... 9 minutes ago Up 9 minutes ago 0.0.0.0:8052->8052/tcp memcached
50afac523c1b docker.io/library/postgres:9.6 docker-entrypoint... 9 minutes ago Up 9 minutes ago 0.0.0.0:8052->8052/tcp postgres
1bb1bc4e8532 k8s.gcr.io/pause:3.1 9 minutes ago Up 9 minutes ago 0.0.0.0:8052->8052/tcp bc97cebf2cfb-infra
[root@ikke-fedora ~]# podman pod rm -f awx
Error: cannot remove storage for container 1bb1bc4e85324e22e2b2bfac4aa3bcb7cb3b7f913c96643b80c829c2d399bafc as it is running or paused: container state improper
yet after while it works:
[root@ikke-fedora ~]# podman pod rm -f awx
bc97cebf2cfb69e0b980f12664953f89880ab5728688d5f912661bac5a056151
Describe the results you expected:
I'd expect it to work immediately at once. Perhaps some incorrect order or race doing it? Trying remove init before others? I thought that was fixed in earlier issue while ago.
Additional information you deem important (e.g. issue happens only occasionally):
Output of podman version:
Name : podman
Epoch : 2
Version : 1.2.0
Release : 24.dev.git0458daf.fc31
Output of podman info --debug:
(paste your output here)
Additional environment details (AWS, VirtualBox, physical, etc.):
Theory: might be the logic in updateContainerStatus() (oci.go line 487) - it looks strange on initial glance. Will investigate on Monday.
I have a similar issue in that I have a pod with no containers in it (not sure how it happened). Now I can list the pod but I cannot delete it.
125 ~/dev-scripts master $ sudo podman pod ls
POD ID NAME STATUS CREATED # OF CONTAINERS INFRA ID
75844985f5e8 ironic-pod Created 2 hours ago 1 1cec1f248ac5
0 ~/dev-scripts master $ sudo podman pod rm ironic-pod
Error: no such file or directory
125 ~/dev-scripts master $
Actually I ran out of disk space on / at one point so this may be the issue.
Are you sure the error is fatal? That looks like a non-fatal cleanup error. The pod's still there after rm runs?
@mheon wdyt the status is here?
Cleanup errors are fixed... They might have taken this with them. Will poke around.
Try a podman ps -a --sync - that should clear up status issues
Most helpful comment
Try a
podman ps -a --sync- that should clear up status issues