|
1 | | -# Observability with Grafana Dashboard |
| 1 | +# Observability for CSI Driver |
2 | 2 |
|
3 | | -This document explains how to use the `grafana-dashboard` make target to install and configure observability tools, including Prometheus and Grafana, on your Kubernetes cluster. The setup uses Helm charts to install Prometheus and Grafana, provides a Prometheus data source, and applies a Grafana dashboard configuration. |
| 3 | +This document explains how to use the `grafana-dashboard`, `setup-tracing` make targets to install and configure observability tools. |
4 | 4 |
|
5 | 5 | ## Prerequisites |
6 | 6 |
|
@@ -183,4 +183,55 @@ kubectl logs <grafana-pod-name> -n monitoring |
183 | 183 |
|
184 | 184 | This setup provides a quick and easy way to enable observability using Grafana dashboards, ensuring that you have visibility into your Kubernetes cluster and CSI driver operations. |
185 | 185 |
|
186 | | ---- |
| 186 | +--- |
| 187 | + |
| 188 | +## Steps to Opt-In for Tracing in the CSI Driver |
| 189 | + |
| 190 | +To enable the tracing for the Linode CSI driver, follow the steps below. These steps involve exporting a new Helm template with tracing enabled, deleting the current CSI driver release, and applying the newly generated configuration. |
| 191 | + |
| 192 | +### 1. Export the Helm Template for the CSI Driver with Tracing Enabled |
| 193 | + |
| 194 | +First, you need to generate a new Helm template for the Linode CSI driver with the `enableTracing` flag set to `true`. You will also have to specify an address that isn't in use for the otel server to run on. By default, the port is set to `4318`. |
| 195 | + |
| 196 | +```bash |
| 197 | +helm template linode-csi-driver \ |
| 198 | + --set apiToken="${LINODE_API_TOKEN}" \ |
| 199 | + --set region="${REGION}" \ |
| 200 | + --set enableTracing="true" \ |
| 201 | + --set tracingPort="4318" \ |
| 202 | + helm-chart/csi-driver --namespace kube-system > csi.yaml |
| 203 | +``` |
| 204 | + |
| 205 | +### 2. Delete the Existing Release of the CSI Driver |
| 206 | + |
| 207 | +Before applying the new configuration, you need to delete the current release of the Linode CSI driver. This step is necessary because the default CSI driver installation does not have tracing enabled, and Helm doesn’t handle changes to some components gracefully without a clean reinstall. |
| 208 | + |
| 209 | +```bash |
| 210 | +kubectl delete -f csi.yaml --namespace kube-system |
| 211 | +``` |
| 212 | + |
| 213 | +### 3. Apply the Newly Generated Template |
| 214 | + |
| 215 | +Once the old CSI driver installation is deleted, you can apply the newly generated template that includes the tracing configuration. |
| 216 | + |
| 217 | +```bash |
| 218 | +kubectl apply -f csi.yaml |
| 219 | +``` |
| 220 | + |
| 221 | +## Steps to Install otel and jaeger for visualizing traces |
| 222 | + |
| 223 | +### 1. Run the Tracing setup |
| 224 | + |
| 225 | +The make target `setup-tracing` installs `otel-collector` and `jaeger` for visualizing the traces. |
| 226 | + |
| 227 | +```bash |
| 228 | +make setup-tracing |
| 229 | +``` |
| 230 | + |
| 231 | +### 2. Access the Jaeger Dashboard |
| 232 | + |
| 233 | +Once the setup is complete, you can access the jaeger dashboard through the configured LoadBalancer service. After the setup script runs, the external IP of the LoadBalancer is printed, and you can access Jaeger by opening the following URL in your browser: |
| 234 | + |
| 235 | +``` |
| 236 | +http://<LoadBalancer-EXTERNAL-IP>:16686 |
| 237 | +``` |
0 commit comments