Re: [PATCH 1/8] /etc/multipath.conf is not mandatory

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On 26.06.2015 16:55, Thomas Renninger wrote:
> From: Hannes Reinecke <hare@xxxxxxx>
> 
> If rootfs is on multipath, but platform does not have an /etc/multipath.conf
> file which is not urgently needed, they system will not boot, due to:
> 
> multipathd is not started and rootfs and swap are not found:
> systemctl status multipathd.service
> * multipathd.service - Device-Mapper Multipath Device Controller
>    Loaded: loaded (/usr/lib/systemd/system/multipathd.service; disabled; vendor preset: enabled)
>    Active: inactive (dead)
> Condition: start condition failed at Thu 2015-05-07 11:49:11 CEST; 7min ago
>            ConditionPathExists=/etc/multipath.conf was not met
> and exit to dracut shell.
> 
> Signed-off-by: Thomas Renninger <trenn@xxxxxxx>
> ---
>  modules.d/90multipath/multipathd.service | 1 -
>  1 file changed, 1 deletion(-)
> 
> diff --git a/modules.d/90multipath/multipathd.service b/modules.d/90multipath/multipathd.service
> index b64b02c..f7bc65f 100644
> --- a/modules.d/90multipath/multipathd.service
> +++ b/modules.d/90multipath/multipathd.service
> @@ -6,7 +6,6 @@ Conflicts=shutdown.target
>  ConditionKernelCommandLine=!nompath
>  ConditionKernelCommandLine=!rd.multipath=0
>  ConditionKernelCommandLine=!rd_NO_MULTIPATH
> -ConditionPathExists=/etc/multipath.conf
>  
>  [Service]
>  Type=simple
> 

CC'ing Benjmain Marzinski as the Fedora maintainer of device-mapper-multipath.

I don't understand how multipath is used without a configuration?

Anyway, I see the service file in Fedora is quiet different from yours and
yours is also different from upstream.

So we have:

*Upstream* -
<http://git.opensvc.com/gitweb.cgi?p=multipath-tools/.git;a=blob_plain;f=multipathd/multipathd.service;h=b5b755bbacd08cd9f612206ce73dce965dbc8b2a;hb=HEAD>

[Unit]
Description=Device-Mapper Multipath Device Controller
Before=iscsi.service iscsid.service lvm2-activation-early.service
Before=local-fs-pre.target
After=multipathd.socket
DefaultDependencies=no
Wants=local-fs-pre.target multipathd.socket
Conflicts=shutdown.target

[Service]
Type=notify
NotifyAccess=main
LimitCORE=infinity
ExecStartPre=/sbin/modprobe dm-multipath
ExecStart=/sbin/multipathd -d -s
ExecReload=/sbin/multipathd reconfigure

[…]

*Fedora device-mapper-multipath-0.4.9-76*

 [Unit]
 Description=Device-Mapper Multipath Device Controller
 Before=iscsi.service iscsid.service lvm2-activation-early.service
-Before=local-fs-pre.target
-After=multipathd.socket
+After=syslog.target
+ConditionPathExists=/etc/multipath.conf
+ConditionKernelCommandLine=!nompath
 DefaultDependencies=no
-Wants=local-fs-pre.target multipathd.socket
 Conflicts=shutdown.target

 [Service]
-Type=notify
-NotifyAccess=main
-LimitCORE=infinity
+Type=forking
+PIDFile=/var/run/multipathd/multipathd.pid
 ExecStartPre=/sbin/modprobe dm-multipath
-ExecStart=/sbin/multipathd -d -s
+ExecStartPre=-/sbin/multipath -A
+ExecStart=/sbin/multipathd
 ExecReload=/sbin/multipathd reconfigure
+#ExecStop=/path/to/scrip delete-me if not necessary


*openSUSE multipath-tools-0.5.0-20.1*

 [Unit]
 Description=Device-Mapper Multipath Device Controller
 Before=iscsi.service iscsid.service lvm2-activation-early.service
-Before=local-fs-pre.target
-After=multipathd.socket
+Before=local-fs-pre.target systemd-udev-trigger.service
+After=multipathd.socket systemd-udevd.service
 DefaultDependencies=no
 Wants=local-fs-pre.target multipathd.socket
 Conflicts=shutdown.target
@@ -11,6 +11,10 @@
 Type=notify
 NotifyAccess=main
 LimitCORE=infinity
-ExecStartPre=/sbin/modprobe dm-multipath
+ExecStartPre=/sbin/modprobe -a scsi_dh_alua scsi_dh_emc scsi_dh_rdac dm-multipath
 ExecStart=/sbin/multipathd -d -s
 ExecReload=/sbin/multipathd reconfigure



I think it's impossible to make this independent in dracut from the shipped
package. You guys definetly should either ship the initramfs version in the
package, so the dracut module can copy that, or better use the same unit file
across distributions.

--
To unsubscribe from this list: send the line "unsubscribe initramfs" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html



[Index of Archives]     [Linux Kernel]     [Linux USB Devel]     [Linux Audio Users]     [Yosemite News]     [Linux SCSI]

  Powered by Linux