rhel 7 multipath服务启动报错

配置多路径服务,启动多路径multipathd.service的时候出现下面报错:

[root@rac2 ~]# systemctl status multipathd.service
multipathd.service - Device-Mapper Multipath Device Controller
Loaded: loaded (/usr/lib/systemd/system/multipathd.service; enabled)
Active: inactive (dead)
start condition failed at Wed 2019-11-27 10:51:20 CST; 12s ago
ConditionPathExists=/etc/multipath.conf was not met

Nov 26 18:39:35 rac2.example.com systemd[1]: Started Device-Mapper Multipath Device Controller.
Nov 26 19:03:34 rac2.example.com systemd[1]: Started Device-Mapper Multipath Device Controller.
Nov 27 10:51:05 rac2.example.com systemd[1]: Started Device-Mapper Multipath Device Controller.
Nov 27 10:51:20 rac2.example.com systemd[1]: Started Device-Mapper Multipath Device Controller.

查看报错信息提示未找到/etc/multipath.conf这个文件。

解决:

通过mpathconf命令生成conf文件

[root@rac2 ~]#mpathconf --enable

[root@rac2 ~]# systemctl restart multipathd.service 

[root@rac2 ~]# systemctl status multipathd.service
multipathd.service - Device-Mapper Multipath Device Controller
Loaded: loaded (/usr/lib/systemd/system/multipathd.service; enabled)
Active: active (running) since Wed 2019-11-27 11:04:50 CST; 6s ago
Process: 8564 ExecStart=/sbin/multipathd (code=exited, status=0/SUCCESS)
Process: 8561 ExecStartPre=/sbin/multipath -A (code=exited, status=0/SUCCESS)
Process: 8557 ExecStartPre=/sbin/modprobe dm-multipath (code=exited, status=0/SUCCESS)
Main PID: 8568 (multipathd)
CGroup: /system.slice/multipathd.service
└─8568 /sbin/multipathd

Nov 27 11:04:50 rac2.example.com systemd[1]: Starting Device-Mapper Multipath Device Controller...
Nov 27 11:04:50 rac2.example.com systemd[1]: PID file /var/run/multipathd/multipathd.pid not readable (yet?) after start.
Nov 27 11:04:50 rac2.example.com systemd[1]: Started Device-Mapper Multipath Device Controller.
Nov 27 11:04:50 rac2.example.com multipathd[8568]: path checkers start up

原文地址:https://www.cnblogs.com/orcl-2018/p/11940823.html