配置multipathd.service开机自启动
systemctl enable multipathd.service
启动multipathd.service失败
[root@hwdb1 ~]# systemctl status multipathd.service
multipathd.service - Device-Mapper Multipath Device Controller
Loaded: loaded (/usr/lib/systemd/system/multipathd.service; enabled; vendor preset: enabled)
Active: inactive (dead)
Condition: start condition failed at 三 2018-10-24 18:17:34 CST; 1min 59s ago
ConditionPathExists=/etc/multipath.conf was not met
仔细一看是没有配置文件的原因,通过mpathconf命令生成conf文件
[root@hwdb1 ~]# mpathconf --enable
[root@hwdb1 ~]# systemctl start multipathd.service
[root@hwdb1 ~]# systemctl status multipathd.service
multipathd.service - Device-Mapper Multipath Device Controller
Loaded: loaded (/usr/lib/systemd/system/multipathd.service; enabled; vendor preset: enabled)
Active: active (running) since 三 2018-10-24 18:20:36 CST; 2s ago
Process: 3718 ExecStart=/sbin/multipathd (code=exited, status=0/SUCCESS)
Process: 3715 ExecStartPre=/sbin/multipath -A (code=exited, status=0/SUCCESS)
Process: 3710 ExecStartPre=/sbin/modprobe dm-multipath (code=exited, status=0/SUCCESS)
Main PID: 3720 (multipathd)
Tasks: 10
CGroup: /system.slice/multipathd.service
└─3720 /sbin/multipathd