跳转到主内容

如何收集 Secd 跟踪

Views:
55
Visibility:
Public
Votes:
0
Category:
ontap-9
Specialty:
nas
Last Updated:

适用场景

ONTAP 9

问题描述

  • 在对与身份验证相关的问题描述进行故障排除时,可能需要增加安全守护进程( SECD )的详细程度。
  • 以下概述了与 diag level 命令关联的选项及其建议的用法。
    • 诊断级别命令只能在提供指导的情况下使用 NetApp 支持
    • 默认情况下, secd 只记录错误和失败的 RPC 命令
      • 完成故障排除后,清除跟踪。
      • 这样可以使活动跟踪保持运行状态,从而确保系统不会产生额外开销。
      • 要清除,请对所有节点执行以下操作: ::*> diag secd trace clear -node <node> -vserverids yes

追加信息

  • SECD 是一个 diag 命令,因此这些示例不会记录在任何面向公众的信息中。
    • 以下示例说明了运行哪个命令 跟踪
    • 请完整阅读本文档,了解所有不同的选项:

test1::*> diag secd trace set -node test1-01 -vserverids main -trace-all yes

Secd 跟踪设置基础知识:

  • secd  使用限制为诊断级别
  • set diag 必须在运行命令之前调用。
    • 命令示例:

test1::*> diag secd trace ?
clear                       *Clear Trace Options
set                         *Set Trace Options
show                        *Show Trace

  • 使用 show 选项确认当前跟踪设置。
    • 如果跟踪设置与参数匹clear配,请使用选项删除所有当前设置。    

test1::*> diag secd trace show -node test1-01
Trace Spec
---------------------------------------

Trace spec has not been set.

  • 以下是设置跟踪时可用的参数。 
    • 注意:每次 set 运行命令时都需要节点: 

 test1::*> diag secd trace set ?
   [-node] <nodename>                   *Node
  [[-trace-all] {yes|no}]               *Trace All RPCs
  [ -vserverids <vserver>, ... ]        *Id List
  [ -ipaddrs <text>, ... ]              *Address List
  [ -domain-names <text>, ... ]         *Domain List
  [ -dc-names <text>, ... ]             *DC List
  [ -rpc-names <rpc_name>, ... ]        *RPC List
  [ -module-names <module_name>, ... ]  *Module List
  [ -trace-connectivity {yes|no} ]      *Trace Connection Errors

  • 以下示例将在节点上设置一个跟踪 test1-01, ,其中包括一个名为 "main" 的 Storage Virtual Machine ( SVM )。 

test1::*> diag secd trace set -node test1-01 -vserverids main -trace-all yes
Trace spec is set successfully for trace-all Vservers.

  • 检查跟踪参数:

test1::*> diag secd trace show -node test1-01
Trace Spec
---------------------------------------
TraceAll:                     Tracing all RPCs
Vserver IDs:                  main

  • 注意
    • 与 "set" 关联的命令是累积的,与 "clear关联的命令是减量的。
    • 因此,基于上述示例,通过运行以下命令将捕获限制为特定域:

test1::diag secd trace set -node test1-01 -domain-names test
Trace spec is set successfully for domains.

test1::diag secd trace show -node test1-01
Trace Spec
---------------------------------------
TraceAll:                     Tracing all RPCs
Domain names:                 test
Vserver IDs:                  main

  • 注意
    • 将域添加到包含 SVM ID 的现有跟踪参数中,以及添加要筛选的 IP 地址,如下所示:
    • 将跟踪限制为一组特定的 IP 地址:

test1:: secd trace set -node test1-01 -ipaddrs 10.10.10.10,10.10.10.11,10.10.10.12,10.10.10.13
Trace spec is set successfully for ipaddrs.

  • 跟踪筛选器现在包括 SVM ID ,域和特定 IP 地址列表: 

test1::diag secd*> trace show  -node test1-01                                                                         
Trace Spec   
---------------------------------------
TraceAll:                     Tracing all RPCs
IP Addrs:                     10.10.10.10 10.10.10.11 10.10.10.12 10.10.10.13 
Domain names:                 test
Vserver IDs:                  main

  • 如上所述, clear 此选项为减值。
    • 如下面的帮助上下文中所述,与每个参数相关的输入是“是”或“否”。

  test1::diag secd*> trace clear ?
   [-node] <nodename>               *Node
  [[-trace-all] {yes|no}]           *Clear Trace All
  [ -vserverids {yes|no} ]          *Clear VserverIds
  [ -ipaddrs {yes|no} ]             *Clear Ipaddrs
  [ -domain-names {yes|no} ]        *Clear Domains
  [ -dc-names {yes|no} ]            *Clear DC
  [ -rpc-names {yes|no} ]           *Clear RPC
  [ -module-names {yes|no} ]        *Clear Module
  [ -trace-connectivity {yes|no} ]  *Clear Trace Connection Errors

  • 因此,假设以下命令清除整个条目以作为一个假假定(如show下面的输出所示),请确保清除所有条目。
  • 注意:如果未正确清除参数,则可能会在未来的日志收集工作中出现发生原因问题: 

test1::diag secd trace clear  -node test1-01 -trace-all yes

test1::diag secd trace show  -node test1-01
Trace Spec
---------------------------------------
IP Addrs:                     10.10.10.10 10.10.10.11 10.10.10.12 10.10.10.13
Domain names:                 test
Vserver IDs:                  main

  • 以下语法将完全删除跟踪条目:

test1::diag secd trace clear -node test1-01 -ipaddrs yes -domain-names yes -vserverids yes

test1::diag secd trace show  -node test1-01
Trace Spec
---------------------------------------
Trace spec has not been set.

操作步骤 - 实际跟踪收集:
  • 使用上述信息可以成功设置跟踪参数。
  • 如果您不确定要启用的特定模块、最好使用trace-all yes该设置来确保捕获尽可能多的数据。
  • 请执行以下步骤:
  1. 在重现问题之前,请运行show命令以验证参数并将其包含在病例数据中。
    注意:
    1 )确保仅在复制期间启用跟踪。复制完成后,请立即禁用跟踪功能。
    2 )必须记录复制过程中涉及的所有相关信息。
        时间 / 日期,用户名和信息, IP 地址及其所属人员(客户端, LIF , DC ),文件名,卷,
    共享信息将极大地有助于日志分析。
     
  2. 有关跟踪集合序列的信息、请参见以下示例:

 test1::> set d
Warning: These diagnostic commands are for use by NetApp personnel only.
Do you want to continue? {y|n}: y

test1::*> diag secd trace show -node test1-01
 Trace Spec
---------------------------------------
Trace spec has not been set.

test1::*> diag secd trace set -node test1-01 -vserverids main -trace-all yes
Trace spec set successfully for trace-all, Vservers.

test1::*> diag secd trace show -node test1-01
Trace Spec
---------------------------------------
TraceAll:                     Tracing all RPCs
Vserver IDs:                  main

 

  1. 活动完成后,完全清除跟踪的所有方面。
    运行show命令以验证尚未设置跟踪。
    test1::*> diag secd trace set -node test1-01 -vserverids main -trace-all no
    Trace spec set successfully for Vservers.
    Trace spec cleared successfully for trace-all.

    test1::*> diag secd trace show -node test1-01
    Trace Spec
    ---------------------------------------
    Vserver IDs:                  main

    test1::*> diag secd trace clear -node test1-01 -vserverids yes

    test1::*> diag secd trace show -node test1-01
    Trace Spec
    ---------------------------------------
    Trace spec has not been set.

     
  2. 两个节点生成类型“所有 AutoSupport ”(这将上载 secd 跟踪数据):
    ::> autosupport invoke * -type all
    注:用户也可以上载 secd 日志(/etc/log/mlog)。

 

Sign in to view the entire content of this KB article.

New to NetApp?

Learn more about our award-winning Support

NetApp provides no representations or warranties regarding the accuracy or reliability or serviceability of any information or recommendations provided in this publication or with respect to any results that may be obtained by the use of the information or observance of any recommendations provided herein. The information in this document is distributed AS IS and the use of this information or the implementation of any recommendations or techniques herein is a customer's responsibility and depends on the customer's ability to evaluate and integrate them into the customer's operational environment. This document and the information contained herein may be used solely in connection with the NetApp products discussed in this document.