summaryrefslogtreecommitdiffstats
path: root/meta/recipes-extended/mdadm
diff options
context:
space:
mode:
authorChangqing Li <changqing.li@windriver.com>2019-07-01 13:04:53 +0800
committerRichard Purdie <richard.purdie@linuxfoundation.org>2019-07-02 08:13:07 +0100
commitd727e24ed5112be305be1a864e975cd39a466848 (patch)
tree579935a3c2fd36462c24e5fbb3fdb18f69ed048b /meta/recipes-extended/mdadm
parentda263d9c7af86c6cdd1b119080c9fd685183a396 (diff)
downloadpoky-d727e24ed5112be305be1a864e975cd39a466848.tar.gz
mdam: fix mdmonitor start up failure
1. recently, mdadm has changed to use service file under srcdir, so remove the one not be used. 2. add -y option to fix below problem mdadm: No mail address or alert command - not monitoring (From OE-Core rev: e3cd783f42bff8ac50d4dde560ead999efd01a57) Signed-off-by: Changqing Li <changqing.li@windriver.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
Diffstat (limited to 'meta/recipes-extended/mdadm')
-rw-r--r--meta/recipes-extended/mdadm/files/0001-mdadm-add-option-y-for-use-syslog-to-recive-event-re.patch28
-rw-r--r--meta/recipes-extended/mdadm/files/mdmonitor.service20
-rw-r--r--meta/recipes-extended/mdadm/mdadm_4.1.bb3
3 files changed, 29 insertions, 22 deletions
diff --git a/meta/recipes-extended/mdadm/files/0001-mdadm-add-option-y-for-use-syslog-to-recive-event-re.patch b/meta/recipes-extended/mdadm/files/0001-mdadm-add-option-y-for-use-syslog-to-recive-event-re.patch
new file mode 100644
index 0000000000..e00287cab1
--- /dev/null
+++ b/meta/recipes-extended/mdadm/files/0001-mdadm-add-option-y-for-use-syslog-to-recive-event-re.patch
@@ -0,0 +1,28 @@
1From 5fdc0173cb4fcf8656f0889ad364d2549795607f Mon Sep 17 00:00:00 2001
2From: Changqing Li <changqing.li@windriver.com>
3Date: Mon, 1 Jul 2019 11:34:49 +0800
4Subject: [PATCH] mdadm: add option -y for use syslog to recive event report
5
6fix service startup failed when there is
7No mail address or alert command
8
9Upstream-Status: Inappropriate [configuration]
10
11Signed-off-by: Changqing Li <changqing.li@windriver.com>
12---
13 systemd/mdmonitor.service | 2 +-
14 1 file changed, 1 insertion(+), 1 deletion(-)
15
16diff --git a/systemd/mdmonitor.service b/systemd/mdmonitor.service
17index 46f7b88..3fc4687 100644
18--- a/systemd/mdmonitor.service
19+++ b/systemd/mdmonitor.service
20@@ -13,4 +13,4 @@ DefaultDependencies=no
21 Environment= MDADM_MONITOR_ARGS=--scan
22 EnvironmentFile=-/run/sysconfig/mdadm
23 ExecStartPre=-/usr/lib/mdadm/mdadm_env.sh
24-ExecStart=BINDIR/mdadm --monitor $MDADM_MONITOR_ARGS
25+ExecStart=BINDIR/mdadm --monitor -y $MDADM_MONITOR_ARGS
26--
272.7.4
28
diff --git a/meta/recipes-extended/mdadm/files/mdmonitor.service b/meta/recipes-extended/mdadm/files/mdmonitor.service
deleted file mode 100644
index a81578ead6..0000000000
--- a/meta/recipes-extended/mdadm/files/mdmonitor.service
+++ /dev/null
@@ -1,20 +0,0 @@
1# This file is part of mdadm.
2#
3# mdadm is free software; you can redistribute it and/or modify it
4# under the terms of the GNU General Public License as published by
5# the Free Software Foundation; either version 2 of the License, or
6# (at your option) any later version.
7
8[Unit]
9Description=Software RAID monitoring and management
10ConditionPathExists=/etc/mdadm.conf
11
12[Service]
13Type=forking
14PIDFile=/var/run/mdadm/mdadm.pid
15EnvironmentFile=-/etc/sysconfig/mdmonitor
16ExecStartPre=mkdir -p /var/run/mdadm
17ExecStart=/sbin/mdadm --monitor -y --scan -f --pid-file=/var/run/mdadm/mdadm.pid
18
19[Install]
20WantedBy=multi-user.target
diff --git a/meta/recipes-extended/mdadm/mdadm_4.1.bb b/meta/recipes-extended/mdadm/mdadm_4.1.bb
index 494b81b5e7..766004fe9d 100644
--- a/meta/recipes-extended/mdadm/mdadm_4.1.bb
+++ b/meta/recipes-extended/mdadm/mdadm_4.1.bb
@@ -19,7 +19,7 @@ SRC_URI = "${KERNELORG_MIRROR}/linux/utils/raid/mdadm/${BPN}-${PV}.tar.xz \
19 file://0001-fix-gcc-8-format-truncation-warning.patch \ 19 file://0001-fix-gcc-8-format-truncation-warning.patch \
20 file://debian-no-Werror.patch \ 20 file://debian-no-Werror.patch \
21 file://mdadm.init \ 21 file://mdadm.init \
22 file://mdmonitor.service \ 22 file://0001-mdadm-add-option-y-for-use-syslog-to-recive-event-re.patch \
23 " 23 "
24SRC_URI[md5sum] = "51bf3651bd73a06c413a2f964f299598" 24SRC_URI[md5sum] = "51bf3651bd73a06c413a2f964f299598"
25SRC_URI[sha256sum] = "ab7688842908d3583a704d491956f31324c3a5fc9f6a04653cb75d19f1934f4a" 25SRC_URI[sha256sum] = "ab7688842908d3583a704d491956f31324c3a5fc9f6a04653cb75d19f1934f4a"
@@ -65,7 +65,6 @@ do_install_append() {
65 oe_runmake install-systemd DESTDIR=${D} 65 oe_runmake install-systemd DESTDIR=${D}
66} 66}
67 67
68
69do_compile_ptest() { 68do_compile_ptest() {
70 oe_runmake test 69 oe_runmake test
71} 70}