业务服务器升级CentOS 7.2系统的机器内核到kernel-3.10.0-862.el7.x86_64.rpm 时候,发现重启后之前绑定的slot盘符都失效了:
另外他们主要升级或安装了如下三个软件:
经查看配置文件正常:
[root@r3474 ]# cat /etc/udev/rules.d/99-hd.rules
KERNEL=="sd*[a-z]",ACTION=="add",ENV{ID_SERIAL}=="ST8000NM0055-1RM112_ZA1B6E9A",SYMLINK+="slot00"
KERNEL=="sd*[0-9]",ACTION=="add",ENV{ID_SERIAL}=="ST8000NM0055-1RM112_ZA1B6E9A",SYMLINK+="slot00-part%n"
KERNEL=="sd*[a-z]",ACTION=="remove",ENV{ID_SERIAL}=="ST8000NM0055-1RM112_ZA1B6E9A",RUN+="/bin/rm -f /dev/slot00 /dev/slot00-part*"
#split ST8000NM0055-1RM112_ZA1B6E9A#############################
KERNEL=="sd*[a-z]",ACTION=="add",ENV{ID_SERIAL}=="ST8000NM0055-1RM112_ZA1B6GXP",SYMLINK+="slot01"
KERNEL=="sd*[0-9]",ACTION=="add",ENV{ID_SERIAL}=="ST8000NM0055-1RM112_ZA1B6GXP",SYMLINK+="slot01-part%n"
KERNEL=="sd*[a-z]",ACTION=="remove",ENV{ID_SERIAL}=="ST8000NM0055-1RM112_ZA1B6GXP",RUN+="/bin/rm -f /dev/slot01 /dev/slot01-part*"
#split ST8000NM0055-1RM112_ZA1B6GXP#############################
KERNEL=="sd*[a-z]",ACTION=="add",ENV{ID_SERIAL}=="ST8000NM0055-1RM112_ZA1B8FMK",SYMLINK+="slot02"
KERNEL=="sd*[0-9]",ACTION=="add",ENV{ID_SERIAL}=="ST8000NM0055-1RM112_ZA1B8FMK",SYMLINK+="slot02-part%n"
KERNEL=="sd*[a-z]",ACTION=="remove",ENV{ID_SERIAL}=="ST8000NM0055-1RM112_ZA1B8FMK",RUN+="/bin/rm -f /dev/slot02 /dev/slot02-part*"
#split ST8000NM0055-1RM112_ZA1B8FMK#############################
各种尝试后发现,7系统使用了udevadm替代6的start_udev等命令,使用下面命令后,磁盘软链接就正常有了,目前方案是临时将其加到/etc/rc.local中:
/sbin/udevadm trigger --type=devices --action=add
在执行上面命令前,查看磁盘链接是没有slot的,正常后的显示如下:
udevadm info -q symlink -n /dev/sdb