add udev role for pure storage (#2393)

Signed-off-by: Yaguang Tang <yaguang.tang@vexxhost.com>
This commit is contained in:
Yaguang Tang authored and GitHub committed 2025-06-12 11:19:54 -04:00
1 parent cea9c4744e
commit f4bd3dd2d9
8 files changed
+60

No files matched your search

@@ -3,7 +3,9 @@ BGP
CRD
Ceph
Glance
HBA
JWT
LUN
Manila
MySQL
Nova
@@ -23,4 +25,5 @@ neutron_pg_drop
readiness
subnet
tracker.ceph.com
udev
vrouter
+4
View File
@@ -79,6 +79,10 @@
tags:
- iscsi
- role: udev
tags:
- udev
- name: Deploy SDN
hosts: controllers:computes
become: true
@@ -0,0 +1,9 @@
---
features:
- |
Added udev rules for Pure Storage devices to optimize iSCSI LUN performance.
The rules:
- Set the I/O scheduler to `none` for improved throughput.
- Reduce CPU usage by disabling entropy collection.
- Balance CPU load by directing I/O completions to the originating CPU.
- Increase the HBA timeout to 60 seconds for reliable I/O operations.
+1
View File
@@ -0,0 +1 @@
# `udev`
+2
View File
@@ -0,0 +1,2 @@
# Add SCSI Unit Attention rescan for resize
ACTION=="change", SUBSYSTEM=="scsi", ENV{SDEV_UA}=="CAPACITY_DATA_HAS_CHANGED", TEST=="rescan", ATTR{rescan}="x"
+15
View File
@@ -0,0 +1,15 @@
# Recommended settings for Pure Storage FlashArray.
# Use noop scheduler for high-performance solid-state storage for SCSI devices
ACTION=="add|change", KERNEL=="sd*[!0-9]", SUBSYSTEM=="block", ENV{ID_VENDOR}=="PURE", ATTR{queue/scheduler}="none"
ACTION=="add|change", KERNEL=="dm-[0-9]*", SUBSYSTEM=="block", ENV{DM_NAME}=="3624a937*", ATTR{queue/scheduler}="none"
# Reduce CPU overhead due to entropy collection
ACTION=="add|change", KERNEL=="sd*[!0-9]", SUBSYSTEM=="block", ENV{ID_VENDOR}=="PURE", ATTR{queue/add_random}="0"
ACTION=="add|change", KERNEL=="dm-[0-9]*", SUBSYSTEM=="block", ENV{DM_NAME}=="3624a937*", ATTR{queue/add_random}="0"
# Spread CPU load by redirecting completions to originating CPU
ACTION=="add|change", KERNEL=="sd*[!0-9]", SUBSYSTEM=="block", ENV{ID_VENDOR}=="PURE", ATTR{queue/rq_affinity}="2"
ACTION=="add|change", KERNEL=="dm-[0-9]*", SUBSYSTEM=="block", ENV{DM_NAME}=="3624a937*", ATTR{queue/rq_affinity}="2"
# Set the HBA timeout to 60 seconds
ACTION=="add|change", KERNEL=="sd*[!0-9]", SUBSYSTEM=="block", ENV{ID_VENDOR}=="PURE", ATTR{device/timeout}="60"
+6
View File
@@ -0,0 +1,6 @@
# SPDX-FileCopyrightText: © 2025 VEXXHOST, Inc.
# SPDX-License-Identifier: GPL-3.0-or-later
- name: Reload udev
ansible.builtin.command: udevadm control --reload-rules
changed_when: false
+20
View File
@@ -0,0 +1,20 @@
# SPDX-FileCopyrightText: © 2025 VEXXHOST, Inc.
# SPDX-License-Identifier: GPL-3.0-or-later
- name: Add udev rules for Pure Storage FlashArray
ansible.builtin.copy:
src: 99-pure-storage.rules
dest: /etc/udev/rules.d/99-pure-storage.rules
owner: root
group: root
mode: "0644"
notify: Reload udev
- name: Add udev rules for SCSI Unit Attention
ansible.builtin.copy:
src: 90-scsi-ua.rules
dest: /etc/udev/rules.d/90-scsi-ua.rules
owner: root
group: root
mode: "0644"
notify: Reload udev