H3C路由器故障日志介绍
logfile日志 logfileX.log 命令行记录、设备运行中产生的记录信息diagfile日志 diagfileX.log 设备运行中产生的诊断日志信息,如系统运行到错误流程时的参数值、单板无法启动时的信息、主控板与接口板通信异常时的握手信息。
诊断信息 XXX.gz
系统当前多个功能模块运行的统计信息,包括设备状态、CPU状态、内存状态、配置情况、软件表项、硬件表项等收集诊断信息会导致设备性能下降,请谨慎使用
对于 logfile 日志和 diagfile 日志,当日志文件写满,产生新的日志文件时,设备会将旧的日志文件自动压缩成.gz 文件
logfile 日志
(1) 执行 logfile save 命令将日志文件缓冲区中的内容全部保存到日志文件中。日志文件缺省
存储在存储介质的 logfile 目录中。
<Sysname> logfile save
The contents in the log file buffer have been saved to the file
cfa0:/logfile/logfile8.log
(2) 查看日志文件的数目和名称。
查看设备的 logfile 日志:(集中式设备)
<Sysname> dir cfa0:/logfile/
Directory of cfa0:/logfile
0 -rw- 21863 Jul 11 2013 16:00:37 logfile8.log
1021104 KB total (421552 KB free)
查看主设备的 logfile 日志:(集中式 IRF 设备)
<Sysname> dir flash:/logfile/
Directory of flash:/logfile
0 -rw- 21863 Jul 11 2013 16:00:37 logfile.log
1021104 KB total (421552 KB free)
查看成员设备的 logfile 日志:(集中式 IRF 设备)
<Sysname> dir slot2#flash:/logfile/
Directory of slot2#flash:/logfile
0 -rw- 21863 Jul 11 2013 16:00:37 logfile.log
1021104 KB total (421552 KB free)
查看设备主用主控板的 logfile 日志:(分布式设备-独立运行模式)
<Sysname> dir cfa0:/logfile/
Directory of cfa0:/logfile
0 -rw- 21863 Jul 11 2013 16:00:37 logfile8.log
1021104 KB total (421552 KB free)
查看设备备用主控板的 logfile 日志:(分布式设备-独立运行模式)
<Sysname> dir slot1#cfa0:/logfile/
Directory of slot1#cfa0:/logfile
0 -rw- 21863 Jul 11 2013 16:00:37 logfile8.log
1021104 KB total (421552 KB free)
0 -rw- 21863 Jul 11 2013 16:00:37 logfile8.log
1021104 KB total (421552 KB free 查看主设备主用主控板的 logfile 日志:(分布式设备-IRF 模式)
<Sysname> dir cfa0:/logfile/
Directory of cfa0:/logfile
0 -rw- 21863 Jul 11 2013 16:00:37 logfile8.log
1021104 KB total (421552 KB free)
查看主设备备用主控板的 logfile 日志:(分布式设备-IRF 模式)
<Sysname> dir slot1#cfa0:/logfile/
Directory of slot1#cfa0:/logfile
0 -rw- 21863 Jul 11 2013 16:00:37 logfile8.log
1021104 KB total (421552 KB free)
查看成员设备主控板的 logfile 日志,如果备设备有两块主控板,则两块都需要检查:(分布式
设备-IRF 模式)
<Sysname> dir chassis2#slot0#cfa0:/logfile/
Directory of chassis2#slot0#cfa0:/logfile
0 -rw- 21863 Jul 11 2013 16:00:37 logfile8.log
1021104 KB total (421552 KB free)
使用 FTP、TFTP 或者 USB 接口将日志文件传输到指定位置。
diagfile 日志
(1) 执行 diagnostic-logfile save 命令将诊断日志文件缓冲区中的内容全部保存到诊断日
志文件中。诊断日志文件缺省存储在存储介质的 diagfile 目录中。
<Sysname> diagnostic-logfile save
The contents in the diagnostic log file buffer have been saved to the file
cfa0:/diagfile/diagfile18.log 查看诊断日志文件的数目和名称。
•查看设备的 diagfile 日志:(集中式设备)
<Sysname> dir cfa0:/diagfile/
Directory of cfa0:/diagfile
0 -rw- 161321 Jul 11 2013 16:16:00 diagfile18.log
1021104 KB total (421416 KB free) 查看主设备的 diagfile 日志:(集中式 IRF 设备)
<Sysname> dir flash:/diagfile/
Directory of flash:/diagfile
0 -rw- 161321 Jul 11 2013 16:16:00 diagfile18.log
1021104 KB total (421416 KB free)
查看成员设备的 diagfile 日志:(集中式 IRF 设备)
<Sysname> dir slot2#flash:/diagfile/
Directory of slot2#flash:/diagfile
0 -rw- 161321 Jul 11 2013 16:16:00 diagfile18.log
1021104 KB total (421416 KB free) 查看设备主用主控板的 diagfile 日志:(分布式设备-独立运行模式)
<Sysname> dir cfa0:/diagfile/
Directory of cfa0:/diagfile
0 -rw- 161321 Jul 11 2013 16:16:00 diagfile18.log
1021104 KB total (421416 KB free)
查看设备备用主控板的 diagfile 日志:(分布式设备-独立运行模式)
<Sysname> dir slot1#cfa0:/diagfile/
Directory of slot1#cfa0:/diagfile
0 -rw- 161321 Jul 11 2013 16:16:00 diagfile18.log
1021104 KB total (421416 KB free) 查看主设备主用主控板的 diagfile 日志:(分布式设备-IRF 模式)
<Sysname> dir cfa0:/diagfile/
Directory of cfa0:/diagfile
0 -rw- 161321 Jul 11 2013 16:16:00 diagfile18.log
1021104 KB total (421416 KB free)
查看主设备备用主控板的 diagfile 日志:(分布式设备-IRF 模式)
<Sysname> dir slot1#cfa0:/diagfile/
Directory of slot1#cfa0:/diagfile
0 -rw- 161321 Jul 11 2013 16:16:00 diagfile18.log
1021104 KB total (421416 KB free)
查看成员设备主控板的 diagfile 日志,如果成员设备有两块主控板,则两块都需要检查:(分布式设备-IRF 模式)
<Sysname> dir chassis2#slot0#cfa0:/diagfile/
Directory of chassis2#slot0#cfa0:/diagfile
0 -rw- 161321 Jul 11 2013 16:16:00 diagfile18.log
1021104 KB total (421416 KB free)
使用 FTP、TFTP 或者 USB 接口将诊断日志文件传输到指定位置 诊断信息可以通过两种方式收集:将诊断信息保存到文件,或者将诊断信息直接显示在屏幕上。为保证信息收集的完整性,建议您使用将诊断信息保存到文件的方式收集诊断信息。
需要注意的是,设备上单板越多,诊断信息收集的时间越长,信息收集期间不能输入命令,请耐心等待
通过 Console 口收集诊断信息所用的时间比通过业务网口收集所用的时间要长。在有可用业务网口或管理口的情况下,建议通过业务网口或管理口登录和传输文件 执行 screen-length disable 命令,以避免屏幕输出被打断(如果是将诊断信息保存到文件中,则忽略此步骤)。
<Sysname> screen-length disable
执行 display diagnostic-information 命令收集诊断信息。
<Sysname> display diagnostic-information
Save or display diagnostic information (Y=save, N=display)? 输入“Y”,以及保存诊断信息的路径和名称,将诊断信息保存至文件中。
Save or display diagnostic information (Y=save, N=display)? : Y
Please input the file name(*.tar.gz)[ cfa0:/diag.tar.gz] :cfa0:/diag.tar.gz
Diagnostic information is outputting to cfa0:/diag.tar.gz.
Please wait...
Save successfully.
<Sysname> dir cfa0:/
Directory of cfa0:
……
6 -rw- 898180 Jun 26 2013 09:23:51 diag.tar.gz
1021808 KB total (259072 KB free) 故障自己搞不定,最常见的方法就是下载日志文件,发给H3C后台技术支持人员。
然后坐等回复。
用户支持邮箱:service@h3c.com
技术支持热线电话:400-810-0504
{:6_264:}
不错,加油,上次楼主分享的是命令总结,这次是日志的收集{:6_290:}{:6_290:} {:6_267:}
页:
[1]
2