搜索

3.2. 为 Red Hat OpenShift GitOps 收集调试数据

download PDF

使用 oc adm must-gather CLI 命令收集有关与 Red Hat OpenShift GitOps 关联的集群的以下详情:

  • Red Hat OpenShift GitOps Operator 的订阅和命名空间。
  • ArgoCD 对象可用的命名空间,以及这些命名空间中的对象,如 ArgoCD, Applications, ApplicationSets, AppProjects, 和 configmaps
  • 由 Red Hat OpenShift GitOps Operator 管理的命名空间列表,以及来自这些命名空间中的资源。
  • 所有与 GitOps 相关的自定义资源对象和定义。
  • Operator 和 Argo CD 日志。
  • 警告和错误级事件。

先决条件

  • 以管理员身份登录到 OpenShift Container Platform 集群。
  • 已安装 OpenShift Container Platform CLI (oc)。
  • 已安装 Red Hat OpenShift GitOps Operator。

流程

  1. 进入到要存储调试信息的目录。
  2. 使用 Red Hat OpenShift GitOps must-gather 镜像运行 oc adm must-gather 命令:

    $ oc adm must-gather --image=registry.redhat.io/openshift-gitops-1/must-gather-rhel8:<image_version_tag> 1
    1
    GitOps 的 must-gather 镜像。

    示例命令

    $ oc adm must-gather --image=registry.redhat.io/openshift-gitops-1/must-gather-rhel8:v1.10.0

    must-gather 工具会创建一个以当前目录中 ./must-gather.local 开头的新目录。例如,./must-gather.local.4157245944708210399

  3. 从刚才创建的目录中创建压缩文件。例如,在使用 Linux 操作系统的计算机上运行以下命令:

    $ tar -cvaf must-gather.tar.gz must-gather.local.4157245944708210399 1
    1
    must-gather-local.4157245944708210399 替换为实际目录名称。
  4. 红帽客户门户中为您的问题单附上压缩文件。
Red Hat logoGithubRedditYoutubeTwitter

学习

尝试、购买和销售

社区

关于红帽文档

通过我们的产品和服务,以及可以信赖的内容,帮助红帽用户创新并实现他们的目标。

让开源更具包容性

红帽致力于替换我们的代码、文档和 Web 属性中存在问题的语言。欲了解更多详情,请参阅红帽博客.

關於紅帽

我们提供强化的解决方案,使企业能够更轻松地跨平台和环境(从核心数据中心到网络边缘)工作。

© 2024 Red Hat, Inc.