Logging
Log File Location
Open a command prompt to an Axual server.
Platform Deploy
If you have installed the Axual platform using Platform Deploy then open the file < Axual Configuration >/setup.sh. The logs are stored in the directory given by the variable LOCAL_DATA_DIR.
Kubernetes/Helm
In Kubernets you can view a pods most recent logging using the command:
kubectl logs <<pod_name>> -n kafka
Sometimes it is necessary to search log file. On a Helm/Kubernetes installation you should setup a log collecotor to gathers the logs from each container into a central location. Tools. Generally, Kubernetes logs Kubernestes system logs to the /var/log/ directory. Each pod logs to the directory pods/<namespace>_<pod_name>_<pod_id>/<container_name>/. (Most Axual pods contain multiple containers.) In a production environment Kubernetes runs on a local operating system. Note though that if you are testing on a local OS such as Mac, Kubernetes runs on a Virtual Machine. To view the entire log file you will need to first enter the environment of the Virtual Machine. On a Mac you will need to either:
-
View the logs by attaching to a second docker container sharing the same logs directory.
docker run -it --privileged --pid=host debian nsenter -t 1 -m -u -n -i sh
-
Screen to the Virtual Machine (This may not work. Different Mac versions work in slightly different ways.)
screen ~/Library/Containers/com.docker.docker/Data/vms/0/tty
Please view Debugging Applications for more information on debugging applications. In that article we discuss Kubernetes status as describe as well as logging.