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':600}
65            - {'peltool  -l -a -f >/tmp/PEL_logs_complete_list.json 2>&1':1200}
66            - {'peltool -a -f -h>/tmp/PEL_logs_complete_display.json 2>&1':1200}
67            - 'hexdump -C /var/lib/phosphor-logging/extensions/pels/badPEL >/tmp/PEL_logs_badPEL.txt'
68            - 'export PDBG_DTB=/var/lib/phosphor-software-manager/pnor/rw/DEVTREE; guard -l >/tmp/GUARD_list.txt'
69            - 'pldmtool fru getfrurecordtable>/tmp/PLDM_fru_record.txt'
70            - 'killall -s SIGUSR1 pldmd; sleep 5'
71            - 'fanctl dump'
72            - 'cp /var/lib/phosphor-software-manager/pnor/rw/DEVTREE /tmp/DEVTREE'
73        FILES:
74            - '/tmp/BMC_flash_side.txt'
75            - '/tmp/BMC_hwmon.txt'
76            - '/tmp/BMC_proc_list.txt'
77            - '/tmp/BMC_proc_fd_active_list.txt'
78            - '/tmp/BMC_journalctl_nopager.txt'
79            - '/tmp/BMC_journalctl_pretty.json'
80            - '/tmp/BMC_dmesg.txt'
81            - '/tmp/BMC_procinfo.txt'
82            - '/tmp/BMC_meminfo.txt'
83            - '/tmp/BMC_systemd.txt'
84            - '/tmp/BMC_failed_service.txt'
85            - '/tmp/BMC_list_service.txt'
86            - '/tmp/BMC_obmc_console.txt'
87            - '/tmp/BMC_obmc_console1.txt'
88            - '/tmp/PEL_logs_list.json'
89            - '/tmp/PEL_logs_complete_list.json'
90            - '/tmp/PEL_logs_complete_display.json'
91            - '/tmp/PEL_logs_display.json'
92            - '/tmp/PEL_logs_badPEL.txt'
93            - '/tmp/GUARD_list.txt'
94            - '/tmp/PLDM_fru_record.txt'
95            - '/tmp/pldm_flight_recorder'
96            - '/tmp/fan_control_dump.json'
97            - '/tmp/DEVTREE'
98        PROTOCOL:
99            - 'SSH'
100
101    # DUMP_LOGS: This section provides option to 'SCP if file exist'.
102    #     COMMANDS: filename is preceded by ls -AX '.
103    #     FILES: is not needed and is ignored if exists.
104    DUMP_LOGS:
105        COMMANDS:
106            - 'ls -AX /var/lib/systemd/coredump/core.*'
107            - 'ls -AX /var/lib/phosphor-debug-collector/dumps/*/*.tar.xz'
108            - 'ls -AX /var/lib/phosphor-debug-collector/hostbootdump/*/*.tar.gz'
109        PROTOCOL:
110            - 'SCP'
111
112    # URLs and Files for OPENBMC redfish
113    # URLs and Files are one-to-one corresponding.
114    # File contains the data returned from 'redfishtool GET URL'
115    REDFISH_LOGS:
116        COMMANDS:
117            - redfishtool -u ${username} -p ${password} -r ${hostname} -S Always raw GET /redfish/v1/AccountService/Accounts
118            - redfishtool -u ${username} -p ${password} -r ${hostname} -S Always raw GET /redfish/v1/Managers/bmc/LogServices/Dump/Entries
119            - redfishtool -u ${username} -p ${password} -r ${hostname} -S Always raw GET /redfish/v1/Systems/system/LogServices/Dump/Entries
120            - redfishtool -u ${username} -p ${password} -r ${hostname} -S Always raw GET /redfish/v1/Systems/system/LogServices/EventLog/Entries
121            - plugin:
122              - plugin_name: plugin.redfish.enumerate_request
123              - plugin_args:
124                - ${hostname}
125                - ${username}
126                - ${password}
127                - /redfish/v1/
128                - json
129        FILES:
130            - 'REDFISH_bmc_user_accounts.json'
131            - 'REDFISH_bmc_dump_entries.json'
132            - 'REDFISH_system_dumps_entries.json'
133            - 'REDFISH_event_log_entries.json'
134            - 'REDFISH_enumerate_v1.json'
135        PROTOCOL:
136            - 'REDFISH'
137
138    # Commands and Files to collect for via out of band IPMI.
139    IPMI_LOGS:
140        COMMANDS:
141            - ipmitool -I lanplus -C 17 -U ${username} -P ${password} -H ${hostname} lan print
142            - ipmitool -I lanplus -C 17 -U ${username} -P ${password} -H ${hostname} fru list
143            - ipmitool -I lanplus -C 17 -U ${username} -P ${password} -H ${hostname} user list
144        FILES:
145            - 'IPMI_LAN_print.txt'
146            - 'IPMI_FRU_list.txt'
147            - 'IPMI_USER_list.txt'
148        PROTOCOL:
149            - 'IPMI'
150
151# Commands and Files to collect for all Linux distributions
152LINUX:
153    LINUX_LOGS:
154        COMMANDS:
155            - 'cat /sys/firmware/opal/msglog >/tmp/OS_msglog.txt'
156            - 'ppc64_cpu --frequency >/tmp/OS_cpufrequency.txt'
157            - 'dmesg >/tmp/OS_dmesg.txt'
158            - 'cat /var/log/opal-prd* >/tmp/OS_opal_prd.txt'
159            - 'cat /var/log/boot.log >/tmp/OS_boot.txt'
160            - 'cat /proc/cpuinfo >/tmp/OS_procinfo.txt'
161            - 'cat /proc/meminfo >/tmp/OS_meminfo.txt'
162            - 'netstat -a >/tmp/OS_netstat.txt'
163            - 'lspci >/tmp/OS_lspci.txt'
164            - 'lscpu >/tmp/OS_lscpu.txt'
165            - 'lscfg >/tmp/OS_lscfg.txt'
166            - 'journalctl --no-pager -b > /tmp/OS_journalctl_nopager.txt '
167        FILES:
168            - '/tmp/OS_msglog.txt'
169            - '/tmp/OS_cpufrequency.txt'
170            - '/tmp/OS_dmesg.txt'
171            - '/tmp/OS_opal_prd.txt'
172            - '/tmp/OS_boot.txt'
173            - '/tmp/OS_procinfo.txt'
174            - '/tmp/OS_meminfo.txt'
175            - '/tmp/OS_netstat.txt'
176            - '/tmp/OS_lspci.txt'
177            - '/tmp/OS_lscpu.txt'
178            - '/tmp/OS_lscfg.txt'
179            - '/tmp/OS_journalctl_nopager.txt'
180        PROTOCOL:
181            - 'SSH'
182
183# Commands and Files to collect for Ubuntu Linux only
184UBUNTU:
185    GENERAL:
186        COMMANDS:
187            - 'rm -rf /tmp/UBUNTU_general.txt'
188            - 'echo "++++++++++ UBUNTU Rleasae ++++++++++" > /tmp/UBUNTU_general.txt'
189            - 'cat /etc/os-release >> /tmp/UBUNTU_general.txt'
190            - 'echo "\n++++++++++ Time stamp ++++++++++" >> /tmp/UBUNTU_general.txt'
191            - 'date >> /tmp/UBUNTU_general.txt'
192            - 'echo  "\n++++++++++ uname -a ++++++++++" >> /tmp/UBUNTU_general.txt'
193            - 'uname -a >> /tmp/UBUNTU_general.txt'
194            - 'echo "\n++++++++++ uptime ++++++++++" >> /tmp/UBUNTU_general.txt'
195            - 'uptime >> /tmp/UBUNTU_general.txt'
196        FILES:
197            - '/tmp/UBUNTU_general.txt'
198        PROTOCOL:
199            - 'SSH'
200    UBUNTU_LOGS:
201        COMMANDS:
202            - '{ cat /etc/os-release; uname -a; rpm -qa ; } >/tmp/OS_info.txt'
203            - 'tail -n 200000 /var/log/messages >/tmp/OS_syslog.txt'
204            - 'rm -rf /tmp/sosreport*FFDC*'
205            - {'sosreport --batch --tmp-dir /tmp --label FFDC >/tmp/OS_sosreport.txt': 1200}
206            - 'tar -zcvf /tmp/crash.tar.gz /var/crash'
207        FILES:
208            - '/tmp/OS_info.txt'
209            - '/tmp/OS_syslog.txt'
210            - '/tmp/OS_sosreport.txt'
211            - '/tmp/sosreport*.tar.xz'
212            - '/tmp/crash.tar.gz'
213        PROTOCOL:
214            - 'SSH'
215    DUMP_LOGS:
216        COMMANDS:
217            - 'ls -AX /tmp/htx/htxerr'
218            - 'ls -AX /tmp/htx/htxmsg'
219        PROTOCOL:
220            - 'SCP'
221
222# Commands and Files to collect for RHE Linux only
223RHEL:
224    GENERAL:
225        COMMANDS:
226            - 'rm -rf /tmp/RHEL_general.txt'
227            - 'echo "++++++++++ RHEL Rleasae ++++++++++" > /tmp/RHEL_general.txt'
228            - 'cat /etc/os-release >> /tmp/RHEL_general.txt'
229            - 'echo -e "\n++++++++++ Time stamp ++++++++++" >> /tmp/RHEL_general.txt'
230            - 'date >> /tmp/RHEL_general.txt'
231            - 'echo -e "\n++++++++++ uname -a ++++++++++" >> /tmp/RHEL_general.txt'
232            - 'uname -a >> /tmp/RHEL_general.txt'
233            - 'echo -e "\n++++++++++ uptime ++++++++++" >> /tmp/RHEL_general.txt'
234            - 'uptime >> /tmp/RHEL_general.txt'
235        FILES:
236            - '/tmp/RHEL_general.txt'
237        PROTOCOL:
238            - 'SSH'
239    RHEL_LOGS:
240        COMMANDS:
241            - '{ cat /etc/os-release; uname -a; rpm -qa ; } >/tmp/OS_info.txt'
242            - 'tail -n 200000 /var/log/messages >/tmp/OS_syslog.txt'
243            - 'rm -rf /tmp/sosreport*FFDC*'
244            - {'sosreport --batch --tmp-dir /tmp --label FFDC >/tmp/OS_sosreport.txt': 1200}
245            - 'tar -zcvf /tmp/crash.tar.gz /var/crash'
246        FILES:
247            - '/tmp/OS_info.txt'
248            - '/tmp/OS_syslog.txt'
249            - '/tmp/OS_sosreport.txt'
250            - '/tmp/sosreport*.tar.xz'
251            - '/tmp/crash.tar.gz'
252        PROTOCOL:
253            - 'SSH'
254    DUMP_LOGS:
255        COMMANDS:
256            - 'ls -AX /tmp/htx/htxerr'
257            - 'ls -AX /tmp/htx/htxmsg'
258        PROTOCOL:
259            - 'SCP'
260
261# Commands and Files to collect for SLES Linux only
262SLES:
263    GENERAL:
264        COMMANDS:
265            - 'rm -rf /tmp/SLES_general.txt'
266            - 'echo "++++++++++ SLES Rleasae ++++++++++" > /tmp/SLES_general.txt'
267            - 'cat /etc/os-release >> /tmp/SLES_general.txt'
268            - 'echo "\n++++++++++ Time stamp ++++++++++" >> /tmp/SLES_general.txt'
269            - 'date >> /tmp/SLES_general.txt'
270            - 'echo "\n++++++++++ uname -a ++++++++++" >> /tmp/SLES_general.txt'
271            - 'uname -a >> /tmp/SLES_general.txt'
272            - 'echo "\n++++++++++ uptime ++++++++++" >> /tmp/SLES_general.txt'
273            - 'uptime >> /tmp/SLES_general.txt'
274        FILES:
275            - '/tmp/SLES_general.txt'
276        PROTOCOL:
277            - 'SSH'
278    SLES_LOGS:
279        COMMANDS:
280            - '{ cat /etc/os-release; uname -a; rpm -qa ; } >/tmp/OS_info.txt'
281            - 'tail -n 200000 /var/log/messages >/tmp/OS_syslog.txt'
282            - 'rm -rf /tmp/scc*.txz.md5'
283            - {'supportconfig >/tmp/OS_supportconfig.txt': 1200}
284            - 'cp /var/log/scc*.txz.md5 /tmp/'
285            - 'tar -zcvf /tmp/crash.tar.gz /var/crash'
286        FILES:
287            - '/tmp/OS_info.txt'
288            - '/tmp/OS_syslog.txt'
289            - '/tmp/OS_supportconfig.txt'
290            - '/tmp/scc*.txz.md5'
291            - '/tmp/crash.tar.gz'
292        PROTOCOL:
293            - 'SSH'
294    DUMP_LOGS:
295        COMMANDS:
296            - 'ls -AX /tmp/htx/htxerr'
297            - 'ls -AX /tmp/htx/htxmsg'
298        PROTOCOL:
299            - 'SCP'
300
301# Commands and Files to collect for AIX only
302AIX:
303    GENERAL:
304        COMMANDS:
305            - 'rm -rf /tmp/AIX_general.txt'
306            - 'echo "++++++++++ AIX Release ++++++++++" > /tmp/AIX_general.txt'
307            - 'cat /proc/version | tail -1 >> /tmp/AIX_general.txt'
308            - 'echo "\n++++++++++ Time stamp ++++++++++" >> /tmp/AIX_general.txt'
309            - 'date >> /tmp/AIX_general.txt'
310            - 'echo  "\n++++++++++ uname -a ++++++++++" >> /tmp/AIX_general.txt'
311            - 'uname -a >> /tmp/AIX_general.txt'
312            - 'echo "\n++++++++++ uptime ++++++++++" >> /tmp/AIX_general.txt'
313            - 'uptime >> /tmp/AIX_general.txt'
314            - 'echo "\n++++++++++ System Info ++++++++++" >> /tmp/AIX_general.txt'
315            - 'prtconf | head -15 >> /tmp/AIX_general.txt'
316        FILES:
317            - '/tmp/AIX_general.txt'
318        PROTOCOL:
319            - 'SSH'
320    AIX_LOGS:
321        COMMANDS:
322            - 'errpt -a >/tmp/OS_errpt.txt ; errclear 0;'
323            - 'bindprocessor -q >/tmp/OS_processors.txt'
324        FILES:
325            - '/tmp/OS_errpt.txt'
326            - '/tmp/OS_processors.txt'
327        PROTOCOL:
328            - 'SSH'
329    DUMP_LOGS:
330        COMMANDS:
331            - 'ls -AX /tmp/htx/htxerr'
332            - 'ls -AX /tmp/htx/htxmsg'
333        PROTOCOL:
334            - 'SCP'
335