Skip to content

Enable Debug Logging on a Runtime Plane

On a Self-Managed or Partially Managed (D2P) runtime plane, set the DataServer log level from the connector UI.

Set the log level

  1. Open the connector and go to Access Control Configs → Kubernetes Configs → Logging.
  2. Select the level for:
    • Application Log Level — DEBUG / INFO / WARN / ERROR. The default is INFO.
    • Root Log Level — DEBUG / INFO / WARN / ERROR. The default is WARN.
  3. Select Save. The Runtime Manager redeploys the connector with the new log levels.

Read the logs

DataServer writes its logs to the /workdir/privacera-dataserver/logs/dataserver/ directory in the DataServer pod. The main log file is dataserver.log.

Replace the following placeholders with the actual values:

  • <namespace>: namespace of the runtime plane.
  • <dataserver-pod>: DataServer pod name.
  1. Find the DataServer pod:
    Bash
    kubectl get pods -n <namespace>
    
  2. Read the DataServer log file:
    Bash
    kubectl exec -it <dataserver-pod> -n <namespace> -- tail -f /workdir/privacera-dataserver/logs/dataserver/dataserver.log
    
  3. To see the console output of the pod, such as startup messages, run:
    Bash
    kubectl logs <dataserver-pod> -n <namespace>
    
  4. Copy the logs to your machine:
    Bash
    kubectl cp <namespace>/<dataserver-pod>:/workdir/privacera-dataserver/logs/dataserver ./dataserver-logs
    

Reset the log level

Debug logging writes a large volume of logs. After you collect the logs, set the log levels back to the defaults:

  1. Go to Access Control Configs → Kubernetes Configs → Logging.
  2. Set Application Log Level to INFO and Root Log Level to WARN.
  3. Select Save.

Note

Saving a log level change replaces the DataServer pod, and the log files in the pod are not kept. Copy the logs before you reset the log level.