sosreport日志收集

sosreport日志收集

sosreport命令

  • 用于收集Linux系统配置并诊断信息后输出结论文档。当Linux系统出现故障需要联系红帽厂商时,一般都会要先使用这个sosreport功能来收集计算机的运行状态和服务配置信息,以便让红帽原厂能够通过日志尽快定位问题。

sosreport命令安装

  • 要运行sosreport,需要安装sos 包。sos包是大多是linux的默认安装包中的一部分。如果因为某种原因没有安装,那么运行下面的yum命令来安装sos 包 :
[root@10-10-150-3 ~]# yum install sos

sos日志收集

  • root用户直接执行sosreport命令即可,对于输出过程中弹出来的信息请回车确认即可
[root@10-10-150-3 ~]# sosreport

sosreport (version 3.6)

This command will collect diagnostic and configuration information from
this CentOS Linux system and installed applications.

An archive containing the collected information will be generated in
/var/tmp/sos.8HpVtw and may be provided to a CentOS support
representative.

Any information provided to CentOS will be treated in accordance with
the published support policies at:

  https://wiki.centos.org/

The generated archive may contain data considered sensitive and its
content should be reviewed by the originating organization before being
passed to any third party.

No changes will be made to system configuration.

Press ENTER to continue, or CTRL-C to quit.    回车确认

Please enter the case id that you are generating this report for []:   回车确认

 Setting up archive ...
 Setting up plugins ...
 Running plugins. Please wait ...
   Finishing plugins              [Running: yum]
  Finished running plugins
Creating compressed archive...

Your sosreport has been generated and saved in:
  /var/tmp/sosreport-10-10-150-3-2022-06-07-zinamwc.tar.xz   日志存放地址

The checksum is: 5872f26c0b0893d1d6a80761600c74ed

Please send this file to your support representative.
  • 注意观察结果,结果中会有明确的日志存放位置及名称
  • 这个工具如果在问题触发前未安装,后续手动安装sosreport命令后也可以采集到信息
  • 2
    点赞
  • 8
    收藏
    觉得还不错? 一键收藏
  • 0
    评论

“相关推荐”对你有帮助么?

  • 非常没帮助
  • 没帮助
  • 一般
  • 有帮助
  • 非常有帮助
提交
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值