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