z/OS UNIX System Services File System Interface Reference
Previous topic | Next topic | Contents | Contact z/OS | Library | PDF


Asynchronous mounting

z/OS UNIX System Services File System Interface Reference
SA23-2285-00

The PFS may choose to complete mounting the file system asynchronously. Because latches are held by the LFS during execution of vfs_mount, it is desirable to perform the mount asynchronously if it cannot be completed immediately (perhaps because of the need to communicate with another system).

Asynchronous mount processing follows this sequence:
  1. The vfs_mount service is called by the LFS as part of the mount processing described in Mounting file systems.
    • If the PFS decides to complete the mount asynchronously, it must indicate this to the LFS with the AsynchMount flag in the MTAB before returning to the LFS.
    • If the SynchOnly flag in the MTAB is set on, the mount must be completed synchronously. The PFS must either complete it synchronously or reject it, returning EINVAL.
  2. When the PFS has completed its asynchronous processing, it calls osi_mountstatus to indicate to the LFS that the mount can now be completed.
  3. The LFS then calls vfs_mount a second time, from within the OMVS address space. On the second call, AsynchMount in the MTAB is turned on so that the PFS can identify this as the second mount.

    The PFS completes the mount actions described in this topic.

After the PFS returns to the LFS from the first call to vfs_mount, the LFS may call any vfs_ operation. In particular, the PFS must be prepared to process vfs_unmount and vfs_statfs. If the PFS can determine the file attributes on the first call, it can create and return the root vnode on that call. Otherwise, it defers this until the second call. If a vnode is returned on the first call and also on the second call, it must be the same vnode each time. If the mount operation fails during the asynchronous phase, the PFS calls osi_mountstatus and reports the failure on the second vfs_mount call.

Serialization: During each vfs_mount, the PFS has exclusive access to the file system that is being mounted, and no access is allowed until the second vfs_mount has completed.

Go to the previous page Go to the next page




Copyright IBM Corporation 1990, 2014