* [PATCHv3] mdadm:fix mdmonitor.service
@ 2019-07-31 1:50 Zang Ruochen
2019-07-31 2:01 ` ✗ patchtest: failure for " Patchwork
2019-07-31 2:50 ` [PATCHv3] " ChenQi
0 siblings, 2 replies; 3+ messages in thread
From: Zang Ruochen @ 2019-07-31 1:50 UTC (permalink / raw)
To: openembedded-core
-The original file mdmonitor.service is as follows:
...
|[Service]
|Environment= MDADM_MONITOR_ARGS=--scan
|EnvironmentFile=-/run/sysconfig/mdadm
|ExecStartPre=-/usr/lib/mdadm/mdadm_env.sh
|ExecStart=/sbin/mdadm --monitor -y $MDADM_MONITOR_ARGS
...
-It has a syntax error and it doesn't work properly,
so add files/0001-Fix-file-mdmonitor.service-syntax-error.patch to fix it.
Signed-off-by: Zang Ruochen <zangrc.fnst@cn.fujitsu.com>
---
...-file-mdmonitor.service-syntax-error.patch | 49 +++++++++++++++++++
meta/recipes-extended/mdadm/mdadm_4.1.bb | 1 +
2 files changed, 50 insertions(+)
create mode 100644 meta/recipes-extended/mdadm/files/0001-Fix-file-mdmonitor.service-syntax-error.patch
diff --git a/meta/recipes-extended/mdadm/files/0001-Fix-file-mdmonitor.service-syntax-error.patch b/meta/recipes-extended/mdadm/files/0001-Fix-file-mdmonitor.service-syntax-error.patch
new file mode 100644
index 0000000000..a36fed6f9f
--- /dev/null
+++ b/meta/recipes-extended/mdadm/files/0001-Fix-file-mdmonitor.service-syntax-error.patch
@@ -0,0 +1,49 @@
+From a4a37cc9d91d7129910360914b8b2060139c0307 Mon Sep 17 00:00:00 2001
+From: Zang Ruochen <zangrc.fnst@cn.fujitsu.com>
+Date: Tue, 30 Jul 2019 12:44:25 +0800
+Subject: [PATCH] Fix file mdmonitor.service syntax error
+
+-The original file mdmonitor.service is as follows:
+...
+|[Service]
+|Environment= MDADM_MONITOR_ARGS=--scan
+|EnvironmentFile=-/run/sysconfig/mdadm
+|ExecStartPre=-/usr/lib/mdadm/mdadm_env.sh
+|ExecStart=/sbin/mdadm --monitor -y $MDADM_MONITOR_ARGS
+...
+-It has a syntax error and it doesn't work properly,
+ so add new file mdmonitor.service to overwrite it.
+
+Signed-off-by: Zang Ruochen <zangrc.fnst@cn.fujitsu.com>
+---
+ systemd/mdmonitor.service | 15 +++++++++------
+ 1 file changed, 9 insertions(+), 6 deletions(-)
+
+diff --git a/systemd/mdmonitor.service b/systemd/mdmonitor.service
+index 3fc4687..bd243b4 100644
+--- a/systemd/mdmonitor.service
++++ b/systemd/mdmonitor.service
+@@ -6,11 +6,14 @@
+ # (at your option) any later version.
+
+ [Unit]
+-Description=MD array monitor
+-DefaultDependencies=no
++Description=Software RAID monitoring and management
++ConditionPathExists=/etc/mdadm.conf
+
+ [Service]
+-Environment= MDADM_MONITOR_ARGS=--scan
+-EnvironmentFile=-/run/sysconfig/mdadm
+-ExecStartPre=-/usr/lib/mdadm/mdadm_env.sh
+-ExecStart=BINDIR/mdadm --monitor -y $MDADM_MONITOR_ARGS
++Type=forking
++PIDFile=/var/run/mdadm/mdadm.pid
++EnvironmentFile=-/etc/sysconfig/mdmonitor
++ExecStart=/sbin/mdadm --monitor --scan -y -f --pid-file=/var/run/mdadm/mdadm.pid
++
++[Install]
++WantedBy=multi-user.target
+--
+2.20.1
+
diff --git a/meta/recipes-extended/mdadm/mdadm_4.1.bb b/meta/recipes-extended/mdadm/mdadm_4.1.bb
index 74c94f6ecb..c3e15adc71 100644
--- a/meta/recipes-extended/mdadm/mdadm_4.1.bb
+++ b/meta/recipes-extended/mdadm/mdadm_4.1.bb
@@ -22,6 +22,7 @@ SRC_URI = "${KERNELORG_MIRROR}/linux/utils/raid/mdadm/${BPN}-${PV}.tar.xz \
file://mdadm.init \
file://0001-mdadm-add-option-y-for-use-syslog-to-recive-event-re.patch \
file://include_sysmacros.patch \
+ file://0001-Fix-file-mdmonitor.service-syntax-error.patch \
"
SRC_URI[md5sum] = "51bf3651bd73a06c413a2f964f299598"
SRC_URI[sha256sum] = "ab7688842908d3583a704d491956f31324c3a5fc9f6a04653cb75d19f1934f4a"
--
2.20.1
^ permalink raw reply related [flat|nested] 3+ messages in thread
* ✗ patchtest: failure for mdadm:fix mdmonitor.service
2019-07-31 1:50 [PATCHv3] mdadm:fix mdmonitor.service Zang Ruochen
@ 2019-07-31 2:01 ` Patchwork
2019-07-31 2:50 ` [PATCHv3] " ChenQi
1 sibling, 0 replies; 3+ messages in thread
From: Patchwork @ 2019-07-31 2:01 UTC (permalink / raw)
To: Zang Ruochen; +Cc: openembedded-core
== Series Details ==
Series: mdadm:fix mdmonitor.service
Revision: 1
URL : https://patchwork.openembedded.org/series/18977/
State : failure
== Summary ==
Thank you for submitting this patch series to OpenEmbedded Core. This is
an automated response. Several tests have been executed on the proposed
series by patchtest resulting in the following failures:
* Issue Added patch file is missing Upstream-Status in the header [test_upstream_status_presence_format]
Suggested fix Add Upstream-Status: <Valid status> to the header of meta/recipes-extended/mdadm/files/0001-Fix-file-mdmonitor.service-syntax-error.patch
Standard format Upstream-Status: <Valid status>
Valid status Pending, Accepted, Backport, Denied, Inappropriate [reason], Submitted [where]
If you believe any of these test results are incorrect, please reply to the
mailing list (openembedded-core@lists.openembedded.org) raising your concerns.
Otherwise we would appreciate you correcting the issues and submitting a new
version of the patchset if applicable. Please ensure you add/increment the
version number when sending the new version (i.e. [PATCH] -> [PATCH v2] ->
[PATCH v3] -> ...).
---
Guidelines: https://www.openembedded.org/wiki/Commit_Patch_Message_Guidelines
Test framework: http://git.yoctoproject.org/cgit/cgit.cgi/patchtest
Test suite: http://git.yoctoproject.org/cgit/cgit.cgi/patchtest-oe
^ permalink raw reply [flat|nested] 3+ messages in thread
* Re: [PATCHv3] mdadm:fix mdmonitor.service
2019-07-31 1:50 [PATCHv3] mdadm:fix mdmonitor.service Zang Ruochen
2019-07-31 2:01 ` ✗ patchtest: failure for " Patchwork
@ 2019-07-31 2:50 ` ChenQi
1 sibling, 0 replies; 3+ messages in thread
From: ChenQi @ 2019-07-31 2:50 UTC (permalink / raw)
To: openembedded-core
On 07/31/2019 09:50 AM, Zang Ruochen wrote:
> -The original file mdmonitor.service is as follows:
> ...
> |[Service]
> |Environment= MDADM_MONITOR_ARGS=--scan
> |EnvironmentFile=-/run/sysconfig/mdadm
> |ExecStartPre=-/usr/lib/mdadm/mdadm_env.sh
> |ExecStart=/sbin/mdadm --monitor -y $MDADM_MONITOR_ARGS
> ...
> -It has a syntax error and it doesn't work properly,
What is the actual syntax error? Why does it not work properly?
> so add files/0001-Fix-file-mdmonitor.service-syntax-error.patch to fix it.
>
> Signed-off-by: Zang Ruochen <zangrc.fnst@cn.fujitsu.com>
> ---
> ...-file-mdmonitor.service-syntax-error.patch | 49 +++++++++++++++++++
> meta/recipes-extended/mdadm/mdadm_4.1.bb | 1 +
> 2 files changed, 50 insertions(+)
> create mode 100644 meta/recipes-extended/mdadm/files/0001-Fix-file-mdmonitor.service-syntax-error.patch
>
> diff --git a/meta/recipes-extended/mdadm/files/0001-Fix-file-mdmonitor.service-syntax-error.patch b/meta/recipes-extended/mdadm/files/0001-Fix-file-mdmonitor.service-syntax-error.patch
> new file mode 100644
> index 0000000000..a36fed6f9f
> --- /dev/null
> +++ b/meta/recipes-extended/mdadm/files/0001-Fix-file-mdmonitor.service-syntax-error.patch
> @@ -0,0 +1,49 @@
> +From a4a37cc9d91d7129910360914b8b2060139c0307 Mon Sep 17 00:00:00 2001
> +From: Zang Ruochen <zangrc.fnst@cn.fujitsu.com>
> +Date: Tue, 30 Jul 2019 12:44:25 +0800
> +Subject: [PATCH] Fix file mdmonitor.service syntax error
> +
> +-The original file mdmonitor.service is as follows:
> +...
> +|[Service]
> +|Environment= MDADM_MONITOR_ARGS=--scan
> +|EnvironmentFile=-/run/sysconfig/mdadm
> +|ExecStartPre=-/usr/lib/mdadm/mdadm_env.sh
> +|ExecStart=/sbin/mdadm --monitor -y $MDADM_MONITOR_ARGS
> +...
> +-It has a syntax error and it doesn't work properly,
> + so add new file mdmonitor.service to overwrite it.
> +
> +Signed-off-by: Zang Ruochen <zangrc.fnst@cn.fujitsu.com>
> +---
> + systemd/mdmonitor.service | 15 +++++++++------
> + 1 file changed, 9 insertions(+), 6 deletions(-)
> +
> +diff --git a/systemd/mdmonitor.service b/systemd/mdmonitor.service
> +index 3fc4687..bd243b4 100644
> +--- a/systemd/mdmonitor.service
> ++++ b/systemd/mdmonitor.service
> +@@ -6,11 +6,14 @@
> + # (at your option) any later version.
> +
> + [Unit]
> +-Description=MD array monitor
> +-DefaultDependencies=no
> ++Description=Software RAID monitoring and management
> ++ConditionPathExists=/etc/mdadm.conf
Why do above changes? Also, isn't /etc/mdadm.conf always there?
> +
> + [Service]
> +-Environment= MDADM_MONITOR_ARGS=--scan
> +-EnvironmentFile=-/run/sysconfig/mdadm
> +-ExecStartPre=-/usr/lib/mdadm/mdadm_env.sh
> +-ExecStart=BINDIR/mdadm --monitor -y $MDADM_MONITOR_ARGS
> ++Type=forking
> ++PIDFile=/var/run/mdadm/mdadm.pid
Type=forking is not encouraged. Is there any reason we want to use it?
Also, PIDFile is recommended to locate under /run instead of /var/run.
systemd actually automatically modifies the configuration to change
/var/run to /run.
Regards,
Chen Qi
> ++EnvironmentFile=-/etc/sysconfig/mdmonitor
> ++ExecStart=/sbin/mdadm --monitor --scan -y -f --pid-file=/var/run/mdadm/mdadm.pid
> ++
> ++[Install]
> ++WantedBy=multi-user.target
> +--
> +2.20.1
> +
> diff --git a/meta/recipes-extended/mdadm/mdadm_4.1.bb b/meta/recipes-extended/mdadm/mdadm_4.1.bb
> index 74c94f6ecb..c3e15adc71 100644
> --- a/meta/recipes-extended/mdadm/mdadm_4.1.bb
> +++ b/meta/recipes-extended/mdadm/mdadm_4.1.bb
> @@ -22,6 +22,7 @@ SRC_URI = "${KERNELORG_MIRROR}/linux/utils/raid/mdadm/${BPN}-${PV}.tar.xz \
> file://mdadm.init \
> file://0001-mdadm-add-option-y-for-use-syslog-to-recive-event-re.patch \
> file://include_sysmacros.patch \
> + file://0001-Fix-file-mdmonitor.service-syntax-error.patch \
> "
> SRC_URI[md5sum] = "51bf3651bd73a06c413a2f964f299598"
> SRC_URI[sha256sum] = "ab7688842908d3583a704d491956f31324c3a5fc9f6a04653cb75d19f1934f4a"
^ permalink raw reply [flat|nested] 3+ messages in thread
end of thread, other threads:[~2019-07-31 2:36 UTC | newest]
Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2019-07-31 1:50 [PATCHv3] mdadm:fix mdmonitor.service Zang Ruochen
2019-07-31 2:01 ` ✗ patchtest: failure for " Patchwork
2019-07-31 2:50 ` [PATCHv3] " ChenQi
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox