[arch-general] mdmonitor.service failed to start
Hi, I noticed that my mdmonitor.service failed to start with the following error message: Failed at step EXEC spawning /usr/lib/systemd/scripts/mdadm_env.sh: No such file or directory My mdadm package version is 3.3.1-2. Should I create such a script on my own? Regards.
On Thu, Jun 19, 2014 at 8:04 PM, Bill Sun <cap.sensitive@gmail.com> wrote:
Hi,
I noticed that my mdmonitor.service failed to start with the following error message: Failed at step EXEC spawning /usr/lib/systemd/scripts/mdadm_env.sh: No such file or directory
My mdadm package version is 3.3.1-2. Should I create such a script on my own?
Regards.
I don't think the service failed to start, The ExecStartPre starts with an -, so it's allowed to fail to start that script, but unit isn't considered failed: mdmonitor.service - MD array monitor Loaded: loaded (/usr/lib/systemd/system/mdmonitor.service; static) Active: active (running) since Wed 2014-06-18 13:43:41 CDT; 4 days ago Process: 266 ExecStartPre=/usr/lib/systemd/scripts/mdadm_env.sh (code=exited, status=203/EXEC) I think systemd is just overeagerly reporting errors here. Then again, mdadm is a bit weird here, since it only installs mdadm_env.sh on SUSE systems, yet didn't bother shipping a different service file for it. Sander
On Mon, Jun 23, 2014 at 09:57:46AM -0500, Sander Jansen wrote:
I don't think the service failed to start, The ExecStartPre starts with an -, so it's allowed to fail to start that script, but unit isn't considered failed:
mdmonitor.service - MD array monitor Loaded: loaded (/usr/lib/systemd/system/mdmonitor.service; static) Active: active (running) since Wed 2014-06-18 13:43:41 CDT; 4 days ago Process: 266 ExecStartPre=/usr/lib/systemd/scripts/mdadm_env.sh (code=exited, status=203/EXEC)
I think systemd is just overeagerly reporting errors here. Then again, mdadm is a bit weird here, since it only installs mdadm_env.sh on SUSE systems, yet didn't bother shipping a different service file for it. It appears that the main process actually failed: Process: 234 ExecStart=/sbin/mdadm --monitor $MDADM_MONITOR_ARGS (code=exited, status=1/FAILURE) Process: 228 ExecStartPre=/usr/lib/systemd/scripts/mdadm_env.sh (code=exited, status=203/EXEC) Main PID: 234 (code=exited, status=1/FAILURE)
However, I grep'ed all log files, and I did not find anything contains 'mdadm' Regards.
Ah, I found the problem: I never configured an email address in /etc/mdadm.conf But the new problem is: Why this service automatically start? I never manually enabled mdmonitor, and I cannot find its link in /etc/systemd/system/ . Regards.
But the new problem is: Why this service automatically start? I never manually enabled mdmonitor, and I cannot find its link in /etc/systemd/system/ . OK, it seems that the unit is somehow a dependence for some other units: $ systemctl is-enabled mdmonitor static
And I just masked that service to force prevent it from auto start. Problem 'solved'. Regards.
On Tue, Jun 24, 2014 at 12:58 AM, Bill Sun <cap.sensitive@gmail.com> wrote:
Ah, I found the problem: I never configured an email address in /etc/mdadm.conf
But the new problem is: Why this service automatically start? I never manually enabled mdmonitor, and I cannot find its link in /etc/systemd/system/ .
Regards.
It's part of the udev rule in /usr/lib/udev/rules.d/63-md-raid-arrays.rules Sander
On Tuesday 24 Jun 2014 10:07:31 Sander Jansen wrote:
But the new problem is: Why this service automatically start? I never manually enabled mdmonitor, and I cannot find its link in /etc/systemd/system/ .
Regards.
It's part of the udev rule in /usr/lib/udev/rules.d/63-md-raid-arrays.rules
I was a little puzzled by this too, but what confused me most is why there are two unit files provided by mdadm: mdmonitor.service and mdadm.service. I had the latter enabled previously, but the former is started automatically now. I had to disable mdadm.service, because it now clashes with the automatically-started mdmonitor. No problem, but it did strike me as a little odd. I like that md monitoring happens automatically now, though. That's a good idea. Paul
On Tue, Jun 24, 2014 at 10:56 AM, Paul Gideon Dann <pdgiddie@gmail.com> wrote:
On Tuesday 24 Jun 2014 10:07:31 Sander Jansen wrote:
But the new problem is: Why this service automatically start? I never manually enabled mdmonitor, and I cannot find its link in /etc/systemd/system/ .
Regards.
It's part of the udev rule in /usr/lib/udev/rules.d/63-md-raid-arrays.rules
I was a little puzzled by this too, but what confused me most is why there are two unit files provided by mdadm: mdmonitor.service and mdadm.service. I had the latter enabled previously, but the former is started automatically now. I had to disable mdadm.service, because it now clashes with the automatically-started mdmonitor. No problem, but it did strike me as a little odd.
I like that md monitoring happens automatically now, though. That's a good idea.
It looks like the mdadm.service seems to be a arch-package specific file. Probably before mdadm contained any systemd specific files itself. Sander
Just opened a bug report since we probably should get rid of mdadm.service. https://bugs.archlinux.org/task/40965 On Tue, Jun 24, 2014 at 11:25 AM, Sander Jansen <s.jansen@gmail.com> wrote:
On Tue, Jun 24, 2014 at 10:56 AM, Paul Gideon Dann <pdgiddie@gmail.com> wrote:
On Tuesday 24 Jun 2014 10:07:31 Sander Jansen wrote:
But the new problem is: Why this service automatically start? I never manually enabled mdmonitor, and I cannot find its link in /etc/systemd/system/ .
Regards.
It's part of the udev rule in /usr/lib/udev/rules.d/63-md-raid-arrays.rules
I was a little puzzled by this too, but what confused me most is why there are two unit files provided by mdadm: mdmonitor.service and mdadm.service. I had the latter enabled previously, but the former is started automatically now. I had to disable mdadm.service, because it now clashes with the automatically-started mdmonitor. No problem, but it did strike me as a little odd.
I like that md monitoring happens automatically now, though. That's a good idea.
It looks like the mdadm.service seems to be a arch-package specific file. Probably before mdadm contained any systemd specific files itself.
Sander
participants (3)
-
Bill Sun
-
Paul Gideon Dann
-
Sander Jansen