Link and access options in /etc/exports You don t (Web hosting ecommerce)

Link and access options in /etc/exports You don t have to just give away your files and directories when you export a directory with NFS. In the options part of each entry in /etc/exports, you can add options that allow or limit access based on user ID, subdirectory, and read/write permission. These options, which are passed to NFS, are as follows: ro Only allow the client to mount this exported file system read-only. The default is to mount the file system read/write. rw Explicitly ask that a shared directory be shared with read/write permissions. (If the client chooses, it can still mount the directory read-only.) noaccess All files and directories below the given directory are not accessible. This is how you would exclude selected subdirectories of a shared directory from being shared. The directory will still appear to the client that mounts the file system that includes this directory, but the client will not be able to view its contents. link_relative If absolute symbolic links are included in the shared file system (that is, ones that identify a full path), the full path is converted to a relative path. To do this, each part of the path is converted to two dots and a slash (../) to reach the root of the file system. Link_absolute Don t change any of the symbolic links (default). User mapping options in /etc/exports Besides options that define how permissions are handled generally, you can also use options to set the permissions that specific users have to NFS shared file systems. One method that simplifies this process is to have each user with multiple user accounts have the same user name and UID on each machine. This makes it easier to map users so that they have the same permission on a mounted file system as they do on files stored on their local hard disk. If that method is not convenient, user IDs can be mapped in many other ways. Here are some methods of setting user permissions and the /etc/exports option that you use for each method: root user Normally, the client s root user is mapped into the anonymous user ID. This prevents the root user from a client computer from being able to change all files and directories in the shared file system. If you want the client s root user to have root permission on the server, use the no_root_squash option. Tip There may be other administrative users, in addition to root, that you want to squash. I recommend squashing UIDs 0 99 as follows: squash_uids=0 99. Anonymous user/group By using anonymous user ID and group ID, you essentially create a user/group whose permissions will not allow access to files that belong to any users on the server (unless those users open permission to everyone). However, files created by the anonymous user/group will be available to anyone assigned as the anonymous user/group. To set all remote users to the anonymous user/group, use the all_squash option.
Looking for affordable and reliable webhost to host and run your business application? Then look no more and go to servlet web hosting services.

Leave a Reply