commit | 416458c07e0e8f7f5172f79f63d540a2d5083f1f | [log] [tgz] |
---|---|---|
author | Jayanth Othayoth <ojayanth@in.ibm.com> | Wed Jul 05 10:31:16 2017 -0500 |
committer | Patrick Williams <patrick@stwcx.xyz> | Fri Jul 07 19:35:53 2017 +0000 |
tree | 90946a4b545c6037f7507fb18cc58848d89443d8 | |
parent | bb4499fc3e2f972b734d2a0fa0a8cd61d7b8e76e [diff] |
Enforce Dump directory creation prior to Dump manager starts Create Dump file storage location before Dump Manager application starts. Change-Id: I583b8cdb853ac1ac18e50c05404f90a2fbb6d5e1 Signed-off-by: Jayanth Othayoth <ojayanth@in.ibm.com>
diff --git a/meta-phosphor/classes/phosphor-debug-collector.bbclass b/meta-phosphor/classes/phosphor-debug-collector.bbclass new file mode 100644 index 0000000..030b404 --- /dev/null +++ b/meta-phosphor/classes/phosphor-debug-collector.bbclass
@@ -0,0 +1 @@ +bmc_dump_path="/tmp/dumps"
diff --git a/meta-phosphor/common/recipes-phosphor/dump/phosphor-debug-collector.bb b/meta-phosphor/common/recipes-phosphor/dump/phosphor-debug-collector.bb index 56e80ee..0f93529 100644 --- a/meta-phosphor/common/recipes-phosphor/dump/phosphor-debug-collector.bb +++ b/meta-phosphor/common/recipes-phosphor/dump/phosphor-debug-collector.bb
@@ -22,7 +22,8 @@ inherit autotools \ pkgconfig \ obmc-phosphor-dbus-service \ - pythonnative + pythonnative \ + phosphor-debug-collector require phosphor-debug-collector.inc @@ -46,10 +47,15 @@ phosphor-logging \ " +MGR_SVC ?= "xyz.openbmc_project.Dump.Manager.service" + +SYSTEMD_SUBSTITUTIONS += "BMC_DUMP_PATH:${bmc_dump_path}:${MGR_SVC}" + FILES_${PN}-manager += "${sbindir}/phosphor-dump-manager" FILES_${PN}-monitor += "${sbindir}/phosphor-dump-monitor" -DBUS_SERVICE_${PN}-manager += "xyz.openbmc_project.Dump.Manager.service" +DBUS_SERVICE_${PN}-manager += "${MGR_SVC}" SYSTEMD_SERVICE_${PN}-monitor += "obmc-dump-monitor.service" + S = "${WORKDIR}/git"
diff --git a/meta-phosphor/common/recipes-phosphor/dump/phosphor-debug-collector/xyz.openbmc_project.Dump.Manager.service b/meta-phosphor/common/recipes-phosphor/dump/phosphor-debug-collector/xyz.openbmc_project.Dump.Manager.service index 9aeba93..84f8232 100644 --- a/meta-phosphor/common/recipes-phosphor/dump/phosphor-debug-collector/xyz.openbmc_project.Dump.Manager.service +++ b/meta-phosphor/common/recipes-phosphor/dump/phosphor-debug-collector/xyz.openbmc_project.Dump.Manager.service
@@ -2,6 +2,7 @@ Description=Phosphor Dump Manager [Service] +ExecStartPre=/bin/sh -c 'mkdir -p {BMC_DUMP_PATH}' ExecStart={sbindir}/phosphor-dump-manager Restart=always Type=dbus