• 产品与解决方案
  • 行业解决方案
  • 服务
  • 支持
  • 合作伙伴
  • 新华三人才研学中心
  • 关于我们

11-网络管理和监控配置指导

目录

20-GOLD配置

本章节下载 20-GOLD配置  (201.82 KB)

docurl=/cn/Service/Document_Software/Document_Center/Home/Switches/00-Public/Configure/Operation_Manual/H3C_S6850_S9850_CG-R655x/11/202211/1723797_30005_0.htm

20-GOLD配置


1 GOLD

1.1  GOLD简介

GOLD(Generic OnLine Diagnostics,通用在线诊断)通过在设备上执行诊断测试例,来发现硬件故障,并进行问题报告。GOLD检查的硬件故障主要包括:端口、内存、芯片、连接、转发路径以及控制路径是否正常等。

1.1.1  诊断类型

GOLD支持的诊断类型包括:

·     监控诊断(Monitoring Diagnostics):设备在运行过程中按照一定的时间间隔执行测试例,来周期检测系统中的硬件是否故障并记录诊断结果。监控诊断只能执行非破坏性的测试例。

·     按需诊断(On-Demand Diagnostics):在设备运行过程中,当用户怀疑硬件故障时,可以手工启动/停止某些测试例对设备进行诊断,这种诊断称为按需诊断。

1.1.2  测试例

GOLD使用测试例来描述诊断(测试)的内容。测试例的内容(参数)包括测试的名称、诊断的类型、描述信息、属性(破坏性的/非破坏性的等)、缺省是否执行以及执行的时间等。设备支持哪些测试例以及测试例内容的缺省值与设备的型号以及启动软件包版本有关,由开发人员根据产品需求在软件开发阶段指定。测试例的部分参数用户可以使用本文中提供的命令行修改,其它参数则不能修改。测试例压缩在System包中,和System包一起发布、安装。所有测试例开启后,均在后台执行,用户可以通过相应的display命令查看测试结果或者日志信息来判断设备是否出现了硬件故障。

1.2  GOLD配置任务简介

GOLD配置任务如下:

(1)     配置诊断

请至少选择其中一项进行配置。

¡     配置监控诊断

¡     配置按需诊断

(2)     (可选)模拟诊断结果

(3)     (可选)配置GOLD日志存储参数

1.3  配置监控诊断

1. 功能简介

对于缺省开启的监控诊断测试例,在设备启动后会自动执行;对于缺省没有开启的监控诊断测试例,需通过diagnostic monitor enable命令开启监控诊断功能。

开启监控诊断测试例后,测试例会按照指定的时间间隔执行。

2. 配置步骤

(1)     进入系统视图。

system-view

(2)     开启监控诊断功能。

diagnostic monitor enable slot slot-number-list [ test test-name ]

缺省情况下,监控诊断功能处于开启状态。

(3)     配置监控诊断测试例的执行时间间隔。

diagnostic monitor interval slot slot-number-list [ test test-name ] time interval

缺省情况下,不同测试例的执行时间间隔不同,请使用display diagnostic content命令查看。

interval的值不能小于监控诊断测试例要求的最小值。执行携带verbose参数的display diagnostic content命令,通过显示信息中的Min interval字段可获知监控诊断测试例要求的最小值。

1.4  配置按需诊断

1. 功能简介

按需诊断由设备管理维护人员根据设备当前状态开始或者停止运行。

按需诊断测试例启动后,何时停止执行,受三条命令的限制:

·     使用diagnostic ondemand stop命令可立即停止执行该测试例。

·     如果某测试例的执行次数达到diagnostic ondemand repeating命令中指定的值,则系统会自动停止执行该测试例。

·     如果某测试例累计失败的执行次数已达到diagnostic ondemand failure命令中指定的值,则系统会自动停止执行该测试例。

2. 配置限制和指导

所有配置的diagnostic ondemand关键字开头的命令行只在设备的本次运行过程中生效,设备重启后这些命令将恢复到缺省情况。

3. 配置步骤

请在用户视图下,进行如下配置:

(1)     配置按需诊断的重复执行次数。

diagnostic ondemand repeating repeating-number

缺省情况下,按需类型诊断测试例重复执行的次数为1次,表示执行一次就结束。

本命令对当前已经启动、执行的按需诊断测试例不生效,只对后续启动的测试例生效。

(2)     配置按需诊断的累计失败执行次数。

diagnostic ondemand failure failure-number

缺省情况下,不限制按需测试例的累计失败执行次数的最大值。

配置时,failure-number的值必须小于等于repeating-number的值。

本命令对当前已经启动、执行的按需诊断测试例不生效,只对后续启动的测试例生效。

(3)     启动按需类型诊断。

diagnostic ondemand start slot slot-number-list test { test-name | non-disruptive } [ para parameters ]

若没有进行前两个配置操作,启动时按缺省配置启动。

(4)     (可选)手工停止按需类型诊断。

diagnostic ondemand stop slot slot-number-list test { test-name | non-disruptive }

用户可以手动停止所有的按需类型测试例。

1.5  模拟诊断结果

1. 功能简介

用户可通过将监控诊断测试例或者按需诊断测试例的执行方式设置为模拟方式来判断GOLD模块框架功能是否正常。在该方式下,当测试例满足执行条件时,系统会执行测试例的部分代码并生成测试结果,但是不会进行硬件纠错操作,例如重启或者主备倒换。

2. 配置步骤

请在用户视图下执行以下命令,设置诊断的执行方式为模拟方式。

diagnostic simulation slot slot-number-list test test-name { failure | random-failure | success }

缺省情况下,诊断为非模拟方式。即启动测试例后,系统会真正执行该测试例。

1.6  配置GOLD日志存储参数

1. 功能简介

GOLD会自动生成日志,用于记录测试例的执行结果等信息。用户可以通过display diagnostic event-log命令查看这些日志。

2. 配置步骤

(1)     进入系统视图。

system-view

(2)     配置可存储的GOLD日志的最大条数。

diagnostic event-log size number

缺省情况下,可存储的GOLD日志的最大条数为512条。

当产生的日志条数超过用户配置的最大条数时,GOLD会自动删除最老日志。

1.7  GOLD显示和维护

在完成上述配置后,在任意视图下执行display命令可以显示配置后GOLD的运行情况,通过查看显示信息验证配置的效果。

在用户视图下执行reset命令可以清除GOLD日志信息和诊断测试结果。

表1-1 GOLD显示和维护

操作

命令

显示启动诊断测试例的信息

display diagnostic bootup [ slot slot-number [ test test-name ] ]

显示设备本次启动时生效的启动诊断的级别

display diagnostic bootup level

显示测试例的内容

display diagnostic content [ slot slot-number ] [ verbose ]

显示GOLD日志的信息

display diagnostic event-log [ error | info ]

显示按需诊断的配置信息

display diagnostic ondemand configuration

显示测试例的执行结果

display diagnostic result [ slot slot-number [ test test-name ] ] [ verbose ]

显示与报文相关的测试例的统计信息

display diagnostic result [ slot slot-number [ test test-name ] ] statistics

显示模拟诊断的配置信息

display diagnostic simulation [ slot slot-number ]

清除GOLD日志

reset diagnostic event-log

清除诊断测试结果

reset diagnostic result [ slot slot-number [ test test-name ] ]

 

1.8  GOLD典型配置举例

1.8.1  GOLD基本配置举例

1. 组网需求

在slot 1上,开启监控诊断测试例PortMonitor并配置测试例的时间间隔为1分钟。

2. 配置步骤

# 查看slot 1上监控诊断测试例的缺省开启状态和时间间隔。

<Sysname> display diagnostic content slot 1 verbose

Diagnostic test suite attributes:

#B/*: Bootup test/NA

#O/*: Ondemand test/NA

#M/*: Monitoring test/NA

#D/*: Disruptive test/Non-disruptive test

#P/*: Per port test/NA

#A/I/*: Monitoring test is active/Monitoring test is inactive/NA

 

Slot 1 cpu 0:

Test name        : PortMonitor

Test attributes  : **M*PI

Test interval    : 00:00:10

Min interval     : 00:00:10

Correct-action   : -NA-

Description       : A Real-time test, disabled by default that checks link status between ports.

# 开启slot 1上的监控诊断测试例PortMonitor。

<Sysname> system-view

[Sysname] diagnostic monitor enable slot 1 test PortMonitor

# 配置slot 1上的监控诊断测试例PortMonitor的时间间隔为1分钟。

[Sysname] diagnostic monitor interval slot 1 test PortMonitor time 0:1:0

3. 验证配置

# 查看配置的结果。

[Sysname] display diagnostic content slot 1 verbose

Diagnostic test suite attributes:

#B/*: Bootup test/NA

#O/*: Ondemand test/NA

#M/*: Monitoring test/NA

#D/*: Disruptive test/Non-disruptive test

#P/*: Per port test/NA

#A/I/*: Monitoring test is active/Monitoring test is inactive/NA

 

Slot 1 cpu 0:

Test name        : PortMonitor

Test attributes  : **M*PA

Test interval    : 00:01:00

Min interval     : 00:00:10

Correct-action   : -NA-

Description       : A Real-time test, disabled by default that checks link status between ports.

# 查看slot 1上监控诊断测试例的执行结果。

[Sysname] display diagnostic result slot 1 verbose

Slot 1 cpu 0:

  Test name                : PortMonitor

  Total run count          : 1247

  Total failure count      : 0

  Consecutive failure count: 0

  Last execution time      : Tue Dec 25 18:09:21 2012

  First failure time       : -NA-

  Last failure time        : -NA-

  Last pass time           : Tue Dec 25 18:09:21 2012

  Last execution result    : Success

  Last failure reason      : -NA-

  Next execution time      : Tue Dec 25 18:10:21 2012

  Port link status : Normal

不同款型规格的资料略有差异, 详细信息请向具体销售和400咨询。H3C保留在没有任何通知或提示的情况下对资料内容进行修改的权利!

新华三官网
联系我们