How can I run a service before network filesystems get mounted?

Solution Verified - Updated -

Issue

  • I need to have a service start before network filesystems are processed

  • My NFS mounts fail sometimes at boot with the following error message

    mount[XXX]: mount.nfs: Failed to resolve server <my-nfs-server>: Name or service not known
    
  • My network filesystems need to be mounted as non-local user or group ids using 3rd-party authentication service (e.g. centrifydc)

  • My network filesystems rely on a local DNS service, hence the local DNS service must be started before mounts are performed

Environment

  • Red Hat Enterprise Linux (RHEL) 7 and later
    • systemd
    • remote filesystems in /etc/fstab
    • 3rd party authentication service or local DNS cache

Subscriber exclusive content

A Red Hat subscription provides unlimited access to our knowledgebase, tools, and much more.

Current Customers and Partners

Log in for full access

Log In

New to Red Hat?

Learn more about Red Hat subscriptions

Using a Red Hat product through a public cloud?

How to access this content