open-vm-tools/udev_rules-disk-devs-only.patch

12 lines
1009 B
Diff

Only adjust timeout on disk devices.
Index: open-vm-tools-10.2.0-7253323/udev/99-vmware-scsi-udev.rules
===================================================================
--- open-vm-tools-10.2.0-7253323.orig/udev/99-vmware-scsi-udev.rules
+++ open-vm-tools-10.2.0-7253323/udev/99-vmware-scsi-udev.rules
@@ -1,3 +1,3 @@
-ACTION=="add", SUBSYSTEMS=="scsi", ATTRS{vendor}=="VMware*", ATTRS{timeout}=="?*", ATTRS{model}=="Virtual disk*", RUN+="/bin/sh -c 'echo 180 >/sys$DEVPATH/timeout'"
-ACTION=="add", SUBSYSTEMS=="scsi", ATTRS{vendor}=="VMware*", ATTRS{timeout}=="?*", ATTRS{model}=="VMware Virtual S", RUN+="/bin/sh -c 'echo 180 >/sys$DEVPATH/timeout'"
+ACTION=="add", SUBSYSTEMS=="scsi", ATTRS{vendor}=="VMware*" , ATTRS{model}=="Virtual disk*", ENV{DEVTYPE}=="disk", RUN+="/bin/sh -c 'echo 180 >/sys$DEVPATH/device/timeout'"
+ACTION=="add", SUBSYSTEMS=="scsi", ATTRS{vendor}=="VMware*" , ATTRS{model}=="VMware Virtual S", ENV{DEVTYPE}=="disk", RUN+="/bin/sh -c 'echo 180 >/sys$DEVPATH/device/timeout'"