Question: Is there a way to get some details about Kubernetes pod that was deleted (stopped, replaced by new version).

I am investigating bug. I have logs with my pod name. That pod does not exist anymore, it was replaced by another one (with different configuration). New pod resides in same namespace, replication controller and service as old one.

Commands like

```
kubectl  get pods
kubectl  get pod <pod-name> 

```

work only with current pods (live or stopped). 

How I could get more details about old pods? I would like to see

1. when they were created
2. which environment variables they had when created
3. why and when they were stopped

Answer: 
as far as i know you may not get the pod details once the pod is deleted. can i know what is the usecase? 

example:

1. if a pod created using - kubectl run busybox-test-pod-status --image=busybox --restart=Never -- /bin/false
you will have a pod with status termiated:error
2. if a pod is created using - kubectl run busybox-test-pod-status --image=busybox --restart=Never -- /bin/true
you will have pod with status terminated:Complted
3. if container in a pods restarts: the pod will be alive and you can get the logs of previous container (only the previous container) using
kubectl logs --container < container\_name > --previous=true < pod\_name >
4. if you doing an upgrade of you app and you are creating pods using deployments. if the update deployment "say a new image". pod will be terminated and new pod will be created. you can get the pod details from depoyment yaml. if you want to get details of previous pod you have see "spec" section of previous deployment yaml
```
kubectl get pods -a    

```

you will get the list of running pods and the terminated pods in case you are searching for this