Skip to main content
SAN hosts and cloud clients

Use Citrix XenServer with ONTAP

Contributors netapp-ranuk netapp-pcarriga netapp-aoife

You can configure ONTAP SAN host configuration settings for Citrix XenServer 7 series OS releases with FC, FCoE, and iSCSi protocols.

SAN Booting

What you'll need

If you decide to use SAN booting, it must be supported by your configuration. You can use the NetApp Interoperability Matrix Tool to verify that your OS, HBA, HBA firmware and the HBA boot BIOS, and ONTAP version are supported.

Steps
  1. Map the SAN boot LUN to the host.

  2. Verify that multiple paths are available.

    Note Multiple paths become available after the host operating system is up and running on the paths.
  3. Enable SAN booting in the server BIOS for the ports to which the SAN boot LUN is mapped.

    For information on how to enable the HBA BIOS, see your vendor-specific documentation.

  4. Reboot the host to verify that the boot was successful.

Multipathing

Multipath support in Citrix XenServer is based on the Device Mapper Multipathd components. Device mapper nodes are not automatically created for all LUNs presented to the XenServer and are only provisioned when LUNs are actively used by the Storage Management Layer (API). Citrix XenServer Storage Manager API plugin handles activating and deactivating multipath nodes automatically.

Due to incompatibilities with the Integrated Multipath Management architecture, Citrix recommends that you use the Citrix XenCenter application for managing the storage configuration. If it is necessary to query the status of Device Mapper tables manually, or list active device mapper multipath nodes on the system, you can use the /sbin/mpathutil status command to verify the settings for your ONTAP LUNs. For more information refer to the standard vendor documentation for Citrix XenServer.

Non-ASA configurations

For non-ASA configurations, there should be two groups of paths with different priorities. The paths with higher priorities are Active/Optimized, meaning they are serviced by the controller where the aggregate is located. The paths with lower priorities are active but are non-optimized because they are served from a different controller. The non-optimized paths are only used when optimized paths are not available.

Example

The following example displays the correct output for an ONTAP LUN with two Active/Optimized paths and two Active/Non-Optimized paths.

# mpathutil status
show topology
3600a098038303458772450714535317a dm-0 NETAPP  , LUN C-Mode
size=80G features='4 queue_if_no_path pg_init_retries 50 retain_attached_hw_handle' hwhandler='1 alua' wp=rw
|-+- policy='service-time 0' prio=50 status=active
| |- 2:0:2:0   sdc   8:32    active ready running
| |- 12:0:5:0  sdn   8:208   active ready running
| |- 2:0:6:0   sdg   8:96    active ready running
| `- 12:0:0:0  sdi   8:128   active ready running
|-+- policy='service-time 0' prio=10 status=enabled
  |- 2:0:0:0   sda   8:0     active ready running
  |- 2:0:1:0   sdb   8:16    active ready running
  |- 12:0:3:0  sd1   8:176   active ready running
  `-12:0:6:0   sdo   8:224   active ready running
[root@sanhost ~]#
Note A single LUN shouldn't require more than four paths. Having more than four paths might cause path issues during storage failures.

All SAN Array Configuration

In All SAN Array (ASA) configurations, all paths to a given Logical Unit (LUN) are active and optimized. This means I/O can be served through all paths at the same time, thereby enabling better performance.

Example

The following example displays the correct output for an ONTAP LUN with all four Active/Optimized paths:

# mpathutil status
show topology
3600a098038303458772450714535317a dm-0 NETAPP  , LUN C-Mode
size=80G features='4 queue_if_no_path pg_init_retries 50 retain_attached_hw_handle' hwhandler='1 alua' wp=rw
|-+- policy='service-time 0' prio=50 status=active
| |- 2:0:2:0   sdc   8:32    active ready running
| |- 12:0:5:0  sdn   8:208   active ready running
| |- 2:0:6:0   sdg   8:96    active ready running
| `- 12:0:0:0  sdi   8:128   active ready running
[root@sanhost ~]#
Note A single LUN shouldn't require more than four paths. Having more than four paths might cause path issues during storage failures.

The Citrix XenServer 7.x OS is compiled with all settings required to recognize and correctly manage ONTAP LUNs. For Citrix XenServer 7.x, an empty zerobyte /etc/multipath.conf file must exist, but you do not need to make specific changes to the file.

Enable the host multipath service from the Xencenter Management Portal and verify that the multipath service is enabled and running.

# systemct1 status multipathd
multipathd.service - Device-Mapper Multipath Device Controller
  Loaded:  load (/usr/lib/systemd/system/multipathd.service; enabled; vendor preset: enabled)
 Drop-In:  /etc/systemd/system/multipathd.service.d
             slice.config
  Active:  active (running) since Fri YYYY-MM-DD 00:00:26 IST; 1 month 9 days ago
Main PID:  3789 (multipathd)
  CGroup:  /control.slice/multipathd.service
            3789  /sbin/multipathd

There is no requirement to append content to the /etc/multipath.conf file, unless you have devices that you do not want multipath to manage or you have existing settings that override defaults. You can add the following syntax to the multipath.conf file to exclude the unwanted devices.

# cat /etc/multipath.conf
blacklist {
     wwid    <DevId>
     devnode "^(ram|raw|loop|fd|md|dm-|sr|scd|st)[0-9]*"
     devnode "^hd[a-z]"
     devnode "^cciss.*"
}
Note Replace the <DevID> with the WWID string of the device you want to exclude.
Example

In the following example for Citrix XenServer 7.x, sda is the local SCSI disk that you want to add to the blacklist.

  1. Run the following command to determine the WWID:

    # lib/udev/scsi_id -gud /dev/sda
    3600a098038303458772450714535317a
  2. Add this WWID to the blacklist stanza in the /etc/multipath.conf:

    #cat /etc/multipath.conf
    blacklist {
      wwid    3600a098038303458772450714535317a
      devnode "^(ram|raw|loop|fd|md|dm-|sr|scd|st)[0-9*]"
      devnode "^hd[a-z]"
      devnode "^cciss.*"
    }

Refer to the multipath parameter runtime configuration by using the $multipathd show config command. You should always check your running configuration for legacy settings that might be overriding default settings, especially in the defaults section.

The following table shows the critical multipathd parameters for ONTAP LUNs and the required values. If a host is connected to LUNs from other vendors and any of these parameters are overridden, they need to be corrected by later stanzas in multipath.conf that apply specifically to ONTAP LUNs. If this is not done, the ONTAP LUNs might not work as expected. The following defaults should only be overridden in consultation with NetApp and/or the OS vendor and only when the impact is fully understood.

Parameter Setting

detect_prio

yes

dev_loss_tmo

"infinity"

failback

immediate

fast_io_fail_tmo

5

features

"3 queue_if_no_path pg_init_retries 50"

flush_on_last_del

"yes"

hardware_handler

"0"

path_checker

"tur"

path_grouping_policy

"group_by_prio"

path_selector

"service-time 0"

polling_interval

5

prio

"ontap"

product

LUN.*

retain_attached_hw_handler

yes

rr_weight

"uniform"

user_friendly_names

no

vendor

NETAPP

Example

The following example illustrates how to correct an overridden default. In this case, the multipath.conf file defines values for path_checker and detect_prio that are not compatible with ONTAP LUNs. If they cannot be removed because of other SAN arrays attached to the host, these parameters can be corrected specifically for ONTAP LUNs with a device stanza.

# cat /etc/multipath.conf
defaults {
  path_checker readsector0
  detect_prio no
}
devices{
        device{
                vendor "NETAPP "
                product "LUN.*"
                path_checker tur
                detect_prio yes
        }
}
Note Citrix XenServer recommends use of Citrix VM tools for all Linux and Windows based guest VMs for a supported configuration.

Known issues

There are no known issues for the Citrix XenServer with ONTAP release.