Skip to main content
简体中文版经机器翻译而成,仅供参考。如与英语版出现任何冲突,应以英语版为准。

生成Trident Protect支持包

贡献者 netapp-mwallis netapp-shwetav

Trident Protect 使管理员能够生成包含对NetApp支持有用的信息的捆绑包,包括有关所管理的集群和应用程序的日志、指标和拓扑信息。如果您已连接到互联网,则可以使用自定义资源 (CR) 文件将支持包上传到NetApp支持站点 (NSS)。

使用CR创建支持包
步骤
  1. 创建自定义资源(CR)文件并将其命名(例如 trident-protect-support-bundle.yaml)。

  2. 配置以下属性:

    • 。metadata.name:(required_)此自定义资源的名称;请为您的环境选择一个唯一且合理的名称。

    • spec.t触发 器Type:(required)用于确定是立即生成支持包、还是按计划生成支持包。计划在UTC时间中午12点生成捆绑包。可能值:

      • 已计划

      • 手动

    • spec.u倍 加载已启用:(可 选)控制是否应在生成支持包后将其上传到NetApp支持站点。如果未指定,则默认为 false。可能值:

      • true

      • false (默认)

    • spec.dataWindowStart:(可 选) RFC 3339格式的日期字符串,指定支持包中包含的数据窗口应开始的日期和时间。如果未指定、则默认为24小时前。您可以指定的最早窗口日期是7天前。

      YAML示例:

    ---
    apiVersion: protect.trident.netapp.io/v1
    kind: AutoSupportBundle
    metadata:
      name: trident-protect-support-bundle
    spec:
      triggerType: Manual
      uploadEnabled: true
      dataWindowStart: 2024-05-05T12:30:00Z
  3. 填充后 `trident-protect-support-bundle.yaml`具有正确值的文件,应用 CR:

    kubectl apply -f trident-protect-support-bundle.yaml -n trident-protect
使用命令行界面创建支持包
步骤
  1. 创建支持包、将括号中的值替换为您环境中的信息。 trigger-type`确定是否立即创建分发包,或者是否由计划决定了创建时间,可以是 `Manual`或 `Scheduled。默认设置为 Manual

    例如:

    tridentctl-protect create autosupportbundle <my-bundle-name> --trigger-type <trigger-type> -n trident-protect

监视和检索支持包

使用任一方法创建支持包后,您可以监视其生成进度并将其检索到本地系统。

步骤
  1. 等待 `status.generationState`到达 `Completed`状态。您可以使用以下命令监控生成进度:

    kubectl get autosupportbundle trident-protect-support-bundle -n trident-protect
  2. 将支持包检索到您的本地系统。从已完成的AutoSupport包中获取复制命令:

    kubectl describe autosupportbundle trident-protect-support-bundle -n trident-protect

    找到 `kubectl cp`从输出中执行命令并运行它,用您喜欢的本地目录替换目标参数。