For an overview of this repository and the services in it, go to the top-level README. To view logs from deployed services, follow this guide.
We have the following types of logs:
More background on the infrastructure as a whole can be found at ./infrastructure.md
.
Prometheus gathers logs from a Kubernetes cluster. It runs as a kubernetes pod automatically included with Istio, which we use to manage ingress and egress from our Kubernetes cluster.
To view the logs, use one of the following means:
For more on getting started with Prometheus, go to the Prometheus docs, or watch this introductory talk from Prometheus co-founder Julius Volz.
You will need to target a specific kubernetes cluster for which you'd like to see logs. See our docs on connection to a Kubernetes cluster.
Once you're targeting a Kubernetes cluster, run the following command to see its logs.
istioctl dashboard prometheus
Alternatively, to see Prometheus logs, you can run a query in the Azure Log Analytics workspace.
- Open the "Log Analytics workspaces" area in the Azure portal.
- Open the analytics workspace which is in the same resource group as your cluster.
- Click "Logs" in the sidebar.
- Run the following the query:
InsightsMetrics
| where Namespace == "prometheus"
To view all of the logs for the doc-index-updater:
stern -n doc-index-updater doc-index-updater
A useful command for viewing the logs related to a specific correlation id
would be to use the -i
or --include
parameter with a regex
which looks for INFO
, WARN
, and ERROR
messages matching that id.
See here, for b9912c04-325e-4f1b-8943-3ef319a88989
:
stern doc-index-updater -n doc-index-updater -i 'level.:.(INFO|WARN|ERROR).*b9912c04-325e-4f1b-8943-3ef319a88989'
See the stern docs for more info.