Cant connent to pods

477 views
Skip to first unread message

Gregory Machin

unread,
Sep 18, 2022, 10:25:52 PM9/18/22
to AWX Project
Hi, 

I was trying to debug an issue with an upgrade from 21.4.0 to 21.9.0 , but I'm not able to connect to the pods to run commands. 
I get errors like : 
Error from server (NotFound): pods "awx-788749fb7f-gvtv9" not found

root@host:~/awx-operator# kubectl -n awx get all
NAME                                                   READY   STATUS    RESTARTS       AGE
pod/awx-operator-controller-manager-7f89bd5797-zp27t   2/2     Running   13 (66m ago)   37d
pod/awx-postgres-13-0                                  1/1     Running   0              45m
pod/awx-788749fb7f-gvtv9                               4/4     Running   0              45m

NAME                                                      TYPE        CLUSTER-IP      EXTERNAL-IP   PORT(S)    AGE
service/awx-operator-controller-manager-metrics-service   ClusterIP   10.43.88.44     <none>        8443/TCP   37d
service/awx-postgres-13                                   ClusterIP   None            <none>        5432/TCP   37d
service/awx-service                                       ClusterIP   10.43.137.182   <none>        80/TCP     37d

NAME                                              READY   UP-TO-DATE   AVAILABLE   AGE
deployment.apps/awx-operator-controller-manager   1/1     1            1           37d
deployment.apps/awx                               1/1     1            1           37d

NAME                                                         DESIRED   CURRENT   READY   AGE
replicaset.apps/awx-operator-controller-manager-7f89bd5797   1         1         1       37d
replicaset.apps/awx-5d7b85bc77                               0         0         0       37d
replicaset.apps/awx-788749fb7f                               1         1         1       34d

NAME                               READY   AGE
statefulset.apps/awx-postgres-13   1/1     37d
root@host:~/awx-operator# kubectl exec -ti awx-operator-controller-manager-7f89bd5797-zp27t -- bash
Error from server (NotFound): pods "awx-operator-controller-manager-7f89bd5797-zp27t" not found
root@host:~/awx-operator# kubectl exec -ti awx-operator-controller-manager-7f89bd5797 -- bash
Error from server (NotFound): pods "awx-operator-controller-manager-7f89bd5797" not found
root@host:~/awx-operator# kubectl exec -ti awx-788749fb7f-gvtv9 -- bash
Error from server (NotFound): pods "awx-788749fb7f-gvtv9" not found
root@host:~/awx-operator# kubectl exec -ti awx-postgres-13-0 -- bash
Error from server (NotFound): pods "awx-postgres-13-0" not found
root@host:~/awx-operator# kubectl exec -ti awx-postgres-13-0 -- /bin/sh
Error from server (NotFound): pods "awx-postgres-13-0" not found
root@host:~/awx-operator# kubectl exec -ti awx-postgres-13-0 -- /bin/sh

what I'm I doing wrong ?

Currently AWX is running just still 21.4.0.
Thanks
Greg

kurokobo

unread,
Sep 19, 2022, 3:38:33 AM9/19/22
to awx-p...@googlegroups.com
Hi,

Your pods seem to be in "awx" namespace,
therefore specifing "-n awx" for your "kubectl exec" command is required;
e.g. "kubectl -n awx exec -ti awx-operator-controller-manager-7f89bd5797-zp27t -- bash"

------- Original Message -------
--
You received this message because you are subscribed to the Google Groups "AWX Project" group.
To unsubscribe from this group and stop receiving emails from it, send an email to awx-project...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/awx-project/7bab5b4e-ff39-4d7d-b66d-c2b089de69f4n%40googlegroups.com.

m.ne...@cityscoot.eu

unread,
Sep 19, 2022, 4:53:05 AM9/19/22
to awx-p...@googlegroups.com
Hi,
You need to provide the container name after the pod i.e:

kubectl exec -ti -n yournamespace deploy/awx -c awx-task -- /bin/bash
kubectl exec -ti -n yournamespace deploy/awx -c awx-web -- /bin/bash
kubectl exec -ti -n yournamespace deploy/awx -c awx-ee -- /bin/bash
kubectl exec -ti -n yournamespace deploy/awx -c redis -- /bin/bash

Regards,
Antuelle78
> > <mailto:awx-project...@googlegroups.com>.
> > To view this discussion on the web visit
> > https://groups.google.com/d/msgid/awx-project/7bab5b4e-ff39-4d7d-b66d-c2b089de69f4n%40googlegroups.com <https://groups.google.com/d/msgid/awx-project/7bab5b4e-ff39-4d7d-b66d-c2b089de69f4n%40googlegroups.com?utm_medium=email&utm_source=footer>.
>
> --
> You received this message because you are subscribed to the Google
> Groups "AWX Project" group.
> To unsubscribe from this group and stop receiving emails from it, send
> an email to awx-project...@googlegroups.com
> <mailto:awx-project...@googlegroups.com>.
> To view this discussion on the web visit
> https://groups.google.com/d/msgid/awx-project/vunXq_igJ6dFqxanjFuAqW_fgpM1uaZUhr_vsWw0RiVi5_fTcFzcaFRrRR1bdwN_Dtv_rYrJqo4-mMfD9zSZJYfJBuuZpgDl9In79jMPNQ8%3D%40protonmail.com <https://groups.google.com/d/msgid/awx-project/vunXq_igJ6dFqxanjFuAqW_fgpM1uaZUhr_vsWw0RiVi5_fTcFzcaFRrRR1bdwN_Dtv_rYrJqo4-mMfD9zSZJYfJBuuZpgDl9In79jMPNQ8%3D%40protonmail.com?utm_medium=email&utm_source=footer>.
>

Gregory Machin

unread,
Sep 21, 2022, 4:55:15 PM9/21/22
to AWX Project
Hi,

Thanks for the assistance. 

-n <Name Space> was what I was missing. 

Regards
G

Reply all
Reply to author
Forward
0 new messages