Automation Suite
2023.10
False
横幅背景图像
Linux 版 Automation Suite 安装指南
上次更新日期 2024年4月19日

如何启用 Istio 日志记录

要调试 Istio,您需要启用日志记录。为此,请执行以下步骤:

  1. 通过运行以下命令查找 istio-ingressgateway Pod。复制网关 Pod 名称。它应该类似于 istio-ingressgateway-r4mbx
    kubectl -n istio-system get podskubectl -n istio-system get pods
  2. 通过运行以下命令打开网关 Pod Shell。

    kubectl exec -it -n istio-system istio-ingressgateway-r4mbx bashkubectl exec -it -n istio-system istio-ingressgateway-r4mbx bash
  3. 通过运行以下命令启用调试级别的日志记录。

    curl -X POST http://localhost:15000/logging?level=debugcurl -X POST http://localhost:15000/logging?level=debug
  4. 从服务器节点运行以下命令。

    istioctl_bin=$(find /var/lib/rancher/rke2/ -name "istioctl" -type f -perm -u+x   -print -quit)
    if [[ -n ${istioctl_bin} ]]
    then
    echo "istioctl bin found"
      kubectl -n istio-system get cm istio-installer-base -o go-template='{{ index .data "istio-base.yaml" }}'  > istio-base.yaml
      kubectl -n istio-system get cm istio-installer-overlay  -o go-template='{{ index .data "overlay-config.yaml" }}'  > overlay-config.yaml 
      ${istioctl_bin} -i istio-system install -y -f istio-base.yaml -f overlay-config.yaml --set meshConfig.accessLogFile=/dev/stdout --set meshConfig.accessLogEncoding=JSON 
    else
      echo "istioctl bin not found"
    fiistioctl_bin=$(find /var/lib/rancher/rke2/ -name "istioctl" -type f -perm -u+x   -print -quit)
    if [[ -n ${istioctl_bin} ]]
    then
    echo "istioctl bin found"
      kubectl -n istio-system get cm istio-installer-base -o go-template='{{ index .data "istio-base.yaml" }}'  > istio-base.yaml
      kubectl -n istio-system get cm istio-installer-overlay  -o go-template='{{ index .data "overlay-config.yaml" }}'  > overlay-config.yaml 
      ${istioctl_bin} -i istio-system install -y -f istio-base.yaml -f overlay-config.yaml --set meshConfig.accessLogFile=/dev/stdout --set meshConfig.accessLogEncoding=JSON 
    else
      echo "istioctl bin not found"
    fi

此页面是否有帮助?

获取您需要的帮助
了解 RPA - 自动化课程
UiPath Community 论坛
Uipath 白色徽标
信任与安全
© 2005-2024 UiPath. All rights reserved.