Mount and unmount operations

Mount is an operation of enumerating an on-disk superblock and metadata into memory for the filesystem's use. This process creates in-memory data structures that describe file metadata and present the host operating system with a view of the directory and file layout in the volume. The mount operation is implemented to check consistency of disk volume. As discussed earlier, the superblock contains the state of the filesystem; it indicates whether the volume is consistent or dirty. If the volume is clean or consistent, a mount operation would succeed, and if the volume is marked as dirty or inconsistent, it returns with the appropriate failure status.

An abrupt shutdown causes filesystem state to be dirty, and requires consistency check before it can be marked for use again. Mechanisms adopted for consistency checks are complex and time consuming; such operations are filesystem implementation specific, and most simple ones provide specific tools for consistency and checks, and other modern implementations use journaling.

Unmount is an operation of flushing the in-memory state of filesystem data structures back to disk. This operation causes all metadata and file caches to be synchronized with disk blocks. Unmount marks the filesystem state in the superblock as consistent, indicating graceful shutdown. In other words, the on-disk superblock state remains dirty until unmount is executed.

..................Content has been hidden....................

You can't read the all page of ebook, please click here login for view all page.
Reset
18.227.228.95