Proper mount options for iSCSI drives

This document (000019648) is provided subject to the disclaimer at the end of this document.

Environment

SUSE Linux Enterprise Server 15
SUSE Linux Enterprise Server 12

Situation

Systems configured to mount iSCSI drives via /etc/fstab entries may encounter the following issues:
  • Dropping to an emergency shell during boot if the iSCSI target is not reachable
  • Failure to shutdown correctly including hangs during shutdown process, and improperly dismounted file systems.

Resolution

For iSCSI based drives add the "_netdev,x-systemd.requires=iscsi.service" mount options for proper boot and shutdown ordering.
Please avoid using the “nofail” option as it is known to cause issues, and the “_netdev” option makes it superfluous.

Cause

Specifying an iSCSI mount point with no options may lead to issues during both boot and shutdown.

To fix this many users will use the "nofail" option. While this will help the system boot properly, it will cause systemd to improperly calculate the ordering constraints needed for a proper shutdown.

This results in race conditions during shutdown which can lead to the iSCSI storage device being disconnected prior to the mount point being properly unmounted.

To fix this problem "_netdev" should be used instead of "nofail".

Additional Information

From systemd.mount manual pages:
nofail : With nofail, this mount will be only wanted, not required, by local-fs.target or remote-fs.target. Moreover the mount unit is not ordered before these target units. This means that the boot will continue without waiting for the mount unit and regardless whether the mount point can be mounted successfully

_netdev : Normally the file system type is used to determine if a mount is a "network mount", i.e. if it should only be started after the network is available. Using this option overrides this detection and specifies that the mount requires network. Network mount units are ordered between remote-fs-pre.target and remote-fs.target, instead of local-fs-pre.target and local-fs.target. They also pull in network-online.target and are ordered after it and network.target.

Disclaimer

This Support Knowledgebase provides a valuable tool for SUSE customers and parties interested in our products and solutions to acquire information, ideas and learn from one another. Materials are provided for informational, personal or non-commercial use within your organization and are presented "AS IS" WITHOUT WARRANTY OF ANY KIND.

  • Document ID:000019648
  • Creation Date: 17-Jun-2020
  • Modified Date:19-Jun-2020
    • SUSE Linux Enterprise Server

< Back to Support Search

For questions or concerns with the SUSE Knowledgebase please contact: tidfeedback@suse.com

SUSE Support Forums

Get your questions answered by experienced Sys Ops or interact with other SUSE community experts.

Join Our Community

Support Resources

Learn how to get the most from the technical support you receive with your SUSE Subscription, Premium Support, Academic Program, or Partner Program.


SUSE Customer Support Quick Reference Guide SUSE Technical Support Handbook Update Advisories
Support FAQ

Open an Incident

Open an incident with SUSE Technical Support, manage your subscriptions, download patches, or manage user access.

Go to Customer Center