1---
2# This yaml formatted file contains defaults items to collect FFDC for the targeted system
3# COMMANDS - List of commands to be run on the corresponding targeted system (inband)
4#            to generate and/or collect data
5# FILES    - List of files; with complete path; on the corresponding targeted system
6#            to be copied to external destination
7# PROTOCOL - Protocol used to communicate with targeted system; ssh, Rest, redfish, etc
8#
9# Note: Items in COMMANDS and FILES are not necessarily one-to-one correspondence.
10#       For example, a file could have been created by an internal process,
11#       and is listed in FILES to be collected.
12#
13
14# Commands and Files to collect for a given OpenBMC system.
15OPENBMC:
16    # Commands and File to take snapshot of linux based system.
17    # Filename is <OS>_general.txt, where <OS> is in [OPENBMC, RHEL, UBUNTU]
18    GENERAL:
19        COMMANDS:
20            - 'rm -rf /tmp/OPENBMC_general.txt'
21            - 'echo "++++++++++ cat /etc/os-release ++++++++++" >> /tmp/OPENBMC_general.txt'
22            - 'cat /etc/os-release >> /tmp/OPENBMC_general.txt'
23            - 'echo -e "\n++++++++++ cat /etc/timestamp ++++++++++" >> /tmp/OPENBMC_general.txt'
24            - 'cat /etc/timestamp >> /tmp/OPENBMC_general.txt'
25            - 'echo -e "\n++++++++++ uname -a ++++++++++" >> /tmp/OPENBMC_general.txt'
26            - 'uname -a >> /tmp/OPENBMC_general.txt'
27            - 'echo -e "\n++++++++++ cat /etc/timestamp ++++++++++" >> /tmp/OPENBMC_general.txt'
28            - 'cat /etc/timestamp >> /tmp/OPENBMC_general.txt'
29            - 'echo -e "\n++++++++++ uptime;cat /proc/uptime ++++++++++" >> /tmp/OPENBMC_general.txt'
30            - 'uptime >> /tmp/OPENBMC_general.txt'
31            - 'cat /proc/uptime >> /tmp/OPENBMC_general.txt'
32            - 'echo -e "\n++++++++++ df -hT ++++++++++" >> /tmp/OPENBMC_general.txt'
33            - 'df -hT >> /tmp/OPENBMC_general.txt'
34            - 'echo -e "\n++++++++++ date;/sbin/hwclock --show ++++++++++" >> /tmp/OPENBMC_general.txt'
35            - 'date >> /tmp/OPENBMC_general.txt'
36            - '/sbin/hwclock --show >> /tmp/OPENBMC_general.txt'
37            - '/usr/bin/timedatectl >> /tmp/OPENBMC_general.txt'
38            - 'echo -e "\n++++++++++ /usr/bin/obmcutil state ++++++++++" >> /tmp/OPENBMC_general.txt'
39            - '/usr/bin/obmcutil state >> /tmp/OPENBMC_general.txt'
40            - 'echo -e "\n++++++++++ bmcweb session data ++++++++++" >> /tmp/OPENBMC_general.txt'
41            - 'for f in `find /var/lib/bmcweb/ -name "*.json"`; do (echo $f; cat $f) done >> /tmp/OPENBMC_general.txt'
42        FILES:
43            - '/tmp/OPENBMC_general.txt'
44        PROTOCOL:
45            - 'SSH'
46
47    OPENBMC_LOGS:
48        COMMANDS:
49            - 'cat /sys/class/watchdog/watchdog1/bootstatus >/tmp/BMC_flash_side.txt'
50            - 'grep -r . /sys/class/hwmon/* >/tmp/BMC_hwmon.txt'
51            - 'top -n 1 -b >/tmp/BMC_proc_list.txt'
52            - 'ls -Al /proc/*/fd/ >/tmp/BMC_proc_fd_active_list.txt'
53            - 'journalctl --no-pager >/tmp/BMC_journalctl_nopager.txt'
54            - 'journalctl -o json-pretty >/tmp/BMC_journalctl_pretty.json'
55            - 'dmesg >/tmp/BMC_dmesg.txt'
56            - 'cat /proc/cpuinfo >/tmp/BMC_procinfo.txt'
57            - 'cat /proc/meminfo >/tmp/BMC_meminfo.txt'
58            - 'systemctl status --all >/tmp/BMC_systemd.txt'
59            - 'systemctl list-units --failed >/tmp/BMC_failed_service.txt'
60            - 'systemctl list-jobs >/tmp/BMC_list_service.txt'
61            - 'cat /var/log/obmc-console.log >/tmp/BMC_obmc_console.txt'
62            - 'cat /var/log/obmc-console1.log >/tmp/BMC_obmc_console1.txt'
63            - 'peltool -l >/tmp/PEL_logs_list.json'
64            - {'peltool -a >/tmp/PEL_logs_display.json':240}
65            - 'hexdump -C /var/lib/phosphor-logging/extensions/pels/badPEL >/tmp/PEL_logs_badPEL.txt'
66            - 'export PDBG_DTB=/var/lib/phosphor-software-manager/pnor/rw/DEVTREE; guard -l >/tmp/GUARD_list.txt'
67            - 'pldmtool fru getfrurecordtable>/tmp/PLDM_fru_record.txt'
68            - 'killall -s SIGUSR1 pldmd; sleep 5'
69            - 'fanctl dump'
70            - 'cp /var/lib/phosphor-software-manager/pnor/rw/DEVTREE /tmp/DEVTREE'
71        FILES:
72            - '/tmp/BMC_flash_side.txt'
73            - '/tmp/BMC_hwmon.txt'
74            - '/tmp/BMC_proc_list.txt'
75            - '/tmp/BMC_proc_fd_active_list.txt'
76            - '/tmp/BMC_journalctl_nopager.txt'
77            - '/tmp/BMC_journalctl_pretty.json'
78            - '/tmp/BMC_dmesg.txt'
79            - '/tmp/BMC_procinfo.txt'
80            - '/tmp/BMC_meminfo.txt'
81            - '/tmp/BMC_systemd.txt'
82            - '/tmp/BMC_failed_service.txt'
83            - '/tmp/BMC_list_service.txt'
84            - '/tmp/BMC_obmc_console.txt'
85            - '/tmp/BMC_obmc_console1.txt'
86            - '/tmp/PEL_logs_list.json'
87            - '/tmp/PEL_logs_display.json'
88            - '/tmp/PEL_logs_badPEL.txt'
89            - '/tmp/GUARD_list.txt'
90            - '/tmp/PLDM_fru_record.txt'
91            - '/tmp/pldm_flight_recorder'
92            - '/tmp/fan_control_dump.json'
93            - '/tmp/DEVTREE'
94        PROTOCOL:
95            - 'SSH'
96
97    # DUMP_LOGS: This section provides option to 'SCP if file exist'.
98    #     COMMANDS: filename is preceded by ls -AX '.
99    #     FILES: is not needed and is ignored if exists.
100    DUMP_LOGS:
101        COMMANDS:
102            - 'ls -AX /var/lib/systemd/coredump/core.*'
103            - 'ls -AX /var/lib/phosphor-debug-collector/dumps/*/*.tar.xz'
104            - 'ls -AX /var/lib/phosphor-debug-collector/hostbootdump/*/*.tar.gz'
105        PROTOCOL:
106            - 'SCP'
107
108    # URLs and Files for OPENBMC redfish
109    # URLs and Files are one-to-one corresponding.
110    # File contains the data returned from 'redfishtool GET URL'
111    REDFISH_LOGS:
112        COMMANDS:
113            - redfishtool -u ${username} -p ${password} -r ${hostname} -S Always raw GET /redfish/v1/AccountService/Accounts
114            - redfishtool -u ${username} -p ${password} -r ${hostname} -S Always raw GET /redfish/v1/Managers/bmc/LogServices/Dump/Entries
115            - redfishtool -u ${username} -p ${password} -r ${hostname} -S Always raw GET /redfish/v1/Systems/system/LogServices/Dump/Entries
116            - redfishtool -u ${username} -p ${password} -r ${hostname} -S Always raw GET /redfish/v1/Systems/system/LogServices/EventLog/Entries
117            - plugin:
118              - plugin_name: plugin.redfish.enumerate_request
119              - plugin_args:
120                - ${hostname}
121                - ${username}
122                - ${password}
123                - /redfish/v1/
124                - json
125        FILES:
126            - 'REDFISH_bmc_user_accounts.json'
127            - 'REDFISH_bmc_dump_entries.json'
128            - 'REDFISH_system_dumps_entries.json'
129            - 'REDFISH_event_log_entries.json'
130            - 'REDFISH_enumerate_v1.json'
131        PROTOCOL:
132            - 'REDFISH'
133
134    # Commands and Files to collect for via out of band IPMI.
135    IPMI_LOGS:
136        COMMANDS:
137            - ipmitool -I lanplus -C 17 -U ${username} -P ${password} -H ${hostname} lan print
138            - ipmitool -I lanplus -C 17 -U ${username} -P ${password} -H ${hostname} fru list
139            - ipmitool -I lanplus -C 17 -U ${username} -P ${password} -H ${hostname} user list
140        FILES:
141            - 'IPMI_LAN_print.txt'
142            - 'IPMI_FRU_list.txt'
143            - 'IPMI_USER_list.txt'
144        PROTOCOL:
145            - 'IPMI'
146
147# Commands and Files to collect for all Linux distributions
148LINUX:
149    LINUX_LOGS:
150        COMMANDS:
151            - 'cat /sys/firmware/opal/msglog >/tmp/OS_msglog.txt'
152            - 'ppc64_cpu --frequency >/tmp/OS_cpufrequency.txt'
153            - 'dmesg >/tmp/OS_dmesg.txt'
154            - 'cat /var/log/opal-prd* >/tmp/OS_opal_prd.txt'
155            - 'cat /var/log/boot.log >/tmp/OS_boot.txt'
156            - 'cat /proc/cpuinfo >/tmp/OS_procinfo.txt'
157            - 'cat /proc/meminfo >/tmp/OS_meminfo.txt'
158            - 'netstat -a >/tmp/OS_netstat.txt'
159            - 'lspci >/tmp/OS_lspci.txt'
160            - 'lscpu >/tmp/OS_lscpu.txt'
161            - 'lscfg >/tmp/OS_lscfg.txt'
162            - 'journalctl --no-pager -b > /tmp/OS_journalctl_nopager.txt '
163        FILES:
164            - '/tmp/OS_msglog.txt'
165            - '/tmp/OS_cpufrequency.txt'
166            - '/tmp/OS_dmesg.txt'
167            - '/tmp/OS_opal_prd.txt'
168            - '/tmp/OS_boot.txt'
169            - '/tmp/OS_procinfo.txt'
170            - '/tmp/OS_meminfo.txt'
171            - '/tmp/OS_netstat.txt'
172            - '/tmp/OS_lspci.txt'
173            - '/tmp/OS_lscpu.txt'
174            - '/tmp/OS_lscfg.txt'
175            - '/tmp/OS_journalctl_nopager.txt'
176        PROTOCOL:
177            - 'SSH'
178
179# Commands and Files to collect for Ubuntu Linux only
180UBUNTU:
181    GENERAL:
182        COMMANDS:
183            - 'rm -rf /tmp/UBUNTU_general.txt'
184            - 'echo "++++++++++ UBUNTU Rleasae ++++++++++" > /tmp/UBUNTU_general.txt'
185            - 'cat /etc/os-release >> /tmp/UBUNTU_general.txt'
186            - 'echo "\n++++++++++ Time stamp ++++++++++" >> /tmp/UBUNTU_general.txt'
187            - 'date >> /tmp/UBUNTU_general.txt'
188            - 'echo  "\n++++++++++ uname -a ++++++++++" >> /tmp/UBUNTU_general.txt'
189            - 'uname -a >> /tmp/UBUNTU_general.txt'
190            - 'echo "\n++++++++++ uptime ++++++++++" >> /tmp/UBUNTU_general.txt'
191            - 'uptime >> /tmp/UBUNTU_general.txt'
192        FILES:
193            - '/tmp/UBUNTU_general.txt'
194        PROTOCOL:
195            - 'SSH'
196    UBUNTU_LOGS:
197        COMMANDS:
198            - '{ cat /etc/os-release; uname -a; rpm -qa ; } >/tmp/OS_info.txt'
199            - 'tail -n 200000 /var/log/messages >/tmp/OS_syslog.txt'
200            - 'rm -rf /tmp/sosreport*FFDC*'
201            - {'sosreport --batch --tmp-dir /tmp --label FFDC >/tmp/OS_sosreport.txt': 1200}
202            - 'tar -zcvf /tmp/crash.tar.gz /var/crash'
203        FILES:
204            - '/tmp/OS_info.txt'
205            - '/tmp/OS_syslog.txt'
206            - '/tmp/OS_sosreport.txt'
207            - '/tmp/sosreport*.tar.xz'
208            - '/tmp/crash.tar.gz'
209        PROTOCOL:
210            - 'SSH'
211    DUMP_LOGS:
212        COMMANDS:
213            - 'ls -AX /tmp/htx/htxerr'
214            - 'ls -AX /tmp/htx/htxmsg'
215        PROTOCOL:
216            - 'SCP'
217
218# Commands and Files to collect for RHE Linux only
219RHEL:
220    GENERAL:
221        COMMANDS:
222            - 'rm -rf /tmp/RHEL_general.txt'
223            - 'echo "++++++++++ RHEL Rleasae ++++++++++" > /tmp/RHEL_general.txt'
224            - 'cat /etc/os-release >> /tmp/RHEL_general.txt'
225            - 'echo -e "\n++++++++++ Time stamp ++++++++++" >> /tmp/RHEL_general.txt'
226            - 'date >> /tmp/RHEL_general.txt'
227            - 'echo -e "\n++++++++++ uname -a ++++++++++" >> /tmp/RHEL_general.txt'
228            - 'uname -a >> /tmp/RHEL_general.txt'
229            - 'echo -e "\n++++++++++ uptime ++++++++++" >> /tmp/RHEL_general.txt'
230            - 'uptime >> /tmp/RHEL_general.txt'
231        FILES:
232            - '/tmp/RHEL_general.txt'
233        PROTOCOL:
234            - 'SSH'
235    RHEL_LOGS:
236        COMMANDS:
237            - '{ cat /etc/os-release; uname -a; rpm -qa ; } >/tmp/OS_info.txt'
238            - 'tail -n 200000 /var/log/messages >/tmp/OS_syslog.txt'
239            - 'rm -rf /tmp/sosreport*FFDC*'
240            - {'sosreport --batch --tmp-dir /tmp --label FFDC >/tmp/OS_sosreport.txt': 1200}
241            - 'tar -zcvf /tmp/crash.tar.gz /var/crash'
242        FILES:
243            - '/tmp/OS_info.txt'
244            - '/tmp/OS_syslog.txt'
245            - '/tmp/OS_sosreport.txt'
246            - '/tmp/sosreport*.tar.xz'
247            - '/tmp/crash.tar.gz'
248        PROTOCOL:
249            - 'SSH'
250    DUMP_LOGS:
251        COMMANDS:
252            - 'ls -AX /tmp/htx/htxerr'
253            - 'ls -AX /tmp/htx/htxmsg'
254        PROTOCOL:
255            - 'SCP'
256
257# Commands and Files to collect for SLES Linux only
258SLES:
259    GENERAL:
260        COMMANDS:
261            - 'rm -rf /tmp/SLES_general.txt'
262            - 'echo "++++++++++ SLES Rleasae ++++++++++" > /tmp/SLES_general.txt'
263            - 'cat /etc/os-release >> /tmp/SLES_general.txt'
264            - 'echo "\n++++++++++ Time stamp ++++++++++" >> /tmp/SLES_general.txt'
265            - 'date >> /tmp/SLES_general.txt'
266            - 'echo "\n++++++++++ uname -a ++++++++++" >> /tmp/SLES_general.txt'
267            - 'uname -a >> /tmp/SLES_general.txt'
268            - 'echo "\n++++++++++ uptime ++++++++++" >> /tmp/SLES_general.txt'
269            - 'uptime >> /tmp/SLES_general.txt'
270        FILES:
271            - '/tmp/SLES_general.txt'
272        PROTOCOL:
273            - 'SSH'
274    SLES_LOGS:
275        COMMANDS:
276            - '{ cat /etc/os-release; uname -a; rpm -qa ; } >/tmp/OS_info.txt'
277            - 'tail -n 200000 /var/log/messages >/tmp/OS_syslog.txt'
278            - 'rm -rf /tmp/scc*.txz.md5'
279            - {'supportconfig >/tmp/OS_supportconfig.txt': 1200}
280            - 'cp /var/log/scc*.txz.md5 /tmp/'
281            - 'tar -zcvf /tmp/crash.tar.gz /var/crash'
282        FILES:
283            - '/tmp/OS_info.txt'
284            - '/tmp/OS_syslog.txt'
285            - '/tmp/OS_supportconfig.txt'
286            - '/tmp/scc*.txz.md5'
287            - '/tmp/crash.tar.gz'
288        PROTOCOL:
289            - 'SSH'
290    DUMP_LOGS:
291        COMMANDS:
292            - 'ls -AX /tmp/htx/htxerr'
293            - 'ls -AX /tmp/htx/htxmsg'
294        PROTOCOL:
295            - 'SCP'
296
297# Commands and Files to collect for AIX only
298AIX:
299    GENERAL:
300        COMMANDS:
301            - 'rm -rf /tmp/AIX_general.txt'
302            - 'echo "++++++++++ AIX Release ++++++++++" > /tmp/AIX_general.txt'
303            - 'cat /proc/version | tail -1 >> /tmp/AIX_general.txt'
304            - 'echo "\n++++++++++ Time stamp ++++++++++" >> /tmp/AIX_general.txt'
305            - 'date >> /tmp/AIX_general.txt'
306            - 'echo  "\n++++++++++ uname -a ++++++++++" >> /tmp/AIX_general.txt'
307            - 'uname -a >> /tmp/AIX_general.txt'
308            - 'echo "\n++++++++++ uptime ++++++++++" >> /tmp/AIX_general.txt'
309            - 'uptime >> /tmp/AIX_general.txt'
310            - 'echo "\n++++++++++ System Info ++++++++++" >> /tmp/AIX_general.txt'
311            - 'prtconf | head -15 >> /tmp/AIX_general.txt'
312        FILES:
313            - '/tmp/AIX_general.txt'
314        PROTOCOL:
315            - 'SSH'
316    AIX_LOGS:
317        COMMANDS:
318            - 'errpt -a >/tmp/OS_errpt.txt ; errclear 0;'
319            - 'bindprocessor -q >/tmp/OS_processors.txt'
320        FILES:
321            - '/tmp/OS_errpt.txt'
322            - '/tmp/OS_processors.txt'
323        PROTOCOL:
324            - 'SSH'
325    DUMP_LOGS:
326        COMMANDS:
327            - 'ls -AX /tmp/htx/htxerr'
328            - 'ls -AX /tmp/htx/htxmsg'
329        PROTOCOL:
330            - 'SCP'
331