How can I get access to the controller and the NodeAgent logs and status?
Thundernetes controller Pod and NodeAgent Pods are installed in the thundernetes-system namespace by default.
- You can see the status of the controller Deployment with
kubectl get deploy -n thundernetes-system thundernetes-controller-manager. This will give you a result like:
NAME READY UP-TO-DATE AVAILABLE AGE thundernetes-controller-manager 1/1 1 1 2h
- To get the controller Pod logs, you need to find the Pod name. Run
kubectl get pods -n thundernetes-systemand look for the name of the controller Pod. It should be something likethundernetes-controller-manager-774c99cd4-6tq8w. Then you can dokubectl logs -n thundernetes-system thundernetes-controller-manager-774c99cd4-6tq8wto see the controller logs. - To see the NodeAgent status you can run
kubectl get ds -n thundernetes-system, since NodeAgent is installed as a Kubernetes DaemonSet. You will see an output similar to this:
NAME DESIRED CURRENT READY UP-TO-DATE AVAILABLE NODE SELECTOR AGE thundernetes-nodeagent 3 3 3 3 3 <none> 2h
- To see the logs for a NodeAgent Pod, you need to find the Pod name. Run
kubectl get pods -n thundernetes-systemand look for the name of the NodeAgent Pod. It should be something likethundernetes-nodeagent-4fdb9. Then you can dokubectl logs -n thundernetes-system thundernetes-nodeagent-4fdb9to see the NodeAgent logs. - If you want to see the logs for a NodeAgent in a particular Node (e.g. if you need to debug communication between the NodeAgent and a GameServer Pod), you need to first find out the Node name.
- Run
kubectl get pods -owideso you can see the Node name that the Pod you want to debug is running on. - Run
kubectl get pods -n thundernetes-system -owideso you can see the Node name along with all the NodeAgent Pods. - As soon as you find out the NodeAgent Pod you want to get its logs, you can run
kubectl logs -n thundernetes-system thundernetes-nodeagent-XXXXXto get this NodeAgent Pod logs.
- Run