Applying Queue Settings with udev

Citrix

Audience
Public
Technology Integrations
Citrix
Source Type
Documentation

Once the IO scheduler elevator has been set to 'noop' it is often desired to keep the setting persistent, after reboots.

Step 1: Create the Rules File

Create a new file in the following location. The OS will use the udev rules to set the elevators after each reboot.


/etc/udev/rules.d/99-pure-storage.rules

Step 2: Add the Following Entries to the Rules File

The following entries automatically sets the elevator to 'noop' each time the system is rebooted. Create a file that has the following entries, ensuring each entry exists on one line with no carriage returns:


# Recommended settings for Pure Storage FlashArray.

# Use noop scheduler for high-performance solid-state storage
ACTION=="add|change", KERNEL=="sd*[!0-9]", SUBSYSTEM=="block", ENV{ID_VENDOR}=="PURE", ATTR{queue/scheduler}="noop"

# 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"

# 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"

# Set the HBA timeout to 60 seconds
ACTION=="add", SUBSYSTEMS=="scsi", ATTRS{model}=="FlashArray      ", RUN+="/bin/sh -c 'echo 60 > /sys/$DEVPATH/device/timeout'"
Note:

Please note that 6 spaces are needed after "FlashArray" under "Set the HBA timeout to 60 seconds" above for the rule to take effect.

Reference

  1. Citrix XenServer performance tuning blog
  2. Citrix XenServer performance tuning blog
  3. Classic network and thruput performance guide
  4. How to Collect Diagnostic Information for XenServer