とても便利。
サポートへ送るためのセットなので、サーバをいじれない状態でリモート対応するときとか、とりあえずこれもらうことにしよう。うん。
yumでのインストール
1 |
[root@localhost tmp]# yum -y install sos |
使ってみる
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 |
#sosreportコマンドを実行するだけ [root@localhost tmp]# sosreport sosreport (version 3.4) 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.40GKTA 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. ←Enter Please enter your first initial and last name [localhost.localdomain]: ←Enter Please enter the case id that you are generating this report for []: ←Enter Setting up archive ... Setting up plugins ... Running plugins. Please wait ... Running 75/75: yum... Creating compressed archive... Your sosreport has been generated and saved in: /var/tmp/sosreport-localhost.localdomain-20171211111541.tar.xz The checksum is: d1c4f0ecfe2be97b149da835d8f35ddf Please send this file to your support representative. #できあがり [root@localhost tmp]# ls -l /var/tmp/sosreport-localhost.localdomain-20171211111541.tar.xz -rw-------. 1 root root 7699244 12月 11 11:17 /var/tmp/sosreport-localhost.localdomain-20171211111541.tar.xz #解凍して中身を見てみる [root@localhost tmp]# tar Jxvf /var/tmp/sosreport-localhost.localdomain-20171211111541.tar.xz [root@localhost tmp]# ls -l sosreport-localhost.localdomain-20171211111541/ 合計 16 lrwxrwxrwx. 1 root root 38 12月 11 11:16 chkconfig -> sos_commands/services/chkconfig_--list lrwxrwxrwx. 1 root root 25 12月 11 11:16 date -> sos_commands/general/date lrwxrwxrwx. 1 root root 27 12月 11 11:16 df -> sos_commands/filesys/df_-al lrwxrwxrwx. 1 root root 31 12月 11 11:16 dmidecode -> sos_commands/hardware/dmidecode drwxr-xr-x. 35 root root 4096 12月 11 11:10 etc lrwxrwxrwx. 1 root root 24 12月 11 11:16 free -> sos_commands/memory/free lrwxrwxrwx. 1 root root 29 12月 11 11:16 hostname -> sos_commands/general/hostname lrwxrwxrwx. 1 root root 130 12月 11 11:16 installed-rpms -> sos_commands/rpm/sh_-c_rpm_--nodigest_-qa_--qf_NAME_-_VERSION_-_RELEASE_._ARCH_INSTALLTIME_date_awk_-F_printf_-59s_s_n_1_2_sort_-f lrwxrwxrwx. 1 root root 34 12月 11 11:16 ip_addr -> sos_commands/networking/ip_-o_addr lrwxrwxrwx. 1 root root 45 12月 11 11:16 java -> sos_commands/java/alternatives_--display_java lrwxrwxrwx. 1 root root 22 12月 11 11:16 last -> sos_commands/last/last dr-xr-xr-x. 7 root root 78 11月 30 10:44 lib lrwxrwxrwx. 1 root root 25 12月 11 11:16 lsmod -> sos_commands/kernel/lsmod lrwxrwxrwx. 1 root root 28 12月 11 11:16 lspci -> sos_commands/pci/lspci_-nnvv lrwxrwxrwx. 1 root root 29 12月 11 11:16 mount -> sos_commands/filesys/mount_-l dr-xr-xr-x. 10 root root 4096 12月 11 11:05 proc lrwxrwxrwx. 1 root root 30 12月 11 11:16 ps -> sos_commands/process/ps_auxwww dr-xr-x---. 2 root root 29 11月 30 15:04 root drwxr-xr-x. 3 root root 19 12月 11 11:17 run drwx------. 45 root root 4096 12月 11 11:17 sos_commands drwx------. 2 root root 35 12月 11 11:17 sos_logs drwx------. 2 root root 37 12月 11 11:17 sos_reports drwx------. 3 root root 18 12月 11 11:16 sos_strings dr-xr-xr-x. 10 root root 112 12月 11 11:05 sys lrwxrwxrwx. 1 root root 28 12月 11 11:16 uname -> sos_commands/kernel/uname_-a lrwxrwxrwx. 1 root root 27 12月 11 11:16 uptime -> sos_commands/general/uptime drwxr-xr-x. 5 root root 42 11月 30 10:38 usr drwxr-xr-x. 4 root root 28 12月 11 11:05 var -rw-r--r--. 1 root root 1492 12月 11 11:17 version.txt lrwxrwxrwx. 1 root root 62 12月 11 11:16 vgdisplay -> sos_commands/lvm2/vgdisplay_-vv_--config_global_locking_type_0 #試しにhosunameというファイルを見てみる [root@localhost tmp]# cat sosreport-localhost.localdomain-20171211111541/hostname localhost.localdomain |