Hacking the Linux Automounter - Current Limitations and Future Directions
The IT industry is experiencing a considerable shift from proprietary operating systems to Linux. As a result, the features and functionality that people have come to expect of these systems now must be provided for on Linux. An automounter provides a mechanism for automatically mounting file systems upon access, and umounting them when they are no longer referenced. The Linux automounter is not feature-complete and there are cases where Linux autofs is just plain incompatible with implementations from other proprietary vendors. In order to solve the current automounter limitations, we start by developing an understanding of how things work today. We explain the basic configuration of autofs for a client machine using simple examples. Then walk through the the internals for basic operations, such as the mounting, or lookup, of a directory and the umounting, or expiry, of a directory. This includes a description of where autofs fits into the VFS layer. Next we discuss the two main deployment difficulties. The first is that the Linux automounter implements direct mount maps in a way that is incompatible with that of every other implementation. We discuss the desired behavior and compare it with that of the Linux automounter. We will then discuss the current development effort to overcome this by extending autofs and its kernel interface. The second major problem surrounds the use of multi-mount entries for the
-hosts mount maps. Because of the nature of multi-mount maps, the Linux implementation mounts and umounts these directory hierarchies as a single unit. This means that clients mounting exported filesystems from large servers can experience resource starvation, causing failed mounts. The root problem is described and we show how the kernel and Linux automounter can be modified to address this issue also. We conclude with a review of the progress of the work outlined above and give a summary of future directions.